string checkmodel_input, checkmodel_command;
MUTATOR_HOOKABLE(GetModelParams, EV_GetModelParams);
+/** called when a player presses the jump key */
+#define EV_PlayerJump(i, o) \
+ /**/ i(float, player_multijump) \
+ /**/ i(float, player_jumpheight) \
+ /**/ o(float, player_multijump) \
+ /**/ o(float, player_jumpheight) \
+ /**/
+float player_multijump;
+float player_jumpheight;
+MUTATOR_HOOKABLE(PlayerJump, EV_PlayerJump);
+
#endif
bool doublejump = false;
float mjumpheight = PHYS_JUMPVELOCITY;
-
-#ifdef SVQC
- if (MUTATOR_CALLHOOK(PlayerJump, doublejump, mjumpheight))
-#elif defined(CSQC)
+#ifdef CSQC
player_multijump = doublejump;
player_jumpheight = mjumpheight;
- if (PM_multijump_checkjump())
#endif
- return true;
+
+ if (MUTATOR_CALLHOOK(PlayerJump, doublejump, mjumpheight)
+#ifdef CSQC
+ || PM_multijump_checkjump()
+#endif
+ ) { return true; }
doublejump = player_multijump;
mjumpheight = player_jumpheight;
#define IS_PLAYER(s) (s).isplayermodel
#define isPushable(s) (s).isplayermodel
- float player_multijump;
- float player_jumpheight;
+ //float player_multijump;
+ //float player_jumpheight;
#define PHYS_INPUT_ANGLES(s) input_angles
// TODO