Here's how i fixed up stubert's b0rked code for wp_disruptor_delay and wp_disruptor_zoomjump:
have the external declarations in g_local.h like u normally would:
Code:
extern vmCvar_t WP_DISRUPTOR_DELAY;
extern vmCvar_t WP_DISRUPTOR_ZOOMJUMP;
do not decalare them at all in cgame...
bg_local.h near the bottom above the include:
Code:
extern vmCvar_t WP_DISRUPTOR_DELAY;
extern vmCvar_t WP_DISRUPTOR_ZOOMJUMP;
now in bg_pmove.c:
inside the #ifdef QAGAME:
Code:
#define PM_DISRUPTOR_DELAY WP_DISRUPTOR_DELAY.integer
#define PM_DISRUPTOR_ZOOMJUMP (WP_DISRUPTOR_ZOOMJUMP.integer & 1)
now replace the #endif with:
Code:
#elif CGAME
#define PM_DISRUPTOR_DELAY 0 // no client mod
#define PM_DISRUPTOR_ZOOMJUMP 0 // no client mod
#endif
the original code for not allowing jump:
Code:
else if (pm->ps->weapon == WP_DISRUPTOR && pm->ps->zoomMode == 1)
{ //can't jump
if (pm->cmd.upmove > 0)
{
pm->cmd.upmove = 0;
}
}
stu's ****ed up code...
Code:
else if (pm->ps->weapon == WP_DISRUPTOR && pm->ps->zoomMode == 1)
{ //can't jump
//stu- THINK AGAIN!! WP_DISRUPTOR_ZOOMJUMP switches it on and off (it's a cvar)
if (pm->cmd.upmove > 0)
{
if (WP_DISRUPTOR_ZOOMJUMP.integer >= 1) //stu- to allows players to jump while zoomed
{
pm->cmd.upmove = 0;
}
}
}
better code to use:
Code:
else if (pm->ps->weapon == WP_DISRUPTOR && pm->ps->zoomMode == 1 && !PM_DISRUPTOR_ZOOMJUMP)
{ //can't jump
if (pm->cmd.upmove > 0)
{
pm->cmd.upmove = 0;
}
}
Now of course you, use your own cvars and do your own sections and this is if the client really is not needed which in this case its not.