7 float okmachinegun_spread;
11 w_ready(thiswep, actor, weaponentity, fire);
19 w_ready(thiswep, actor, weaponentity, fire);
28 actor.punchangle_x =
random() - 0.5;
29 actor.punchangle_y =
random() - 0.5;
32 okmachinegun_spread =
bound(
WEP_CVAR_PRI(WEP_OVERKILL_MACHINEGUN, spread_min),
WEP_CVAR_PRI(WEP_OVERKILL_MACHINEGUN, spread_min) + (
WEP_CVAR_PRI(WEP_OVERKILL_MACHINEGUN, spread_add) * actor.(weaponentity).misc_bulletcounter),
WEP_CVAR_PRI(WEP_OVERKILL_MACHINEGUN, spread_max));
37 WEP_CVAR(WEP_OVERKILL_MACHINEGUN, damagefalloff_halflife),
38 WEP_CVAR(WEP_OVERKILL_MACHINEGUN, damagefalloff_mindist),
39 WEP_CVAR(WEP_OVERKILL_MACHINEGUN, damagefalloff_maxdist),
42 WEP_CVAR(WEP_OVERKILL_MACHINEGUN, damagefalloff_forcehalflife),
43 WEP_OVERKILL_MACHINEGUN.m_id, EFFECT_RIFLE,
true);
61 if(
vdist(actor.origin - actor.enemy.origin, <, 3000 -
bound(0,
skill, 10) * 200))
67 if ((
WEP_CVAR_SEC(WEP_OVERKILL_MACHINEGUN, refire_type) == 1) && (fire & 2) && (
time >= actor.jump_interval))
73 if ((actor.(weaponentity).wframe == WFRAME_IDLE) ||
74 (actor.(weaponentity).wframe == WFRAME_FIRE2))
77 actor.(weaponentity).
wframe = WFRAME_FIRE2;
79 if (it == actor || (
IS_SPEC(it) && it.enemy == actor))
81 wframe_send(it, actor.(weaponentity), WFRAME_FIRE2, autocvar_g_weaponratefactor, true);
87 if (
WEP_CVAR(WEP_OVERKILL_MACHINEGUN, reload_ammo) && actor.(weaponentity).clip_load <
WEP_CVAR_PRI(WEP_OVERKILL_MACHINEGUN,
ammo))
90 thiswep.wr_reload(thiswep, actor, weaponentity);
103 if ((fire & 2) && (
WEP_CVAR_SEC(WEP_OVERKILL_MACHINEGUN, refire_type) == 0))
119 if (
WEP_CVAR(WEP_OVERKILL_MACHINEGUN, reload_ammo))
138 return WEAPON_THINKING_WITH_PORTALS;
143 return WEAPON_OVERKILL_MACHINEGUN_MURDER;
166 PAR(_(
"The %s quickly fires bullets with a small degree of spread."),
COLORED_NAME(
this));
167 PAR(_(
"Like with all %s weapons, the secondary fire shoots a laser which doesn't damage or push enemies, but can be used to push yourself around."),
COLORED_NAME(MUTATOR_ok));
168 PAR(_(
"The primary fire consumes %s ammo, although you spawn with an infinite amount of it in %s. "
169 "It has a limited magazine size, so needs reloading after several shots."),
COLORED_NAME(ITEM_Bullets),
COLORED_NAME(MUTATOR_ok));
170 PAR(_(
"The %s can be used in a lot of situations, and it works particularly well at long ranges since the bullets pierce the sky instantaneously."),
COLORED_NAME(
this));
void animdecide_setaction(entity e, float action, float restart)
const int ANIMACTION_SHOOT
bool bot_aim(entity this,.entity weaponentity, float shotspeed, float shotspeedupward, float maxshottime, float applygravity, bool shot_accurate)
void W_Blaster_Attack(entity actor,.entity weaponentity)
void SpawnCasing(vector vel, vector ang, int casingtype, entity casingowner,.entity weaponentity)
var entity(vector mins, vector maxs,.entity tofield) findbox_tofield_OrFallback
float GetResource(entity e, Resource res_type)
Returns the current amount of resource the given entity has.
fields which are explicitly/manually set are marked with "M", fields set automatically are marked wit...
virtual void wr_checkammo1()
(SERVER) checks ammo for weapon primary
#define COLORED_NAME(this)
const int IT_UNLIMITED_AMMO
#define PHYS_INPUT_BUTTON_ATCK(s)
float W_WeaponRateFactor(entity this)
void W_SwitchWeapon_Force(Player this, Weapon w,.entity weaponentity)
#define pointparticles(effect, org, vel, howmany)
entity Notification
always last
void W_OverkillMachineGun_Attack_Auto(Weapon thiswep, entity actor,.entity weaponentity, int fire)
#define METHOD(cname, name, prototype)
#define w_getbestweapon(ent, wepent)
#define sound(e, c, s, v, a)
#define PAR(...)
Adds an individually translatable paragraph to PAGE_TEXT without having to deal with strcat and sprin...
void fireBullet_falloff(entity this,.entity weaponentity, vector start, vector dir, float spread, float max_solid_penetration, float damage, float falloff_halflife, float falloff_mindist, float falloff_maxdist, float headshot_multiplier, float force, float falloff_forcehalflife, float dtype, entity tracer_effect, bool do_antilag)
#define W_SetupShot(ent, wepent, antilag, recoil, snd, chan, maxdamage, deathtype)
#define FOREACH_CLIENT(cond, body)
#define vdist(v, cmp, f)
Vector distance comparison, avoids sqrt()
string W_Guide_Keybinds(Weapon wep)
void W_MuzzleFlash(Weapon thiswep, entity actor,.entity weaponentity, vector shotorg, vector shotdir)
string W_Guide_DPS_onlyOne(string name, string fire)
#define WEP_CVAR_PRI(wep, name)
#define WEP_CVAR(wep, name)
#define WEP_CVAR_SEC(wep, name)
void W_DecreaseAmmo(Weapon wep, entity actor, float ammo_use,.entity weaponentity)
void W_Reload(entity actor,.entity weaponentity, float sent_ammo_min, Sound sent_sound)
void weapon_thinkf(entity actor,.entity weaponentity, WFRAME fr, float t, void(Weapon thiswep, entity actor,.entity weaponentity, int fire) func)
bool weapon_prepareattack(Weapon thiswep, entity actor,.entity weaponentity, bool secondary, float attacktime)
void w_ready(Weapon thiswep, entity actor,.entity weaponentity, int fire)
#define ATTACK_FINISHED(ent, w)
float weapon_load[REGISTRY_MAX(Weapons)]