Can i use MAX_PLAYERS for Pickup Ids?
#4

Well you can just use a loop:

pawn Код:
public OnPlayerPickupPickup(playerid, pickupid)
{
    for(new x=0; x<MAX_PLAYERS; x++)
    {
        if(pickupid == Pickupid[x])
        {
            //Do something here
            break; //Stop the loop
        }
    }
    return 1;
}
Reply


Messages In This Thread
Can i use MAX_PLAYERS for Pickup Ids? - by almighty - 08.08.2010, 20:20
Re: Can i use MAX_PLAYERS for Pickup Ids? - by Zamaroht - 08.08.2010, 21:10
Re: Can i use MAX_PLAYERS for Pickup Ids? - by almighty - 08.08.2010, 21:39
Re: Can i use MAX_PLAYERS for Pickup Ids? - by PotH3Ad - 09.08.2010, 00:13
Re: Can i use MAX_PLAYERS for Pickup Ids? - by almighty - 09.08.2010, 16:43

Forum Jump:


Users browsing this thread: 1 Guest(s)