Prevent switch weapons
#2

This is like an example:
- Tought if you want to make it fully support each gun, I'd recommand making a loop with data over them as you chose. And other values. You didn't give us a code to work with, this is the best I can make for you for now.

pawn Код:
new pastWI[MAX_PLAYERS];

OnPlayerConnect(playerid)
{
    pastWI[playerid] = 0;
    return 1;
}

OnPlayerUpdate(playerid)
{
    new weaponid = GetPlayerWeapon(playerid);
    if(weaponid != pastWI[playerid])
    {
         if(pastWI[playerid] == 24 && weaponid == 31)
        {
              SetPlayerArmedWeapon(playerid, 24);
        }
    }
}
Reply


Messages In This Thread
Prevent switch weapons - by JacobWilkerson - 10.08.2013, 18:56
Re: Prevent switch weapons - by BullseyeHawk - 10.08.2013, 19:14
Re : Prevent switch weapons - by JacobWilkerson - 10.08.2013, 19:21
Re: Prevent switch weapons - by BullseyeHawk - 10.08.2013, 19:40
Re: Prevent switch weapons - by dEcooR - 10.08.2013, 19:56

Forum Jump:


Users browsing this thread: 1 Guest(s)