19.01.2012, 23:22
Basically, but if you have an if() and more than one statement after it, you need to use brackets
I added "||", which is an OR
pawn Код:
public OnPlayerStateChange(playerid, newstate, oldstate)
{
if(oldstate == PLAYER_STATE_ONFOOT && newstate == PLAYER_STATE_DRIVER)
{
new vehicle = GetPlayerVehicleID(playerid);
if(vehicle == 25 || vehicle == 26 || vehicle == 27)
{
ShowPlayerDialog(playerid, TRUCKINGDIALOG, DIALOG_STYLE_LIST, "Choose a destination.", "From here to LV Depot /*(listitem 0)*/ \nFrom here to Ocean Docks /*(listitem 1)*/ \nFrom here to Verona/*(listitem 2)*/", "Ok", "Cancel Job");
}
}
return 1;
}