]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/weapons/weapon/devastator.qc
Merge branch 'garymoon/show-server-name-in-info' into 'master'
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / weapons / weapon / devastator.qc
index fc42f39d71763909615daaedb2c6790445f1aa51..997f6eb36865648470cf398e2b78294a1ffe1ee1 100644 (file)
@@ -47,7 +47,7 @@ void W_Devastator_Explode(entity this, entity directhitentity)
        if(this.realowner.(weaponentity).m_weapon == thiswep)
        {
                if(GetResource(this.realowner, thiswep.ammo_type) < WEP_CVAR(devastator, ammo))
-               if(!(this.realowner.items & IT_UNLIMITED_WEAPON_AMMO))
+               if(!(this.realowner.items & IT_UNLIMITED_AMMO))
                {
                        this.realowner.cnt = thiswep.m_id;
                        ATTACK_FINISHED(this.realowner, weaponentity) = time;
@@ -143,7 +143,7 @@ void W_Devastator_DoRemoteExplode(entity this, .entity weaponentity)
        if(this.realowner.(weaponentity).m_weapon == thiswep)
        {
                if(GetResource(this.realowner, thiswep.ammo_type) < WEP_CVAR(devastator, ammo))
-               if(!(this.realowner.items & IT_UNLIMITED_WEAPON_AMMO))
+               if(!(this.realowner.items & IT_UNLIMITED_AMMO))
                {
                        this.realowner.cnt = thiswep.m_id;
                        ATTACK_FINISHED(this.realowner, weaponentity) = time;
@@ -401,7 +401,7 @@ METHOD(Devastator, wr_aim, void(entity thiswep, entity actor, .entity weaponenti
         });
         float desirabledamage;
         desirabledamage = enemydamage;
-        if(time > actor.invincible_finished && time > actor.spawnshieldtime)
+        if(time > STAT(INVINCIBLE_FINISHED, actor) && time > actor.spawnshieldtime)
             desirabledamage = desirabledamage - selfdamage * autocvar_g_balance_selfdamagepercent;
         if(teamplay && actor.team)
             desirabledamage = desirabledamage - teamdamage;