*/
void PlayerJump (void)
{
- if(self.frozen)
- return; // no jumping in freezetag when frozen
-
+ if(self.player_blocked)
+ return; // no jumping while blocked
+
float doublejump = FALSE;
player_multijump = doublejump;
if(MUTATOR_CALLHOOK(PlayerJump))
return;
-
+
doublejump = player_multijump;
float mjumpheight;
-
+
if (autocvar_sv_doublejump)
{
tracebox(self.origin + '0 0 0.01', self.mins, self.maxs, self.origin - '0 0 0.01', MOVE_NORMAL, self);
self.flags &= ~FL_JUMPRELEASED;
animdecide_setaction(self, ANIMACTION_JUMP, TRUE);
-
+
if(autocvar_g_jump_grunt)
PlayerSound(playersound_jump, CH_PLAYER, VOICETYPE_PLAYERSOUND);
}
else
vel_perpend = vel_perpend * max(0, 1 - frametime * wishspeed * sidefric);
-
+
vel_xy = vel_straight * wishdir + vel_perpend;
-
+
if(speedclamp >= 0)
{
float vel_xy_preclamp;
string c;
WarpZone_PlayerPhysics_FixVAngle();
-
+
maxspd_mod = 1;
if(self.ballcarried)
- if(g_nexball)
- maxspd_mod *= autocvar_g_nexball_basketball_carrier_highspeed;
- else if(g_keepaway)
+ if(g_keepaway)
maxspd_mod *= autocvar_g_keepaway_ballcarrier_highspeed;
maxspd_mod *= autocvar_g_movement_highspeed;
return;
bot_think();
}
-
+
self.items &= ~IT_USING_JETPACK;
if(IS_PLAYER(self))
self.disableclientprediction = 0;
if(time < self.ladder_time)
self.disableclientprediction = 1;
-
- if(self.frozen)
+
+ if(time < self.spider_slowness)
{
- if(autocvar_sv_dodging_frozen && IS_REAL_CLIENT(self))
- {
- self.movement_x = bound(-5, self.movement_x, 5);
- self.movement_y = bound(-5, self.movement_y, 5);
- self.movement_z = bound(-5, self.movement_z, 5);
- }
- else
- self.movement = '0 0 0';
- self.disableclientprediction = 1;
+ self.stat_sv_maxspeed *= 0.5; // half speed while slow from spider
+ self.stat_sv_airspeedlimit_nonqw *= 0.5;
}
MUTATOR_CALLHOOK(PlayerPhysics);
if(self.conveyor.state)
self.velocity -= self.conveyor.movedir;
- if not(IS_PLAYER(self))
+ if (!IS_PLAYER(self))
{
maxspd_mod = autocvar_sv_spectator_speed_multiplier;
if(!self.spectatorspeed)
if(self.waterlevel < WATERLEVEL_SWIMMING)
if(time >= self.ladder_time)
- if not(self.hook)
+ if (!self.hook)
{
self.nextstep = time + 0.3 + random() * 0.1;
trace_dphitq3surfaceflags = 0;
tracebox(self.origin, self.mins, self.maxs, self.origin - '0 0 1', MOVE_NOMONSTERS, self);
- if not(trace_dphitq3surfaceflags & Q3SURFACEFLAG_NOSTEPS)
+ if (!(trace_dphitq3surfaceflags & Q3SURFACEFLAG_NOSTEPS))
{
if(trace_dphitq3surfaceflags & Q3SURFACEFLAG_METALSTEPS)
GlobalSound(globalsound_metalfall, CH_PLAYER, VOICETYPE_PLAYERSOUND);
PM_Accelerate(wishdir, wishspeed, wishspeed, autocvar_sv_accelerate*maxspd_mod, 1, 0, 0, 0);
}
}
- else if ((self.items & IT_JETPACK) && self.BUTTON_HOOK && (!autocvar_g_jetpack_fuel || self.ammo_fuel >= 0.01 || self.items & IT_UNLIMITED_WEAPON_AMMO) && !self.frozen)
+ else if ((self.items & IT_JETPACK) && self.BUTTON_HOOK && (!autocvar_g_jetpack_fuel || self.ammo_fuel >= 0.01 || self.items & IT_UNLIMITED_WEAPON_AMMO) && !self.freezetag_frozen)
{
//makevectors(self.v_angle_y * '0 1 0');
makevectors(self.v_angle);
if (f > 0 && wishvel != '0 0 0')
{
self.velocity = self.velocity + wishvel * f * frametime;
- if not(self.items & IT_UNLIMITED_WEAPON_AMMO)
+ if (!(self.items & IT_UNLIMITED_WEAPON_AMMO))
self.ammo_fuel -= autocvar_g_jetpack_fuel * frametime * fvel * f;
self.flags &= ~FL_ONGROUND;
self.items |= IT_USING_JETPACK;
}
}
+ // WEAPONTODO
float xyspeed;
xyspeed = vlen('1 0 0' * self.velocity_x + '0 1 0' * self.velocity_y);
- if(self.weapon == WEP_NEX && autocvar_g_balance_nex_charge && autocvar_g_balance_nex_charge_velocity_rate && xyspeed > autocvar_g_balance_nex_charge_minspeed)
+ if(self.weapon == WEP_VORTEX && WEP_CVAR(vortex, charge) && WEP_CVAR(vortex, charge_velocity_rate) && xyspeed > WEP_CVAR(vortex, charge_minspeed))
{
// add a maximum of charge_velocity_rate when going fast (f = 1), gradually increasing from minspeed (f = 0) to maxspeed
- xyspeed = min(xyspeed, autocvar_g_balance_nex_charge_maxspeed);
- f = (xyspeed - autocvar_g_balance_nex_charge_minspeed) / (autocvar_g_balance_nex_charge_maxspeed - autocvar_g_balance_nex_charge_minspeed);
+ xyspeed = min(xyspeed, WEP_CVAR(vortex, charge_maxspeed));
+ f = (xyspeed - WEP_CVAR(vortex, charge_minspeed)) / (WEP_CVAR(vortex, charge_maxspeed) - WEP_CVAR(vortex, charge_minspeed));
// add the extra charge
- self.nex_charge = min(1, self.nex_charge + autocvar_g_balance_nex_charge_velocity_rate * f * frametime);
+ self.vortex_charge = min(1, self.vortex_charge + WEP_CVAR(vortex, charge_velocity_rate) * f * frametime);
}
:end
if(self.flags & FL_ONGROUND)