pub trait PersistSpawnCommandsExt {
// Required methods
fn spawn_persisted<T: Bundle>(&mut self, bundle: T) -> EntityCommands<'_>;
fn spawn_persisted_with_id<T: Bundle>(
&mut self,
id: impl Into<String>,
bundle: T,
) -> EntityCommands<'_>;
}Expand description
Ergonomic helpers for spawning persisted entities via Commands.
These helpers always attach a Guid component so call sites do not need to
remember (Guid, Bundle) tuples.
Required Methods§
fn spawn_persisted<T: Bundle>(&mut self, bundle: T) -> EntityCommands<'_>
fn spawn_persisted_with_id<T: Bundle>( &mut self, id: impl Into<String>, bundle: T, ) -> EntityCommands<'_>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".