26.10.2010, 16:57
Are you sure this part is right:
Also, I'd suggest first checking player's job, then launching the loop if the job is correct (not like you're doing - checking the job every loop tick). Plus breaking the loop when found the correct vehicle id wouldn't hurt.
Edit: Maybe I should learn to write faster.
pawn Код:
PlayerInfo[playerid][pJob] != 1
pawn Код:
if(PlayerInfo[playerid][pJob] != 1)
{
for(new i = 0; i <MAX_PIZZABIKES; i++)
{
if(vehicleid == PizzaJobVehicles[i])
{
SendClientMessage(playerid, COLOR_RED, "You don't have the keys of this Vehicle");
SendClientMessage(playerid, COLOR_RED, "So you decide to step off the Pizzaboy");
RemovePlayerFromVehicle(playerid);
break; // Kill the loop.
}
}
}