if(self.runes & RUNE_SPEED)
{
if(self.runes & CURSE_SLOW)
- t = t * cvar("g_balance_rune_speed_combo_atkrate");
+ t = t * autocvar_g_balance_rune_speed_combo_atkrate;
else
- t = t * cvar("g_balance_rune_speed_atkrate");
+ t = t * autocvar_g_balance_rune_speed_atkrate;
}
else if(self.runes & CURSE_SLOW)
{
- t = t * cvar("g_balance_curse_slow_atkrate");
+ t = t * autocvar_g_balance_curse_slow_atkrate;
}
}
if (antilag)
if (!ent.cvar_cl_noantilag)
{
- if (cvar("g_antilag") == 1) // switch to "ghost" if not hitting original
+ if (autocvar_g_antilag == 1) // switch to "ghost" if not hitting original
{
traceline(w_shotorg, w_shotorg + w_shotdir * range, MOVE_NORMAL, ent);
if (!trace_ent.takedamage)
}
}
}
- else if(cvar("g_antilag") == 3) // client side hitscan
+ else if(autocvar_g_antilag == 3) // client side hitscan
{
// this part MUST use prydon cursor
if (ent.cursor_trace_ent) // client was aiming at someone
if(ent.items & IT_STRENGTH)
if(!g_minstagib)
if(
- (time > ent.prevstrengthsound + cvar("sv_strengthsound_antispam_time"))
+ (time > ent.prevstrengthsound + autocvar_sv_strengthsound_antispam_time)
||
- (time > ent.prevstrengthsoundattempt + cvar("sv_strengthsound_antispam_refire_threshold"))
+ (time > ent.prevstrengthsoundattempt + autocvar_sv_strengthsound_antispam_refire_threshold)
) // prevent insane sound spam
{
sound(ent, CHAN_AUTO, "weapons/strength_fire.wav", VOL_BASE, ATTN_NORM);
f = 0;
if (self.state == WS_RAISE && !intermission_running)
{
- f = (self.owner.weapon_nextthink - time) * g_weaponratefactor / cvar("g_balance_weaponswitchdelay");
+ f = (self.owner.weapon_nextthink - time) * g_weaponratefactor / autocvar_g_balance_weaponswitchdelay;
self.angles_x = -90 * f * f;
if (qcweaponanimation)
{
}
else if (self.state == WS_DROP && !intermission_running)
{
- f = 1 - (self.owner.weapon_nextthink - time) * g_weaponratefactor / cvar("g_balance_weaponswitchdelay");
+ f = 1 - (self.owner.weapon_nextthink - time) * g_weaponratefactor / autocvar_g_balance_weaponswitchdelay;
self.angles_x = -90 * f * f;
if (qcweaponanimation)
{
sprint(cl, strcat("You do not have the ^2", W_Name(wpn), "\n") );
Send_WeaponComplain (cl, wpn, W_Name(wpn), 1);
- if(cvar("g_showweaponspawns"))
+ if(autocvar_g_showweaponspawns)
{
entity e;
string s;
void weapon_setup(float windex)
{
entity e;
- qcweaponanimation = cvar("sv_qcweaponanimation");
+ qcweaponanimation = autocvar_sv_qcweaponanimation;
e = get_weaponinfo(windex);
self.items &~= IT_AMMO;
self.items = self.items | e.items;
mdirection = normalize(mvelocity);
mspeed = vlen(mvelocity);
- nstyle = cvar("g_projectiles_newton_style");
+ nstyle = autocvar_g_projectiles_newton_style;
if(nstyle == 0 || forceAbsolute)
{
// absolute velocity
//dprint("impossible shot, adjusting\n");
}
- outspeed = bound(mspeed * cvar("g_projectiles_newton_style_2_minfactor"), outspeed, mspeed * cvar("g_projectiles_newton_style_2_maxfactor"));
+ outspeed = bound(mspeed * autocvar_g_projectiles_newton_style_2_minfactor, outspeed, mspeed * autocvar_g_projectiles_newton_style_2_maxfactor);
outvelocity = mdirection * outspeed;
}
else if(nstyle == 3)
spread *= g_weaponspreadfactor;
if(spread <= 0)
return forward;
- sstyle = cvar("g_projectiles_spread_style");
+ sstyle = autocvar_g_projectiles_spread_style;
if(sstyle == 0)
{
dir = normalize(dir);
#if 0
- if(cvar("g_projectiles_spread_style") != mspercallsstyle)
+ if(autocvar_g_projectiles_spread_style != mspercallsstyle)
{
mspercallsum = mspercallcount = 0;
- mspercallsstyle = cvar("g_projectiles_spread_style");
+ mspercallsstyle = autocvar_g_projectiles_spread_style;
}
mspercallsum -= gettime(GETTIME_HIRES);
#endif