diff options
Diffstat (limited to 'ecs/src/event/component.rs')
-rw-r--r-- | ecs/src/event/component.rs | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/ecs/src/event/component.rs b/ecs/src/event/component.rs index 5b40c39..b4edffc 100644 --- a/ecs/src/event/component.rs +++ b/ecs/src/event/component.rs @@ -41,7 +41,9 @@ where } } -/// Event emitted when a `ComponentT` component is removed from a entity. +/// Event emitted when: +/// a) A `ComponentT` component is removed from a entity. +/// b) A entity with component `ComponentT` is despawned. #[derive(Clone, Component)] pub struct Removed<ComponentT> where @@ -72,3 +74,11 @@ where Self { _pd: PhantomData } } } + +/// Specifies a kind of component event UID. +#[derive(Debug, Clone, Copy)] +#[non_exhaustive] +pub enum Kind +{ + Removed, +} |