3AUTOCVAR(g_smneg,
bool,
false,
"enable stale-move negation, penalizing repeated use of the same weapon");
4AUTOCVAR(g_smneg_bonus,
bool,
true,
"allow weapons to become stronger than their baseline");
5AUTOCVAR(g_smneg_bonus_asymptote,
float, 4,
"stale-move negation damage is infinity at this bonus level");
6AUTOCVAR(g_smneg_cooldown_factor,
float, 1 / 4,
"stale-move negation penalty cooldown factor");
20 float a = autocvar_g_smneg_bonus_asymptote;
22 (!autocvar_g_smneg_bonus ? 0 : (-a + .1)),
25 float z = (
M_PI / 5) * a;
27 ? (atan(z / x) / (
M_PI / 2))
28 : (tan(-(x / z)) + 1);
33 float deathtype =
M_ARGV(3,
float);
35 if (w == WEP_Null)
return;
39 float weight = c.x_smneg_weight[w.
m_id];
45 float restore =
frag_damage * autocvar_g_smneg_cooldown_factor;
47 c.x_smneg_weight[it.m_id] -= restore;
#define REGISTER_MUTATOR(...)
#define MUTATOR_HOOKFUNCTION(...)
var entity(vector mins, vector maxs,.entity tofield) findbox_tofield_OrFallback
fields which are explicitly/manually set are marked with "M", fields set automatically are marked wit...
#define DEATH_WEAPONOF(t)
#define FOREACH(list, cond, body)
strcat(_("^F4Countdown stopped!"), "\n^BG", _("Teams are too unbalanced."))
ClientState CS(Client this)
float x_smneg_weight[REGISTRY_MAX(Weapons)]
float smneg_multiplier(float weight)