How do you check if a player has ANY weapons?
#1

Hi there,

I am wondering how would you check if a player has a weapon of any kind?

I tried doing this

pawn Код:
Check_Weapons(playerid)
{
    new playerWeaponData[2][13];

    for(new i = 0; i < 13; i++)
    {
        GetPlayerWeaponData(playerid, i, playerWeaponData[0][i], playerWeaponData[1][i]);
       
        if(playerWeaponData[0][i] > 1)
        {
            SendClientMessage(playerid,COLOR_BLUE,"has weapons");
            return 1;
        }
    }

    return 0;
}
This code above ^ didn't work.

Thanks for any help provided <3
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 3 Guest(s)