fn move_system(time: Res<Time>, mut q: Query<(&Velocity, &mut Transform)>) {
    let delta = time.delta_seconds();

    for (v, mut t) in q.iter_mut() {
        t.translation += delta * v.translation;
        t.rotate(Quat::from_rotation_z(v.rotation * delta));
    }
}
/// Apply velocity to positions and rotations.
Apply velocity to positions and rotations.
Apply velocity to positions and rotations .
fn move_system(time: Res<Time>, mut q: Query<(&Velocity, &mut Transform)>) {
    let delta = time.delta_seconds();
    for (v, mut t) in q.iter_mut() {
        t.translation += delta * v.translation;
        t.rotate(Quat::from_rotation_z(v.rotation * delta));
    }
}
fn move_system ( time : Res < Time > , mut q : Query < ( & Velocity , & mut Transform ) > ) { let delta = time . delta_seconds ( ) ; for ( v , mut t ) in q . iter_mut ( ) { t . translation += delta * v . translation ; t . rotate ( Quat :: from_rotation_z ( v . rotation * delta ) ) ; } }
Apply velocity to positions and rotations.
Apply velocity to positions and rotations .
time
Res<Time>
q
Query<(&Velocity, &mut Transform)>
time
Res<Time>
q
Query<(&Velocity, &mut Transform)>