Accepted Rules Detection - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Accepted Rules Detection (
/showthread.php?tid=482581)
Accepted Rules Detection -
[WA]iRonan - 21.12.2013
I am searching for a way to detect if a player has accepted the rules. Doesn't really have to save as I can do that myself, explainments for functions are welcome and eventual credits are given for the script.
- iRonan
Re: Accepted Rules Detection - Patrick - 21.12.2013
pawn Код:
public OnPlayerConnect(playerid) {
return ShowPlayerDialog(playerid, 1, DIALOG_STYLE_MSGBOX, "Title : Rules", "List : Rules", "Button 1", "Button 2");
}
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
switch(dialogid) {
case 1: {
if( !response ) {
SendClientMessage(playerid, -1, "You did not accept the rules.");
}
else {
SendClientMessage(playerid, -1, "You accepted the rules.");
}
}
}
return true;
}
Simple, is not that hard
just create a dialog, and
OnDialogResponse will do its job.
Re: Accepted Rules Detection -
[WA]iRonan - 21.12.2013
I found it already. Iy was different than yours psd2k12