19.04.2013, 14:16
probalo asн
otra cosa, se crashea cuando colocas bien la contraseсa o auque la coloques mal?
pawn Код:
public CargarDatosUsuario(playerid)
{
new rows,fields;
cache_get_data(rows, fields);
if(rows > 0) {
TogglePlayerControllable(playerid, 1);
new temp[40];
cache_get_row(0, 3, temp), PlayerInfo[playerid][Admin] = strval(temp),
cache_get_row(0, 4, temp), PlayerInfo[playerid][Asesinatos] = strval(temp),
cache_get_row(0, 5, temp), PlayerInfo[playerid][Muertes] = strval(temp),
cache_get_row(0, 6, temp), PlayerInfo[playerid][Vip] = strval(temp),
cache_get_row(0, 7, temp), PlayerInfo[playerid][Dinero] = strval(temp),
cache_get_row(0, 8, temp), PlayerInfo[playerid][Advertencias] = strval(temp),
cache_get_row(0, 9, temp), PlayerInfo[playerid][Skin] = strval(temp),
cache_get_row(0, 10, temp), PlayerInfo[playerid][AutoID] = strval(temp),
cache_get_row(0, 11, temp), PlayerInfo[playerid][PosX] = floatstr(temp),
cache_get_row(0, 12, temp), PlayerInfo[playerid][PosY] = floatstr(temp),
cache_get_row(0, 13, temp), PlayerInfo[playerid][PosZ] = floatstr(temp),
cache_get_row(0, 14, temp), PlayerInfo[playerid][PosA] = floatstr(temp),
cache_get_row(0, 15, temp), PlayerInfo[playerid][Banco] = strval(temp),
cache_get_row(0, 16, temp), PlayerInfo[playerid][DuelosG] = strval(temp),
cache_get_row(0, 17, temp), PlayerInfo[playerid][DuelosP] = strval(temp),
cache_get_row(0, 18, temp), PlayerInfo[playerid][CarrerasG] = strval(temp),
cache_get_row(0, 19, temp), PlayerInfo[playerid][CarrerasP] = strval(temp),
cache_get_row(0, 20, temp), PlayerInfo[playerid][Baneado] = strval(temp);
SetPlayerScore(playerid, PlayerInfo[playerid][Asesinatos]);
DarDinero(playerid, PlayerInfo[playerid][Dinero]);
}
else {
SendClientMessage(playerid,-1,"Ha ocurrido un error al cargar los datos");
}
return 1;
}