diff --git a/Cargo.toml b/Cargo.toml index 545391930..5df6f22c2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "specs" -version = "0.14.0" +version = "0.14.1" description = """ Specs is an Entity-Component System library written in Rust. """ diff --git a/src/storage/mod.rs b/src/storage/mod.rs index 54483b296..022237340 100644 --- a/src/storage/mod.rs +++ b/src/storage/mod.rs @@ -202,6 +202,14 @@ where &self.data.inner } + /// Returns the `EntitesRes` resource fetched by this storage. + /// **This does not have anything to do with the components inside.** + /// You only want to use this when implementing additional methods + /// for `Storage` via an extension trait. + pub fn fetched_entities(&self) -> &EntitiesRes { + &self.entities + } + /// Tries to read the data associated with an `Entity`. pub fn get(&self, e: Entity) -> Option<&T> { if self.data.mask.contains(e.id()) && self.entities.is_alive(e) {