Skip to content

Commit

Permalink
remove: unused stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
mrchantey committed Feb 16, 2024
1 parent 39a795b commit 761ca12
Show file tree
Hide file tree
Showing 8 changed files with 17 additions and 71 deletions.
38 changes: 1 addition & 37 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,6 @@ notify = "6.0.1"
notify-debouncer-full = "0.2.0"
serde = { version = "1.0.193", features = ["derive"] }
serde_json = "1.0.108"
typetag = "0.2.14"
ciborium = "0.2"

### math ###
Expand Down
3 changes: 0 additions & 3 deletions crates/forky/forky_bevy/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,6 @@ bevy_utils = { workspace = true }
anyhow = { workspace = true }
extend = { workspace = true }

serde = { workspace = true }
serde_json = { workspace = true }

[target.'cfg(target_arch = "wasm32")'.dependencies]
forky_web = { workspace = true }
leptos = { workspace = true }
Expand Down
30 changes: 15 additions & 15 deletions crates/forky/forky_bevy/src/components/orphan_children.rs
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
use bevy_derive::Deref;
use bevy_derive::DerefMut;
use bevy_ecs::prelude::*;
use bevy_hierarchy::prelude::*;
// use bevy_derive::Deref;
// use bevy_derive::DerefMut;
// use bevy_ecs::prelude::*;
// use bevy_hierarchy::prelude::*;

/// Container for children that are not in the hierarchy.
#[derive(Component, Deref, DerefMut)]
pub struct OrphanChildren(pub Vec<Entity>);
// /// Container for children that are not in the hierarchy.
// #[derive(Component, Deref, DerefMut)]
// pub struct OrphanChildren(pub Vec<Entity>);

impl OrphanChildren {
/// does not account for if this orphan has orphan children
pub fn despawn(&self, commands: &mut Commands) {
for child in self.0.iter() {
commands.entity(*child).despawn_recursive();
}
}
}
// impl OrphanChildren {
// /// does not account for if this orphan has orphan children
// pub fn despawn(&self, commands: &mut Commands) {
// for child in self.0.iter() {
// commands.entity(*child).despawn_recursive();
// }
// }
// }
3 changes: 1 addition & 2 deletions crates/gamai/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,6 @@ anyhow = { workspace = true }
heck = { workspace = true }
petgraph = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
typetag = { workspace = true }
extend = { workspace = true }
num-traits = { workspace = true }
strum = { workspace = true }
Expand All @@ -47,6 +45,7 @@ bevy_time = { workspace = true }
bevy_utils = { workspace = true }

[dev-dependencies]
serde_json = { workspace = true }
sweet = { workspace = true }

[[example]]
Expand Down
1 change: 0 additions & 1 deletion crates/gamai/macros/src/action/parse_action.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ fn action_trait(
let post_tick_system = post_tick_system(input);

quote! {
#[typetag::serde]
impl Action for #ident {
fn duplicate(&self) -> Box<dyn Action> {
Box::new(self.clone())
Expand Down
11 changes: 0 additions & 11 deletions crates/gamai/src/action/action.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ use bevy_ecs::system::EntityCommands;
use bevy_ecs::world::EntityWorldMut;
use serde::Serialize;

#[typetag::serde]
pub trait Action: 'static {
fn duplicate(&self) -> Box<dyn Action>;

Expand Down Expand Up @@ -59,16 +58,6 @@ impl<T: IntoAction> Action for T {
}

fn meta(&self) -> ActionMeta { self.into_action_ref().meta() }

#[doc(hidden)]
fn typetag_name(&self) -> &'static str {
self.into_action_ref().typetag_name()
}

#[doc(hidden)]
fn typetag_deserialize(&self) {
self.into_action_ref().typetag_deserialize()
}
}

// impl<T> IntoAction for T where
Expand Down
1 change: 0 additions & 1 deletion crates/gamai/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,4 @@ pub mod exports {
pub use serde;
pub use serde::Deserialize;
pub use serde::Serialize;
pub use typetag;
}

0 comments on commit 761ca12

Please sign in to comment.