[Ayuda] Hacer que solo elijan skin los que no estan registrados.
#3

Podrнas comprobar si existe o no la cuenta. Serнa algo asн...

pawn Код:
public OnPlayerRequestClass(playerid, classid)
{
    new query[200], nombre[MAX_PLAYER_NAME];
    GetPlayerName(playerid, nombre, sizeof(nombre));
    format(query, sizeof(query), "SELECT IP FROM `playerdata` WHERE user = '%s' LIMIT 1", nombre);
    mysql_query(query);
    mysql_store_result();
    if(mysql_num_rows()) SpawnPlayer(playerid);
    SetPlayerPos(playerid, 2370.5166,2165.1321,26.9844);
    SetPlayerCameraPos(playerid, 2374.5188,2169.5798,26.9844);
    SetPlayerCameraLookAt(playerid, 2370.5166,2165.1321,26.9844);
    SetPlayerFacingAngle(playerid,315.9228);
    ApplyAnimation(playerid,"DANCING","dnce_M_b",4.1,7,5,1,1,1);
    return 1;
}
Entonces, si la cuenta existe lo Spawnea directamente.

PD: No lo probй, pero deberнa funcionar.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 2 Guest(s)