21.06.2014, 20:58
Why a two-dimensional array when a one-dimensional array would be enough? As far as I see, you do not have to temporarily store the results you get in the for-loop. Aswell, you should make sure to check all slots (0 - 12):
pawn Код:
new weaponData[2];
for(new s = 0; s <= 12; s++) {
GetPlayerWeaponData(playerid, s, weaponData[0], weaponData[1]);
if(weaponData[0] == 38 && weaponData[1] > 100) {
// Player has Minigun with an amount of ammo greater than 100.
}
}