keep cruise control going when the game is not focused

This commit is contained in:
yuni 2024-05-15 15:07:07 +02:00
parent e801f3ac02
commit a99ce596d7

View file

@ -429,6 +429,10 @@ pub fn apply_input_to_player(
axis_input += 1.0 * DVec3::from(player_transform.rotation.inverse() * stop_direction.as_vec3());
}
}
} else {
if settings.cruise_control_active {
axis_input.z += 1.2;
}
}
// In typical games we would normalize the input vector so that diagonal movement is as
// fast as forward or sideways movement. But here, we merely clamp each direction to an