SA-MP Forums Archive
Problem with registration - 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: Problem with registration (/showthread.php?tid=454666)



Problem with registration - RedJohn - 29.07.2013

Hi. I have problem with user registration.

When I join my server, dialog will be shown, and two buttons "Register" and "Quit", and when I press "Quit" without filling any password I got kick. Which is normal. But in "Users" folder "Name.ini" is created. I would like it like, when I press "Quit" there is no .ini file in "Users" folder. Hope you understood.

pawn Код:
if(dialogid == UserRegister)
    {
        if(!response) return Kick(playerid);
        }
        if(response)
        {
            if(!strlen(inputtext))
            {
                ShowPlayerDialog(playerid, UserRegister, DIALOG_STYLE_INPUT, "Register", "Welcome back to {"DialogRed"}eGaming Roleplay{"DialogText"}.\n\nEnter your password to register.", "Register", "Quit");
                return 1;
            }
            new hashpass[129];
            WP_Hash(hashpass, sizeof(hashpass), inputtext);
            new INI:file = INI_Open(Path(playerid));
            INI_SetTag(file, "Player's Data");
            INI_WriteString(file, "Password", hashpass);
            INI_WriteInt(file,"AdminLevel", 0);
            INI_WriteInt(file,"VIPLevel", 0);
            INI_WriteInt(file,"Money", 0);
            INI_WriteInt(file,"Scores", 0);
            INI_WriteInt(file,"Kills", 0);
            INI_WriteInt(file,"Deaths", 0);
            INI_WriteInt(file, "Skin", -1);
            INI_Close(file);
            SendClientMessage(playerid, YELLOW, "You have been successfully registered.");
            SetPlayerColor(playerid, WHITE);
            return 1;
        }
    }



Re: Problem with registration - RedJohn - 30.07.2013

Bump!


Re: Problem with registration - DobbysGamertag - 30.07.2013

Have you tried https://sampwiki.blast.hk/wiki/Fremove ?


Re: Problem with registration - RedJohn - 30.07.2013

Hmm. No I didn't. Let me try.


Re: Problem with registration - RedJohn - 30.07.2013

Can't make it working.

Register done using this tut: https://sampforum.blast.hk/showthread.php?tid=352703

Can you tell me what should I do?

EDIT: Sorry for double post.


Re: Problem with registration - RedJohn - 01.08.2013

BUMP.


Re: Problem with registration - RedJohn - 02.08.2013

Bumpity bump.