Whats Wrong ?
#1

Hi guys I make a login register system It was working perfect When I set PInfo,pass as a int but now I change it to string
and its not getting right str and saving "Wrong pass"

pawn Код:
enum pInfo
{
 Password[255],
 pAdminLevel,
 pScore,
 pCash,
 pLPrice,
};

pawn Код:
if(dialogid == 2)
    {
        new name[MAX_PLAYER_NAME], file[128];
        GetPlayerName(playerid, name, sizeof(name));
        format(file, sizeof(file), SERVER_USER_FILE, name);
        if(!response) return Kick(playerid);
        if(!strlen(inputtext))return ShowPlayerDialog(playerid,2,DIALOG_STYLE_INPUT,"Your registered!","Welcome back :P\nPlease sign-in below:","Login","Cancel");
        PlayerInfo[playerid][Password] = dini_Get(file,"Password");
        if(udb_hash(inputtext) != PlayerInfo[playerid][Password])
        {
            SendClientMessage(playerid,RED,"Sorry Wrong Password!");
            ShowPlayerDialog(playerid,2,DIALOG_STYLE_INPUT,"Your registered!","Welcome back :P\nPlease sign-in below:","Login","Cancel");
        }
        else
        {
            OnLogin(playerid, inputtext);
        }
    }

    return 1;
}
Reply


Messages In This Thread
Whats Wrong ? - by iRana - 06.12.2010, 10:32
Re: Whats Wrong ? - by leong124 - 06.12.2010, 10:57
Re: Whats Wrong ? - by Lenny the Cup - 06.12.2010, 12:22
Re: Whats Wrong ? - by Joe_ - 06.12.2010, 13:35
Re: Whats Wrong ? - by iRana - 06.12.2010, 15:39
Re: Whats Wrong ? - by iRana - 07.12.2010, 09:34
Re: Whats Wrong ? - by iRana - 07.12.2010, 10:05

Forum Jump:


Users browsing this thread: 1 Guest(s)