diff options
| author | HampusM <hampus@hampusmat.com> | 2026-06-06 19:21:26 +0200 |
|---|---|---|
| committer | HampusM <hampus@hampusmat.com> | 2026-06-06 19:22:36 +0200 |
| commit | 20f6ccad8af992a739e5ac350ef8b1777de39e35 (patch) | |
| tree | e073def2a34e34a169bc424e86fe2ea2a0b3109a | |
| parent | 7fe8e9ea15fac647fe8655ee096a9aa5703a97c6 (diff) | |
| -rw-r--r-- | engine-ecs/src/lib.rs | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/engine-ecs/src/lib.rs b/engine-ecs/src/lib.rs index 8b3b8c3..6880a24 100644 --- a/engine-ecs/src/lib.rs +++ b/engine-ecs/src/lib.rs @@ -50,7 +50,13 @@ use crate::query::{ use crate::sole::{Single, Sole}; use crate::stats::Stats; use crate::system::observer::Observer; -use crate::system::{Callbacks, Metadata as SystemMetadata, System, SystemComponent}; +use crate::system::{ + Callbacks, + Metadata as SystemMetadata, + Param as SystemParam, + System, + SystemComponent, +}; use crate::uid::Uid; pub mod actions; @@ -625,6 +631,16 @@ impl Default for World } } +impl<'world> SystemParam<'world> for &'world World +{ + type Input = (); + + fn new(world: &'world World, _system_metadata: &SystemMetadata) -> Self + { + world + } +} + /// The result of calling [`World::step`]. pub enum StepResult { |
