Uncontrollable state, not unconscious. Also cause controllable state to stop movement physics

Co-authored-by: r3cp3ct <45179536+r3cp3ct@users.noreply.github.com>
Co-authored-by: sigonasr2 <sigonasr2@gmail.com>
main
sigonasr2, Sig, Sigo 3 years ago
parent ebbbabd7d0
commit a1fec557a3
  1. 6
      src/sig/objects/actor/PhysicsObject.java

@ -56,7 +56,7 @@ public abstract class PhysicsObject extends AnimatedObject implements PhysicsObj
} }
protected void handleMovementPhysics(double updateMult) { protected void handleMovementPhysics(double updateMult) {
if (state==State.STAGGER) { if (state==State.STAGGER||state==State.UNCONTROLLABLE) {
return; return;
} }
int right = rightKeyHeld()?1:0; int right = rightKeyHeld()?1:0;
@ -225,9 +225,9 @@ public abstract class PhysicsObject extends AnimatedObject implements PhysicsObj
} }
/** /**
* Sets how long this object will remain in the unconscious state. * Sets how long this object will remain in the uncontrollable state.
* Automatically resets the state to the previous state the object * Automatically resets the state to the previous state the object
* was in when the unconscious state completes. * was in when the uncontrollable state completes.
* @param duration Amount of time in seconds. * @param duration Amount of time in seconds.
* */ * */
public void setUncontrollable(double duration) { public void setUncontrollable(double duration) {

Loading…
Cancel
Save