]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/mutators/mutator/overkill/okmachinegun.qc
Merge branch 'master' into martin-t/weapon-priority
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / mutators / mutator / overkill / okmachinegun.qc
index aa872f1541a64f052d79d7c73751a6c7e46a984c..768e364a78535f8274516388f47519ed4294da21 100644 (file)
@@ -13,7 +13,7 @@ void W_OverkillMachineGun_Attack_Auto(Weapon thiswep, entity actor, .entity weap
        }
 
        if(!thiswep.wr_checkammo1(thiswep, actor, weaponentity))
-       if(!(actor.items & IT_UNLIMITED_WEAPON_AMMO))
+       if(!(actor.items & IT_UNLIMITED_AMMO))
        {
                W_SwitchWeapon_Force(actor, w_getbestweapon(actor, weaponentity), weaponentity);
                w_ready(thiswep, actor, weaponentity, fire);
@@ -111,7 +111,7 @@ METHOD(OverkillMachineGun, wr_think, void(entity thiswep, entity actor, .entity
 METHOD(OverkillMachineGun, wr_checkammo1, bool(entity thiswep, entity actor, .entity weaponentity))
 {
        float ammo_amount;
-       ammo_amount = GetResourceAmount(actor, thiswep.ammo_type) >= WEP_CVAR_PRI(okmachinegun, ammo);
+       ammo_amount = GetResource(actor, thiswep.ammo_type) >= WEP_CVAR_PRI(okmachinegun, ammo);
        if (WEP_CVAR(okmachinegun, reload_ammo))
        {
                ammo_amount += actor.(weaponentity).(weapon_load[WEP_OVERKILL_MACHINEGUN.m_id]) >= WEP_CVAR_PRI(okmachinegun, ammo);