]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Electro: remove leftover code from wr_resetplayer that now doesn't work as intended
authorterencehill <piuntn@gmail.com>
Sun, 12 Sep 2021 17:24:40 +0000 (19:24 +0200)
committerterencehill <piuntn@gmail.com>
Sun, 12 Sep 2021 17:24:40 +0000 (19:24 +0200)
qcsrc/common/weapons/weapon/electro.qc

index cd577e1e45103118fc1929caeab091981d8d1700..c2ec43e8c374bddbdb917343ce44f98b1a08a42e 100644 (file)
@@ -527,8 +527,8 @@ METHOD(Electro, wr_think, void(entity thiswep, entity actor, .entity weaponentit
         if(time >= actor.(weaponentity).electro_secondarytime + WEP_CVAR_SEC(electro, refire2) * W_WeaponRateFactor(actor))
         if(weapon_prepareattack(thiswep, actor, weaponentity, false, WEP_CVAR_PRI(electro, refire)))
         {
-                W_Electro_Attack_Bolt(thiswep, actor, weaponentity);
-                weapon_thinkf(actor, weaponentity, WFRAME_FIRE1, WEP_CVAR_PRI(electro, animtime), w_ready);
+            W_Electro_Attack_Bolt(thiswep, actor, weaponentity);
+            weapon_thinkf(actor, weaponentity, WFRAME_FIRE1, WEP_CVAR_PRI(electro, animtime), w_ready);
         }
     }
     else if(fire & 2)
@@ -564,14 +564,6 @@ METHOD(Electro, wr_checkammo2, bool(entity thiswep, entity actor, .entity weapon
     }
     return ammo_amount;
 }
-METHOD(Electro, wr_resetplayer, void(entity thiswep, entity actor))
-{
-    for(int slot = 0; slot < MAX_WEAPONSLOTS; ++slot)
-    {
-       .entity weaponentity = weaponentities[slot];
-       actor.(weaponentity).electro_secondarytime = time;
-    }
-}
 METHOD(Electro, wr_reload, void(entity thiswep, entity actor, .entity weaponentity))
 {
     W_Reload(actor, weaponentity, min(WEP_CVAR_PRI(electro, ammo), WEP_CVAR_SEC(electro, ammo)), SND_RELOAD);