]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/w_minstanex.qc
Share the final reload code that comes to mind. The reload code is for the most part...
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / w_minstanex.qc
index 567e4fa100a97f2185ea7f8d5bd3bd1856f118b9..267bc2547fd4c955b9be022e904e0a24eadec280 100644 (file)
@@ -1,21 +1,9 @@
 #ifdef REGISTER_WEAPON
-REGISTER_WEAPON(MINSTANEX, w_minstanex, IT_CELLS, 7, WEP_FLAG_HIDDEN | WEP_FLAG_CANCLIMB | WEP_TYPE_HITSCAN, BOT_PICKUP_RATING_HIGH, "minstanex", "minstanex", _("MinstaNex"))
+REGISTER_WEAPON(MINSTANEX, w_minstanex, IT_CELLS, 7, WEP_FLAG_HIDDEN | WEP_FLAG_RELOADABLE | WEP_FLAG_CANCLIMB | WEP_TYPE_HITSCAN, BOT_PICKUP_RATING_HIGH, "minstanex", "minstanex", _("MinstaNex"))
 #else
 #ifdef SVQC
 .float minstanex_lasthit;
 
-void W_Minstanex_SetAmmoCounter()
-{
-       // set clip_load to the weapon we have switched to, if the gun uses reloading
-       if(!autocvar_g_balance_minstanex_reload_ammo)
-               self.clip_load = 0; // also keeps crosshair ammo from displaying
-       else
-       {
-               self.clip_load = self.weapon_load[WEP_MINSTANEX];
-               self.clip_size = autocvar_g_balance_minstanex_reload_ammo; // for the crosshair ammo display
-       }
-}
-
 void W_Minstanex_Reload()
 {
        self.reload_ammo_player = ammo_cells;
@@ -280,7 +268,6 @@ float w_minstanex(float req)
        else if (req == WR_SETUP)
        {
                weapon_setup(WEP_MINSTANEX);
-               W_Minstanex_SetAmmoCounter();
                self.minstanex_lasthit = 0;
        }
        else if (req == WR_CHECKAMMO1)