#ifdef SVQC
-spawnfunc(weapon_okmachinegun)
-{
- if(autocvar_sv_q3acompat_machineshotgunswap)
- if(this.classname != "droppedweapon")
- {
- weapon_defaultspawnfunc(this, WEP_SHOCKWAVE);
- return;
- }
- weapon_defaultspawnfunc(this, WEP_OVERKILL_MACHINEGUN);
-}
-
void W_OverkillMachineGun_Attack_Auto(Weapon thiswep, entity actor, .entity weaponentity, int fire)
{
float okmachinegun_spread;
#pragma once
CLASS(OverkillMachineGun, Weapon)
+/* spawnfunc */ ATTRIB(OverkillMachineGun, m_canonical_spawnfunc, string, "weapon_okmachinegun");
/* ammotype */ ATTRIB(OverkillMachineGun, ammo_type, int, RESOURCE_BULLETS);
/* impulse */ ATTRIB(OverkillMachineGun, impulse, int, 3);
/* flags */ ATTRIB(OverkillMachineGun, spawnflags, int, WEP_FLAG_RELOADABLE | WEP_TYPE_HITSCAN | WEP_FLAG_PENETRATEWALLS);
ENDCLASS(OverkillMachineGun)
REGISTER_WEAPON(OVERKILL_MACHINEGUN, okmachinegun, NEW(OverkillMachineGun));
+SPAWNFUNC_WEAPON(weapon_okmachinegun, WEP_OVERKILL_MACHINEGUN)
#include "okshotgun.qh"
#ifdef SVQC
-spawnfunc(weapon_okshotgun) { weapon_defaultspawnfunc(this, WEP_OVERKILL_SHOTGUN); }
-
METHOD(OverkillShotgun, wr_aim, void(entity thiswep, entity actor, .entity weaponentity))
{
if (vdist(actor.origin - actor.enemy.origin, >, WEP_CVAR_PRI(okshotgun, bot_range)))
#pragma once
CLASS(OverkillShotgun, Weapon)
+/* spawnfunc */ ATTRIB(OverkillShotgun, m_canonical_spawnfunc, string, "weapon_okshotgun");
/* ammotype */ ATTRIB(OverkillShotgun, ammo_type, int, RESOURCE_SHELLS);
/* impulse */ ATTRIB(OverkillShotgun, impulse, int, 2);
/* flags */ ATTRIB(OverkillShotgun, spawnflags, int, WEP_FLAG_RELOADABLE | WEP_TYPE_HITSCAN);
ENDCLASS(OverkillShotgun)
REGISTER_WEAPON(OVERKILL_SHOTGUN, okshotgun, NEW(OverkillShotgun));
+
+SPAWNFUNC_WEAPON(weapon_okshotgun, WEP_OVERKILL_SHOTGUN)
#endif
#ifdef SVQC
-spawnfunc(weapon_okvortex) { weapon_defaultspawnfunc(this, WEP_OVERKILL_VORTEX); }
-
REGISTER_MUTATOR(okvortex_charge, true);
MUTATOR_HOOKFUNCTION(okvortex_charge, GetPressedKeys)
#pragma once
CLASS(OverkillVortex, Weapon)
+/* spawnfunc */ ATTRIB(OverkillVortex, m_canonical_spawnfunc, string, "weapon_okvortex");
/* ammotype */ ATTRIB(OverkillVortex, ammo_type, int, RESOURCE_CELLS);
/* impulse */ ATTRIB(OverkillVortex, impulse, int, 7);
/* flags */ ATTRIB(OverkillVortex, spawnflags, int, WEP_FLAG_RELOADABLE | WEP_TYPE_HITSCAN);
ENDCLASS(OverkillVortex)
REGISTER_WEAPON(OVERKILL_VORTEX, okvortex, NEW(OverkillVortex));
+
+SPAWNFUNC_WEAPON(weapon_okvortex, WEP_OVERKILL_VORTEX)
set g_random_items_replace_weapon_arc "random" "Classnames to replace arc with."
set g_random_items_replace_weapon_hook "random" "Classnames to replace hook with."
set g_random_items_replace_weapon_tuba "random" "Classnames to replace tuba with."
+set g_random_items_replace_weapon_okshotgun "random" "Classnames to replace overkill shotgun with."
+set g_random_items_replace_weapon_okmachinegun "random" "Classnames to replace overkill machinegun with."
+set g_random_items_replace_weapon_okvortex "random" "Classnames to replace overkill vortex with."
set g_random_items_replace_weapon_porto "random" "Classnames to replace port-o-launch with."
set g_random_items_replace_weapon_fireball "random" "Classnames to replace fireball with."
set g_random_items_replace_weapon_minelayer "random" "Classnames to replace mine layer with."
set g_random_items_weapon_arc_probability 0 "Probability of random arc spawning in the map."
set g_random_items_weapon_hook_probability 0 "Probability of random hook spawning in the map."
set g_random_items_weapon_tuba_probability 0 "Probability of random tuba spawning in the map."
+set g_random_items_weapon_okshotgun_probability 0 "Probability of random overkill shotgun spawning in the map."
+set g_random_items_weapon_okmachinegun_probability 0 "Probability of random overkill machinegun spawning in the map."
+set g_random_items_weapon_okvortex_probability 0 "Probability of random overkill vortex spawning in the map."
set g_random_items_weapon_porto_probability 0 "Probability of random port-o-launch spawning in the map."
set g_random_items_weapon_fireball_probability 0 "Probability of random fireball spawning in the map."
set g_random_items_weapon_minelayer_probability 0 "Probability of random mine layer spawning in the map."
set g_random_loot_weapon_arc_probability 0 "Probability of random arc spawning as loot."
set g_random_loot_weapon_hook_probability 0 "Probability of random hook spawning as loot."
set g_random_loot_weapon_tuba_probability 0 "Probability of random tuba spawning as loot."
+set g_random_loot_weapon_okshotgun_probability 0 "Probability of random overkill shotgun spawning as loot."
+set g_random_loot_weapon_okmachinegun_probability 0 "Probability of random overkill machinegun spawning as loot."
+set g_random_loot_weapon_okvortex_probability 0 "Probability of random overkill vortex spawning as loot."
set g_random_loot_weapon_porto_probability 0 "Probability of random port-o-launch spawning as loot."
set g_random_loot_weapon_fireball_probability 0 "Probability of random fireball spawning as loot."
set g_random_loot_weapon_minelayer_probability 0 "Probability of random mine layer spawning as loot."