06.06.2016, 08:05
Quote:
pawn Код:
|
PHP код:
if(dialogid == 1555)
{
if(!response)
{
SendClientMessage(playerid,red,"Canceled.");
}
else if(response)
{
switch(listitem)
{
case 0:
{
if(Zone[AIRPORT] == TEAM_ZONE_JAPAN_COLOR)
{
SendClientMessage(playerid, green,"Succes Spawn There");
}
}
default: SendClientMessage(playerid, COLOR_RED,"You Are Not Japan");
}
}
}
Example:
PHP код:
ShowPlayerDialog(playerid, DIALOG_TEST, DIALOG_STYLE_LIST, "Select a Location", "Some Location\nAnother Location\nCancel", "Select", "Cancel")
if(dialogid == DIALOG_TEST)
{
switch(listitem)
{
case 0: SetPlayerPos(playerid, 5.0, 4.0, 3.0); // Would be listitem 0, A.K.A "Some Location"
case 1: SetPlayerPos(playerid, 15.0, 14.0, 13.0); // Would be listitem 1, A.K.A "Another Location"
default: return 1; // Would be listitem 2, A.K.A "Cancel"
}
}