PM_ClientMovement_Unstick();
// set crouched
- if (PHYS_INPUT_BUTTONS(self) & 16)
+ if (PHYS_INPUT_BUTTON_CROUCH(self))
{
// wants to crouch, this always works..
if (!IS_DUCKED(self))
// swimming
UNSET_ONGROUND(self);
- float jump = PHYS_INPUT_BUTTONS(self) & 2;
+ float jump = PHYS_INPUT_BUTTON_JUMP(self);
// water jump only in certain situations
// this mimics quakeworld code
if (jump && self.waterlevel == WATERLEVEL_SWIMMING && self.velocity_z >= -180)
void PM_Main()
{
+ float buttons = PHYS_INPUT_BUTTON_MASK(self);
#ifdef CSQC
//Con_Printf(" %f", PHYS_INPUT_TIMELENGTH);
- if (!(PHYS_INPUT_BUTTONS(self) & 2)) // !jump
+ if (!(PHYS_INPUT_BUTTON_JUMP(self))) // !jump
UNSET_JUMP_HELD(self); // canjump = true
pmove_waterjumptime -= PHYS_INPUT_TIMELENGTH;
PM_ClientMovement_UpdateStatus();
#ifdef SVQC
anticheat_physics();
#endif
- float buttons = PHYS_INPUT_BUTTONS(self);
if (PM_check_specialcommand(buttons))
return;
PM_check_frozen();
-#ifdef SVQC
- MUTATOR_CALLHOOK(PlayerPhysics);
-#endif
-#ifdef CSQC
- PM_dodging();
-#endif
-
PM_check_blocked();
maxspeed_mod = 1;
self.velocity -= self.conveyor.movedir;
#endif
+#ifdef SVQC
+ MUTATOR_CALLHOOK(PlayerPhysics);
+#endif
+// float forcedodge = 1;
+// if(forcedodge) {
+//#ifdef CSQC
+// PM_dodging_checkpressedkeys();
+//#endif
+// PM_dodging();
+// PM_ClientMovement_Move();
+// return;
+// }
+
#ifdef SVQC
if (!IS_PLAYER(self))
{
PM_ladder(maxspeed_mod);
#endif
- else if ((ITEMS(self) & IT_JETPACK) && PHYS_BUTTON_HOOK(self) && (!PHYS_JETPACK_FUEL || PHYS_AMMO_FUEL(self) > 0 || (ITEMS(self) & IT_UNLIMITED_WEAPON_AMMO)) && !PHYS_FROZEN(self))
+ else if ((ITEMS(self) & IT_JETPACK) && PHYS_INPUT_BUTTON_HOOK(self) && (!PHYS_JETPACK_FUEL || PHYS_AMMO_FUEL(self) > 0 || (ITEMS(self) & IT_UNLIMITED_WEAPON_AMMO)) && !PHYS_FROZEN(self))
PM_jetpack(maxspeed_mod);
else
#ifdef CSQC
// jump if on ground with jump button pressed but only if it has been
// released at least once since the last jump
- if (PHYS_INPUT_BUTTONS(self) & 2)
+ if (PHYS_INPUT_BUTTON_JUMP(self))
{
if (IS_ONGROUND(self) && (!IS_JUMP_HELD(self) || !cvar("cl_movement_track_canjump")))
{
}
else
// we REALLY need this handling to happen, even if the move is not executed
- if (!(PHYS_INPUT_BUTTONS(self) & 2)) // !jump
+ if (!(PHYS_INPUT_BUTTON_JUMP(self))) // !jump
UNSET_JUMP_HELD(self); // canjump = true
-
-#ifdef CSQC
- PM_dodging_checkpressedkeys();
- PM_dodging_updatepressedkeys();
-#endif
}
#ifdef SVQC