Simple Question
#9

you cant show 2 dialogs in the same momment.

so

you have to do when the player agrees to read the rules.

the login/register box appears.

like that:

pawn Код:
#define C_Rules randomid
#define DIALOG_LOGIN randomid
#define DIALOG_REGISTER randomid

public OnPlayerConnect(playerid)
{
    new BigString[1900];
        strcat(BigString, "\n{FFFFFF}1. {F81414}Respect and obey all Admins.", 1900 );
        strcat(BigString, "\n{FFFFFF}2. {F81414}Do not Deathmatch or Teamkill.", 1900 );
        strcat(BigString, "\n{FFFFFF}3. {F81414}Do not Spam.", 1900 );
        strcat(BigString, "\n{FFFFFF}4. {F81414}Do not use cheats or hacks.", 1900 );
        strcat(BigString, "\n{FFFFFF}5. {F81414}Respect all other players.", 1900 );
        strcat(BigString, "\n{FFFFFF}6. {F81414}******.", 1900 );
        strcat(BigString, "\n{FFFFFF}7. {F81414}Never quit to avoid anything.", 1900 );
        strcat(BigString, "\n{FFFFFF}8. {F81414}********other players.", 1900 );
        strcat(BigString, "\n{FFFFFF}9. {F81414}****.", 1900 );
        strcat(BigString, "\n{FFFFFF}10. {F81414}No mods are allowed.", 1900 );
    ShowPlayerDialog(playerid,C_Rules, DIALOG_STYLE_MSGBOX, "{ff0000}Rules", BigString, "Accept","Ignore");
    //some of your stuffs
}

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
    if(dialogid == C_Rules)
    {
        if(response)
        {
            if(fexist(UserPath(playerid)))
            {
            INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid);
            ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT,"{F81414}San Andreas *****.","{FFFFFF}Welcome, Type your password below to login.\nIf it's not you, relog with a different username","Login","Quit");
            return 1;
            }
            else
            {
                ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_INPUT,"{F81414}San Andreas ********** ","{FFFFFF}Welcome, Type your password below to register a new account.","Register","Quit");
                return 1;
            }
        }
    }
   
    //some of your stuffs
}
Reply


Messages In This Thread
Simple Question - by _Khaled_ - 22.08.2012, 01:46
Re: Simple Question - by Akira297 - 22.08.2012, 01:47
Re: Simple Question - by _Khaled_ - 22.08.2012, 01:50
Re: Simple Question - by _Khaled_ - 22.08.2012, 01:52
Re: Simple Question - by Akira297 - 22.08.2012, 01:54
Re: Simple Question - by _Khaled_ - 22.08.2012, 01:56
Re: Simple Question - by Devilxz97 - 22.08.2012, 01:56
Re: Simple Question - by Akira297 - 22.08.2012, 01:57
Re: Simple Question - by Kirollos - 22.08.2012, 01:57
Re: Simple Question - by Lordzy - 22.08.2012, 01:59

Forum Jump:


Users browsing this thread: 3 Guest(s)