fix Nitro not using any power
This commit is contained in:
parent
83cc58c6cd
commit
7ec1cc885b
|
@ -857,7 +857,7 @@ fn handle_wants_acceleration(
|
|||
delta_v =
|
||||
(trans.rotation.inverse() * stop_direction.normalize()).as_dvec3();
|
||||
engine.currently_matching_velocity = true;
|
||||
thruster_on = true;
|
||||
thruster_on = true; // is this redundant?
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -876,6 +876,7 @@ fn handle_wants_acceleration(
|
|||
if delta_v.length_squared() > 0.003 {
|
||||
// Engine is firing!
|
||||
thruster_on = true;
|
||||
engine.currently_firing = true;
|
||||
engine.current_warmup =
|
||||
(engine.current_warmup + dt / engine.warmup_seconds).clamp(0.0, 1.0);
|
||||
|
||||
|
@ -932,6 +933,7 @@ fn handle_wants_acceleration(
|
|||
// Engine is not firing
|
||||
engine.current_warmup =
|
||||
(engine.current_warmup - dt / engine.warmup_seconds).clamp(0.0, 1.0);
|
||||
engine.currently_firing = false;
|
||||
}
|
||||
|
||||
if is_player.is_some() {
|
||||
|
|
Loading…
Reference in a new issue