31.05.2014, 17:38
pawn Код:
if(dialogid == LOGIN_DIALOG)
{
if(!response)
{
ShowPlayerDialog(playerid, LOGIN_DIALOG, DIALOG_STYLE_PASSWORD, "Login", "Type in your password", "Login", "Cancel");
}
else
{
new escapedPassword[129];
WP_Hash(escapedPassword, sizeof(escapedPassword), inputtext);
if(!strcmp(escapedPassword,PlayerInfo[playerid][pPass],true))
{
SendClientMessage(playerid, -1, "Incorrect Password Entered - Please try again.");
ShowPlayerDialog(playerid, LOGIN_DIALOG, DIALOG_STYLE_PASSWORD, "Login", "Type in your password", "Login", "Cancel");
}
else
{
format(GlobalString, sizeof(GlobalString), "Welcome "COL_LIGHTBLUE"%s!",GetName(playerid));
SendClientMessage(playerid, -1, GlobalString);
SetSpawnInfo(playerid, 0, PlayerInfo[playerid][pSkin], PlayerInfo[playerid][pPosX], PlayerInfo[playerid][pPosY], PlayerInfo[playerid][pPosZ], PlayerInfo[playerid][pAngle], 0, 0, 0, 0, 0, 0);
SpawnPlayer(playerid);
TogglePlayerSpectating(playerid, false);
}
pawn Код:
new escapedPassword[129];
WP_Hash(escapedPassword, sizeof(escapedPassword), inputtext);
if(!strcmp(escapedPassword,PlayerInfo[playerid][pPass],true))