simple script
#2

Quote:

#define DIALOG_CARSELL 9999 //on top

Quote:

ShowPlayerDialog(targetid, DIALOG_CARSELL, DIALOG_STYLE_MSGBOX, "Car sell", string, "Yes", "No"); // after has offered you his car

Quote:

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])// under
{
if(dialogid == DIALOG_CARSELL)
{
if(response) // If they clicked 'Yes' or pressed enter
{
SendClientMessage(playerid, COLOR_GREEN, "Thank you for buying this car!");
}
else // Pressed ESC or clicked cancel
{
SendClientMessage(playerid, COLOR_RED, "You not accepted.");
}
return 1; // We handled a dialog, so return 1. Just like OnPlayerCommandText.
}

return 0; // You MUST return 0 here! Just like OnPlayerCommandText.
}

More info:
https://sampwiki.blast.hk/wiki/ShowPlayerDialog
https://sampwiki.blast.hk/wiki/OnDialogResponse
Reply


Messages In This Thread
simple script - by MatZZPL - 15.11.2012, 21:25
Re: simple script - by Azazelo - 15.11.2012, 21:36
Re: simple script - by MatZZPL - 15.11.2012, 21:42
Re: simple script - by MatZZPL - 15.11.2012, 22:03
Re: simple script - by Faisal_khan - 16.11.2012, 04:51
Re: simple script - by MatZZPL - 16.11.2012, 12:07
Re: simple script - by MatZZPL - 16.11.2012, 14:36
Re: simple script - by MatZZPL - 16.11.2012, 16:03
Re: simple script - by MatZZPL - 16.11.2012, 22:27
Re: simple script - by MatZZPL - 17.11.2012, 15:19

Forum Jump:


Users browsing this thread: 2 Guest(s)