✨♻️ bevy_vanth, vanth, vanth_derive, flake: Add Bevy integration crate and refactor entity/networking
- Created new crate `bevy_vanth` with basic plugin structure for Bevy integration. - Refactored `Id` generation in `vanth` to use `OsRng` and removed redundant `to_u128_pair`/`from_u128_pair` methods. - Moved networking functionality into new `net` module with `Node`, `Packet`, and `Message` types. - Updated `vanth_derive` to use `proc-macro-crate` for reliable crate path resolution. - Added `rand` dependency to replace custom ID generation logic. - Updated `Cargo.toml`/`Cargo.lock` with new dependencies: `bevy_app`, `nix`, `cfg_aliases`, `proc-macro-crate`. - Modified `README.md` with improved project description. - Added commented clippy check in `flake.nix`.
This commit is contained in:
parent
5262a266c0
commit
3b193c5aa3
13 changed files with 298 additions and 127 deletions
8
crates/bevy_vanth/Cargo.toml
Normal file
8
crates/bevy_vanth/Cargo.toml
Normal file
|
@ -0,0 +1,8 @@
|
|||
[package]
|
||||
name = "bevy_vanth"
|
||||
version.workspace = true
|
||||
edition.workspace = true
|
||||
|
||||
[dependencies]
|
||||
bevy_ecs.workspace = true
|
||||
bevy_app.workspace = true
|
20
crates/bevy_vanth/src/lib.rs
Normal file
20
crates/bevy_vanth/src/lib.rs
Normal file
|
@ -0,0 +1,20 @@
|
|||
use bevy_app::Plugin;
|
||||
use bevy_ecs::component::Component;
|
||||
|
||||
#[derive(Component)]
|
||||
pub struct VanthRoot {}
|
||||
|
||||
pub struct VanthPlugin {}
|
||||
|
||||
impl Plugin for VanthPlugin {
|
||||
fn build(&self, app: &mut bevy_app::App) {
|
||||
// TODO: Allow specifying custom schedules.
|
||||
app.add_systems(bevy_app::FixedPreUpdate, run_vanth).finish();
|
||||
}
|
||||
}
|
||||
|
||||
impl VanthPlugin {}
|
||||
|
||||
fn run_vanth() {
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue