From a44e663eb6d4aaf567dd35f2676014ba5aaa9e00 Mon Sep 17 00:00:00 2001 From: HampusM Date: Sun, 5 Jan 2025 22:03:34 +0100 Subject: feat(ecs): allow control over component mutability in query --- ecs/examples/with_sole.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ecs/examples/with_sole.rs') diff --git a/ecs/examples/with_sole.rs b/ecs/examples/with_sole.rs index 47aa0b3..689e562 100644 --- a/ecs/examples/with_sole.rs +++ b/ecs/examples/with_sole.rs @@ -15,7 +15,7 @@ struct AmmoCounter counter: u32, } -fn count_ammo(query: Query<(Ammo,)>, mut ammo_counter: Single) +fn count_ammo(query: Query<(&Ammo,)>, mut ammo_counter: Single) { for (ammo,) in &query { println!("Found {} ammo", ammo.ammo_left); -- cgit v1.2.3-18-g5258