]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/mutators/mutator_instagib.qc
#includes: cleanup server
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / mutators / mutator_instagib.qc
index 67be0829099d6ceb60955fa36a9426e538b4ebf3..dc1d0eba54dc1c710119ed7e68dd512b17240dff 100644 (file)
@@ -1,14 +1,13 @@
-#include "../_all.qh"
 
 #include "mutator.qh"
 
 #include "../cl_client.qh"
-#include "../../common/buffs.qh"
+#include "../../common/buffs/all.qh"
 
 #include "../../common/items/all.qc"
 
-void spawnfunc_item_minst_cells()
-{SELFPARAM();
+spawnfunc(item_minst_cells)
+{
        if (!g_instagib) { remove(self); return; }
        if (!self.ammo_cells) self.ammo_cells = autocvar_g_instagib_ammo_drop;
        StartItemA(ITEM_VaporizerCells);
@@ -229,6 +228,8 @@ MUTATOR_HOOKFUNCTION(instagib_PlayerPowerups)
        return false;
 }
 
+.float stat_sv_maxspeed;
+
 MUTATOR_HOOKFUNCTION(instagib_PlayerPhysics)
 {SELFPARAM();
        if(self.items & ITEM_Speed.m_itemid)
@@ -333,7 +334,7 @@ MUTATOR_HOOKFUNCTION(instagib_SetStartItems)
        start_ammo_rockets = warmup_start_ammo_rockets = 0;
        start_ammo_fuel    = warmup_start_ammo_fuel    = 0;
 
-       start_weapons = warmup_start_weapons = WEPSET_VAPORIZER;
+       start_weapons = warmup_start_weapons = WEPSET(VAPORIZER);
        start_items |= IT_UNLIMITED_SUPERWEAPONS;
 
        return false;
@@ -357,7 +358,7 @@ MUTATOR_HOOKFUNCTION(instagib_FilterItem)
                e.noalign = self.noalign;
         e.cnt = self.cnt;
         e.team = self.team;
-               WITH(entity, self, e, spawnfunc_item_minst_cells());
+               WITH(entity, self, e, spawnfunc_item_minst_cells(e));
                return true;
        }