Need help! (+rep)
#4

Since you aren't really returning anything significant you can use this instead...

pawn Код:
new pGunInfo[MAX_PLAYERS][13];
//We can set these cells to their current ammo cap for each weapon slot.

public IsAtAmmoLimit(playerid)
{
    new weapon[13][2];
    for(new i=0; i < 13; i++)
    {
        GetPlayerWeaponData(playerid, i, weapon[i][0], weapon[i][1]);
        if(weapon[i][1] > pGunInfo[playerid][i]) return true; //this will check if any are above that, then it will return true
    }
    return false; //if none of the weapons have more ammo than their cap it will get to this then return false
}
Reply


Messages In This Thread
Need help! (+rep) - by Medardo4Life - 12.05.2012, 04:09
Re: Need help! (+rep) - by HDFord - 12.05.2012, 06:31
Re: Need help! (+rep) - by Ballu Miaa - 12.05.2012, 06:35
Re: Need help! (+rep) - by [ABK]Antonio - 12.05.2012, 06:55
Re: Need help! (+rep) - by Medardo4Life - 12.05.2012, 07:42
Re: Need help! (+rep) - by [ABK]Antonio - 12.05.2012, 07:47
Re: Need help! (+rep) - by Medardo4Life - 12.05.2012, 07:58
Re: Need help! (+rep) - by [ABK]Antonio - 12.05.2012, 08:16
Re: Need help! (+rep) - by Medardo4Life - 12.05.2012, 08:24
Re: Need help! (+rep) - by [ABK]Antonio - 12.05.2012, 08:38

Forum Jump:


Users browsing this thread: 3 Guest(s)