31.03.2010, 13:19
Hello i have problems with my code as allways.
this time when i registered my acc its all OK,but wheni dissconect and conenct again (relog) and PUT the RIGHT PASSWORD in box it send me a message that i write wrong password,here is my code
this time when i registered my acc its all OK,but wheni dissconect and conenct again (relog) and PUT the RIGHT PASSWORD in box it send me a message that i write wrong password,here is my code
Код:
if(dialogid == 2) // Login Dialog
{
TogglePlayerControllable(playerid, 0);
new name[24], file[128];
GetPlayerName(playerid, name, sizeof(name));
format(file,sizeof(file),"/KA/Users/%s.ini",name);
if(response == 1)
{
if(dini_Int(file, "Password") == udb_hash(inputtext))
{
SetPlayerMoney(playerid, dini_Int(file, "Cash"));
PlayerInfo[playerid][pALevel] = dini_Int(file, "AdminLevel");
SendClientMessage(playerid, 0x00ff41ff, "[System]: You successfuly loged in!");
return 1;
}
else
{
SendClientMessage(playerid, 0xff7000ff, "[System]: You entered wrong password!");
Kick(playerid);
return 1;
}
}
}

