10.06.2012, 01:35
Change:
To:
pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
if(dialogid == ID_FLIGHT1) {
if(response) {
ShowPlayerDialog(playerid, ID_FLIGHT1, DIALOG_STYLE_INPUT, "Departing from", "Please fill in the field \n\nPlease input the airport you're departing from", "Continue", "Cancel");
ShowPlayerDialog(playerid, ID_FLIGHT2, DIALOG_STYLE_INPUT, "Arriving at", "Please input the airport you're arriving at", "Done", "Cancel");
format(FlightDepart[playerid], sizeof(FlightDepart), "%s", inputtext);
}
}
if(dialogid == ID_FLIGHT2) {
if(response) {
new string[128];
ShowPlayerDialog(playerid, ID_FLIGHT2, DIALOG_STYLE_INPUT, "Arriving at", "~r~Please fill in the field ~w~\n\nPlease input the airport you're arriving at", "Done", "Cancel");
format(FlightArrive[playerid], sizeof(FlightArrive), "%s", inputtext);
format(string, sizeof string, "Flight by %s: Departing From: %s: Arriving At: %s:", PlayersName(playerid), FlightDepart[playerid], FlightArrive[playerid]);
SendClientMessageToAll(COLOR_WHITE, string);
}
}
}
pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
if(dialogid == ID_FLIGHT1) {
if(response) {
ShowPlayerDialog(playerid, ID_FLIGHT1, DIALOG_STYLE_INPUT, "Departing from", "Please fill in the field \n\nPlease input the airport you're departing from", "Continue", "Cancel");
ShowPlayerDialog(playerid, ID_FLIGHT2, DIALOG_STYLE_INPUT, "Arriving at", "Please input the airport you're arriving at", "Done", "Cancel");
format(FlightDepart[playerid], sizeof(FlightDepart), "%s", inputtext);
}
}
return 1;
if(dialogid == ID_FLIGHT2) {
if(response) {
new string[128];
ShowPlayerDialog(playerid, ID_FLIGHT2, DIALOG_STYLE_INPUT, "Arriving at", "~r~Please fill in the field ~w~\n\nPlease input the airport you're arriving at", "Done", "Cancel");
format(FlightArrive[playerid], sizeof(FlightArrive), "%s", inputtext);
format(string, sizeof string, "Flight by %s: Departing From: %s: Arriving At: %s:", PlayersName(playerid), FlightDepart[playerid], FlightArrive[playerid]);
SendClientMessageToAll(COLOR_WHITE, string);
}
}
return 1;
}

