How To: Log if a player has accepted my server rules connect message...
#1

Okay, so I have made this dialog appear when a player connects to my server:

pawn Code:
ShowPlayerDialog(playerid, 1, DIALOG_STYLE_MSGBOX, "Some Simple Rules You Need To Follow...", "Cheating Will Result In An IP Ban. In This Case, You Will Not Be Un-Banned!\nRespect Everyone and Everyones' Property!\nAdministators Are The Boss, Do Not Second Guess Them!\nIf You Ignore An Admin, The Admin Can/Will Ban You, It's Up To Them!\nDo Not Ask The Admins/Moderators' To Do Things For You!\nConsider Yourself Warned!", "I Agree", "I Disagree");
This is what happens when the choose "I Agree" or "I Disagree":

pawn Code:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
    if(dialogid == 1)
    {
        if(response)
        {
        new string[250];
        format(string, sizeof(string), "~g~Welcome ~w~To The ~p~Future ~w~Of ~r~SA:MP ~w~Gaming!");
        GameTextForPlayer(playerid, string, 5000, 4);
        }
        else
        {
        new string[300];
        format(string, sizeof(string), "/n/n~w~You Selected ~b~Quit, ~w~Therefore You Were ~r~Kicked! ~w~Goodbye!");
        GameTextForPlayer(playerid, string, 999999999, 4);
        Kick(playerid);
        }
        return 1;
    }
    return 0;
}
How could I make it so if they click "I Agree", they do not have to click it every time they join the server? Also how to add a command that only Admins can use that will make that player read that dialog box again... Thanks!
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)