public virtual void ResetInput() { Input.Direction = 0; Input.Hook = false; if ((Input.Fire & 1) != 0) { Input.Fire++; } Input.Fire &= SnapObj_PlayerInput.INPUT_STATE_MASK; Input.Jump = false; LatestInput.FillFrom(Input); LatestPrevInput.FillFrom(Input); }
public virtual void OnDirectInput(SnapObj_PlayerInput newInput) { LatestPrevInput.FillFrom(LatestInput); LatestInput.FillFrom(newInput); if (LatestInput.TargetX == 0 && LatestInput.TargetY == 0) { LatestInput.TargetY = -1; } if (NumInputs > 2 && Player.Team != Team.SPECTATORS) { HandleWeaponSwitch(); FireWeapon(); } LatestPrevInput.FillFrom(LatestInput); }