diff options
Diffstat (limited to 'ecs/src/event')
-rw-r--r-- | ecs/src/event/component.rs | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/ecs/src/event/component.rs b/ecs/src/event/component.rs index 40cd20d..8b066a7 100644 --- a/ecs/src/event/component.rs +++ b/ecs/src/event/component.rs @@ -5,7 +5,8 @@ use std::marker::PhantomData; use ecs_macros::Component; -use crate::component::{Component, Id as ComponentId}; +use crate::component::Component; +use crate::uid::Uid; use crate::event::{Event, Id}; use crate::tuple::{ReduceElement as TupleReduceElement, With as TupleWith}; @@ -50,7 +51,7 @@ where where Self: Sized, { - Id::new::<Added<ComponentForId>, _>(Some(ComponentId::of::<ComponentT>())) + Id::new::<Added<ComponentForId>, _>(Some(ComponentT::id())) } } @@ -93,18 +94,18 @@ where where Self: Sized, { - Id::new::<Removed<ComponentForId>, _>(Some(ComponentId::of::<ComponentT>())) + Id::new::<Removed<ComponentForId>, _>(Some(ComponentT::id())) } } #[must_use] -pub fn create_added_id(component_id: ComponentId) -> Id +pub fn create_added_id(component_id: Uid) -> Id { Id::new::<Added<ComponentForId>, _>(Some(component_id)) } #[must_use] -pub fn create_removed_id(component_id: ComponentId) -> Id +pub fn create_removed_id(component_id: Uid) -> Id { Id::new::<Removed<ComponentForId>, _>(Some(component_id)) } |