diff options
-rw-r--r-- | ecs/src/pair.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/ecs/src/pair.rs b/ecs/src/pair.rs index f6d33d2..600c6e4 100644 --- a/ecs/src/pair.rs +++ b/ecs/src/pair.rs @@ -356,6 +356,13 @@ pub struct WithWildcard<'world, Relation, Target> impl<Relation, Target> WithWildcard<'_, Relation, Target> { + /// Returns the [`Uid`] of the pair. + #[must_use] + pub fn id(&self) -> Uid + { + self.component_ref.id() + } + /// Attempts to get the component data of this pair, returning `None` if the `Data` /// type is incorrect. /// |