29.05.2015, 20:22
So Ive made an clickable txd login reg system and I have a problem. When someone tries to login and if he type a wrong password it will open a new dialog saying that he entered the worng password but then when he type another wrong password it will spawn him saying he logged in...
What am I doing wrong?
Код:
if(dialogid == DIALOG_LOGIN) { if ( !response ) return Kick(playerid); if( response ) { new HashPass[129]; WP_Hash(HashPass, sizeof(HashPass), inputtext); if(strcmp(HashPass, PlayerInfo[playerid][pPass]) == 0) { INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid); TogglePlayerSpectating(playerid, 0); SetSpawnInfo( playerid, 0, 0, 1714.8339, -1912.6870, 13.5666, 359.9943, 26, 36, 28, 150, 0, 0 ); SpawnPlayer(playerid); GivePlayerMoney(playerid, PlayerInfo[playerid][pNovac]); }else { ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_PASSWORD,""COL_BIJELA"Balkan Godfather-"COL_ZLATNA"Login",""COL_ZLATNA"_______________________\n\n"COL_BIJELA"Unijeli ste "COL_CRVENA"pogresnu Lozinku!\n\n"COL_BIJELA"Pokusaj "COL_ZLATNA"Ponovo!\n"COL_ZLATNA"_______________________","Uredu","Odustani"); return 1; } } }