Switch to non-deprecated .single_mut() method

This commit is contained in:
2025-07-27 10:31:12 -05:00
parent 88db8a868a
commit f68d841e52

View File

@@ -139,7 +139,7 @@ fn input_ship_thruster(
mut query: Query<(&mut Velocity, &Rotation, &mut Children, &ThrusterColors), With<Ship>>,
mut commands: Commands,
) {
let Ok((mut velocity, rotation, children, colors)) = query.get_single_mut() else {
let Ok((mut velocity, rotation, children, colors)) = query.single_mut() else {
let count = query.iter().count();
panic!("There should be exactly one player ship! Instead, there seems to be {count}.");
};