Welcome, Guest
You have to register before you can post on our site.

Username
  

Password
  





Search Forums



(Advanced Search)

Forum Statistics
» Members: 7,243
» Latest member: AJ371
» Forum threads: 2,375
» Forum posts: 12,284

Full Statistics

Online Users
There are currently 361 online users.
» 0 Member(s) | 358 Guest(s)
Bing, Google, Applebot

Latest Threads
EVO Anti-Cheat
Forum: Libraries
Last Post: Eduardo_AC
5 hours ago
» Replies: 0
» Views: 11
Developer for Hire – Syst...
Forum: Pawn Scripting
Last Post: ejtamovic
Yesterday, 08:35 AM
» Replies: 0
» Views: 35
Liberty City map
Forum: Pawn Scripting
Last Post: ziyadprogamer
2025-06-28, 04:55 PM
» Replies: 2
» Views: 2,166
GameText styles in open.m...
Forum: Pawn Scripting
Last Post: Miki
2025-06-28, 01:25 PM
» Replies: 1
» Views: 53
Script[gamemodes/gamemode...
Forum: Pawn Scripting
Last Post: Miki
2025-06-27, 05:08 PM
» Replies: 1
» Views: 433
Want to edit my profile n...
Forum: Chat
Last Post: Hera.
2025-06-26, 08:41 PM
» Replies: 1
» Views: 571
Farsi
Forum: Other
Last Post: acc.gangbeni
2025-06-25, 08:21 AM
» Replies: 2
» Views: 3,074
Las Venturas Gang Wars - ...
Forum: Advertisements
Last Post: lvgwgta
2025-06-22, 06:47 PM
» Replies: 0
» Views: 65
[Request] Linko Gaming Ro...
Forum: General Discussions
Last Post: JamesC
2025-06-20, 07:34 PM
» Replies: 0
» Views: 82
RevolutionX DM/Stunt/Race...
Forum: Advertisements
Last Post: DerekZ905
2025-06-18, 03:12 PM
» Replies: 0
» Views: 94

 
  Acks limit
Posted by: Lorenzo - 2020-11-11, 02:40 PM - Forum: Pawn Scripting - No Replies

Hi, I'm trying to understand more about this topic because I can't find anything online.

Sometimes after death only for some players happens that they being banned for reaching the acks limit of 5000/sec. But it's not a deterministic thing and happens randomly. I tried testing?to?figuring out the problem but nothing.?

There is something to avoid inside the OnPlayerSpawn or OnPlayerDeath callbacks? Or could be also related to a server network issue because I'm using a very cheap VPS with low specs?

I'm using the 0.3DL with a lot of models and maps loaded, I don't know if could be part of the problem.


  Help with kill streack
Posted by: DaZzY - 2020-11-11, 02:07 PM - Forum: Pawn Scripting - Replies (4)

Hello?

i have kill streack on my server and i want to show a message who end a kill streack of someone?

example ( player1?ended streack of players 2 )



Quote:public OnPlayerDeath(playerid,killerid,reason)

{

new str[128];

new name[32];

GetPlayerName(killerid,name,32);





killstreak[killerid];

killstreak[playerid] = 0;





switch(killstreak[killerid])

{



case 3:

{



format(str,sizeof(str),""RED"[DM]"ORANGE" %s "GREY"is now "WHITE"Killing Spree"GREY"!!",name);

SendClientMessageToAll(-1,str);

}

case 5:

{

format(str,sizeof(str),""RED"[DM]"ORANGE" %s "GREY"is now "WHITE"Dominating!!"GREY"!!",name);

SendClientMessageToAll(-1,str);

}

case 6:

{

format(str,sizeof(str),""RED"[DM]"ORANGE" %s "GREY"is now "WHITE"UnStoppable!!"GREY"!!",name);

SendClientMessageToAll(-1,str);

}

case 7:

{

format(str,sizeof(str),""RED"[DM]"ORANGE" %s "GREY"is now "WHITE"Wicked Sick!!"GREY"!!",name);

SendClientMessageToAll(-1,str);

}

case 8:

{

format(str,sizeof(str),""RED"[DM]"ORANGE" %s "GREY"is now "WHITE"Monster like!!"GREY"!!",name);

SendClientMessageToAll(-1,str);

}

case 9:

{

format(str,sizeof(str),""RED"[DM]"ORANGE" %s "GREY"is now "WHITE"GOD LIKE!!"GREY"!!",name);

SendClientMessageToAll(-1,str);

}

case 10:

{

format(str,sizeof(str),""RED"[DM]"ORANGE" %s "GREY"is now "WHITE"Immortal!!"GREY"!!",name);

SendClientMessageToAll(-1,str);

SetPlayerArmour(killerid,100);

}

}

return 1;

}


  Pawno freezes upon compile
Posted by: Miki - 2020-11-11, 07:50 AM - Forum: Pawn Scripting - Replies (6)

The short story is i saved this gamemode i started writing from scratch and i wanted to check it out again and maybe script a little more, i set everything up, latest server files, latest plugins and includes but for some reason (i believe its compatibility or something because it works properly on win7) it freezes when i hit compile. I tried other gamemodes and for some reason it works for them. Now i also tried zeexs latest compiler and it gives me bunch of warnings which i'll list below, i tried #pragma compat 1 but that doesn't seem to work. The gamemode compiles to an amx but its corrupted and won't run.

Code:
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(443) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(700) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(700) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(700) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(784) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(784) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(784) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(790) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(790) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(790) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(795) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(809) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(809) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(809) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(816) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(816) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(816) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(823) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(823) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(823) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(831) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(831) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(831) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(831) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(837) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(837) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(837) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(837) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(843) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(843) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(843) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(843) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(997) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(997) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(997) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(1003) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(1003) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(1003) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(1085) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(1085) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(1085) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(1093) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(1093) : warning 239: literal array/string passed to a non-const parameter
C:\Users\colic\Desktop\samp_server\gamemodes\mfunserver.pwn(1093) : warning 239: literal array/string passed to a non-const parameter
Pawn compiler 3.10.10 Copyright (c) 1997-2006, ITB CompuPhase


45 Warnings.
EDIT:
Found the solution by googling the warning and a thread from this forum came up.


  [HELP]SetVehicleZAngle
Posted by: DiegoProgram - 2020-11-11, 07:07 AM - Forum: Programaci?n - Replies (2)

alguien tiene idea de porque cuando extraigo el angulo?del vehiculo (GetVehicleZAngle)

y intento cargarla me da una posicion en la que el auto no estaba?



me dijeron que hay que invertir los valores oh algo asi pero la verdad que ni idea...


Question Question about open.mp and SAxVCxLC
Posted by: vico - 2020-11-11, 04:15 AM - Forum: General Discussions - Replies (2)

Hello!



First things first: let me say i searched the forums but cant find anything remotely similar to what i'm going to ask. If indeed there are other similar threads and i wasn't able to find, i humbly sorry.



SAxVCxLC, which for those who don't know is a mod who add the landmasses of Vice City and Liberty City (GTA III) alongside (not replacing) San Andreas.



From their Readme:



Quote:Adds the GTA Vice City and Liberty City maps into GTA San Andreas. GTA SA remains fully playable and moddable: mods for SA work also with SAxVCxLC. SAxVCxLC is clean basis for modding by external mods.



I don't know what will be the stance of open.mp about support for TCs, so i'm here to ask if the devs have intentions, even for long term, to add some kind of support for this expanded gameworld, i mean a way to start a server and be able to, via pawn, interact with the other landmasses (place objects, teleport players, etc).



Particularly for me that would be a huge draw-in to make a server after all those years.



Thanks in advance for all your work with open.mp keeping the community alive!


Rainbow Help - Split MySQL
Posted by: wearLy - 2020-11-10, 01:54 PM - Forum: Pawn Scripting - No Replies

Everything goes well, except in the vehicle and accessory loops.







Code:
[color=#24292e][size=x-small][font=SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace]// MySQL:

g_MysqlRaceCheck[playerid];



// create orm instance and register all needed variables

new ORM: ormid = PlayerInfo[playerid][ORM_ID] = orm_create("player", mySQL_Server);



orm_addvar_int(ormid, PlayerInfo[playerid][pID], "id");

orm_addvar_string(ormid, PlayerName[playerid], MAX_PLAYER_NAME, "nome");

orm_addvar_string(ormid, PlayerInfo[playerid][pKey], 65, "senha");

orm_addvar_int(ormid, PlayerInfo[playerid][pLevel], "level");

orm_addvar_int(ormid, PlayerInfo[playerid][pExp], "respeitos");

orm_addvar_int(ormid, PlayerInfo[playerid][pConnectTime], "horas_jogadas");

orm_addvar_int(ormid, PlayerInfo[playerid][pCash], "dinheiro");

orm_addvar_int(ormid, PlayerInfo[playerid][pConta], "dinheiro_banco");

orm_addvar_int(ormid, PlayerInfo[playerid][pOuros], "ouros");

orm_addvar_int(ormid, PlayerInfo[playerid][pCashVip], "cash");

orm_addvar_int(ormid, PlayerInfo[playerid][pKills], "assassinatos");

orm_addvar_int(ormid, PlayerInfo[playerid][pDeaths], "mortes");

orm_addvar_int(ormid, PlayerInfo[playerid][pSkin], "skin");

orm_addvar_int(ormid, PlayerInfo[playerid][pPayDay], "timer_payday");

orm_addvar_int(ormid, PlayerInfo[playerid][pPegouVIP], "vip_pegou");



new string_save[355];

new string_read[18][60];

new string[50];

for(new carro; carro < MAX_PLAYER_CARROS; carro)

{

// Veiculo informa??es

format(string, sizeof string, "veiculo_%d", carro);

orm_addvar_string(ormid, string_save, sizeof (string_save), string);



split(string_save, string_read, '|');



PlayerConce[playerid][carro][conce_valid]? = strval(string_read[0]);

PlayerConce[playerid][carro][conce_model]? = strval(string_read[1]);

PlayerConce[playerid][carro][conce_pos][0] = floatstr(string_read[2]);

PlayerConce[playerid][carro][conce_pos][1] = floatstr(string_read[3]);

PlayerConce[playerid][carro][conce_pos][2] = floatstr(string_read[4]);

PlayerConce[playerid][carro][conce_pos][3] = floatstr(string_read[5]);

PlayerConce[playerid][carro][conce_health] = floatstr(string_read[6]);

PlayerConce[playerid][carro][conce_color][0] = strval(string_read[7]);

PlayerConce[playerid][carro][conce_color][1] = strval(string_read[8]);

PlayerConce[playerid][carro][conce_preco] = strval(string_read[9]);

PlayerConce[playerid][carro][conce_gasolina] = strval(string_read[10]);

PlayerConce[playerid][carro][conce_estacionado] = strval(string_read[11]);

PlayerConce[playerid][carro][conce_seguro] = strval(string_read[12]);

PlayerConce[playerid][carro][conce_alarme]? = strval(string_read[13]);

PlayerConce[playerid][carro][conce_date] = strval(string_read[14]);

PlayerConce[playerid][carro][conce_despesas] = strval(string_read[15]);

format(PlayerConce[playerid][carro][conce_placa], 25, string_read[16]);

format(PlayerConce[playerid][carro][conce_textol], 75, string_read[17]);



// Tunning

format(string, sizeof string, "tune_%d", carro);

orm_addvar_string(ormid, string_save, 258, string);



split(string_save, string_read, '|');



for(new component; component != 15; component) {

PlayerConce[playerid][carro][conce_tune][component] = strval(string_read[component]);

}

}

for(new index; index != MAX_PLAYER_ATTACHED_OBJECTS; index)

{

// Acessorios Informa??es

format(string, sizeof string, "itens_%d", index);

orm_addvar_string(ormid, string_save, sizeof(string_save), string);



split(string_save, string_read, '|');



format(acessorioInfo[playerid][index][acessorioNome], 75, string_read[1]);

acessorioInfo[playerid][index][acessorioValid]? = strval(string_read[0]);

acessorioInfo[playerid][index][acessorioModelo] = strval(string_read[2]);

acessorioInfo[playerid][index][acessorioBone] = strval(string_read[3]);

// Coordenadas

acessorioInfo[playerid][index][acessorioPos][0] = floatstr(string_read[4]);

acessorioInfo[playerid][index][acessorioPos][1] = floatstr(string_read[5]);

acessorioInfo[playerid][index][acessorioPos][2] = floatstr(string_read[6]);

// Rota??o

acessorioInfo[playerid][index][acessorioRot][0] = floatstr(string_read[7]);

acessorioInfo[playerid][index][acessorioRot][1] = floatstr(string_read[8]);

acessorioInfo[playerid][index][acessorioRot][2] = floatstr(string_read[9]);

// Tamanho

acessorioInfo[playerid][index][acessorioTam][0] = floatstr(string_read[10]);

acessorioInfo[playerid][index][acessorioTam][1] = floatstr(string_read[11]);

acessorioInfo[playerid][index][acessorioTam][2] = floatstr(string_read[12]);

}



orm_setkey(ormid, "nome");



// tell the orm system to load all data, assign it to our variables and call our callback when ready

orm_load(ormid, "OnPlayerLoginCheck", "dd", playerid, g_MysqlRaceCheck[playerid]);[/font][/size][/color]


Wink Help with FCNPC
Posted by: dwp12345 - 2020-11-10, 04:53 AM - Forum: Pawn Scripting - Replies (1)

I want to make npc stop following player by distance.



here is my code,



Code:
public FCNPC_Moving(npcid)

{

new Float:p[3];

? ? for(new i =0 ; i < GetMaxPlayers(); i )

{

? ? if(IsPlayerNPC(i)) continue;

FCNPC_GetPosition(npcid,p[0],p[1],p[2]);

if(IsPlayerInRangeOfPoint(i,10,p[0],p[1],p[2]))

{

if(IsPlayerInRangeOfPoint(i,1,p[0],p[1],p[2]))

{

FCNPC_Punch(npcid,p[0],p[1],p[2],50);

}

else

{

? ? FCNPC_GoToPlayer(npcid, i, FCNPC_MOVE_TYPE_AUTO, FCNPC_MOVE_SPEED_AUTO, FCNPC_MOVE_MODE_AUTO, FCNPC_MOVE_PATHFINDING_AUTO, 0.0, true, 0.0, 1.5, 250);

? ? ? ? ? ? ? ??



}

}

}

return 1;

}


  Farsi
Posted by: NimA - 2020-11-08, 04:38 PM - Forum: Other - Replies (2)

????:\


  Good Advertising Sites
Posted by: Torque - 2020-11-07, 09:42 PM - Forum: General Discussions - Replies (4)

I understand that it's incredibly hard to open a new SAMP community. There's aren't many new users coming in, and pretty much everybody who is still playing SAMP is already established in their current communities.



However, I still want to reach out and try and bring in some potential players to my servers. Besides this forum (Which lets face is, is mostly consisted of developers, not players), what sites are out there to help me get the word out about my SAMP roleplay community?



Thanks.


Exclamation Problema de guardado con SQL.
Posted by: nittro - 2020-11-07, 08:04 PM - Forum: Programaci?n - No Replies

Mi problema es que el sistema de registro va bien, pero al desconectarse y loguear otra vez, coloca todos los datos en 0. Estaba probando el sistema hasta que ocurrio.



PHP Code:
new DB:sqldb;

new 
guardadordeCuenta;



enum d@usuario 

{

ID,

Nivel,

NivelStaff,

Vip,

bool:Ingreso,

Muteado,

Dinero,

Vida,

Chaleco,

Genero,

Float:PosX,

Float:PosZ,

Float:PosY,

bool:NewSpawn

};

new 
Cuenta[MAX_PLAYERS][d@usuario];





forward GuardarCuentas();



/*

*=======================================*

*===============Dialogos================*

*=======================================*

*/

#define DIALOGO_REGISTRO (0)

#define DIALOGO_INGRESO (1)

#define DIALOGO_GENERO (2)



public OnGameModeInit()

{

//Conectar al SQlite.

sqldb db_open("sqldb.db");

//Crear la tabla Sqlite.

db_query(sqldb"CREATE TABLE IF NOT EXISTS `usuarios` (ID INTEGER PRIMARY KEY AUTOINCREMENT, Nombre TEXT, Llave TEXT, Nivel NUMERIC, NivelStaff NUMERIC, Vip NUMERIC, Muteado NUMERIC, Vida NUMERIC, Chaleco NUMERIC, Dinero NUMERIC, Genero NUMERIC, PosX FLOAT, PosY FLOAT, PosZ FLOAT)");

// Algunos Timers sobre la base de datos SQlite.

guardadordeCuenta SetTimer("GuardarCuentas"120000true); // Guardar cuentas cada dos minutos.

}



public 
OnGameModeExit()

{

//Cierro la base de datos.

db_close(sqldb);

return 
1

}



public 
OnPlayerConnect(playerid)

{

ReiniciarD(playerid);

new 
query[(59)];

format(querysizeof(query), "SELECT * FROM usuarios WHERE Nombre = '%s' COLLATE NOCASE"DB_Escape(Nombre(playerid)));

new 
DBResult:db_query(sqldbquery);

if(
db_num_rows(R))

{

ShowPlayerDialog(playerid,DIALOGO_INGRESO,DIALOG_STYLE_PASSWORD,""GRISCLARO"? "AZULMARINO"Bienvenido de nuevo al servidor",""ROJO"Escribe tu contrase?a para ingresar al servidor.","Ingresar","Salir");

}

else

{

ShowPlayerDialog(playerid,DIALOGO_REGISTRO,DIALOG_STYLE_INPUT,""GRISCLARO"? "AZULMARINO"Bienvenido al servidor",""ROJO"Escribe tu contrase?a para poder guardar tus datos.",""TURQUESA"Registrar",""ROJO"Salir");

}

db_free_result(R);

return 
1;

}



public 
OnPlayerDisconnect(playeridreason)

{

//Guardar posici?n del jugador.

new Float:xFloat:yFloat:z;

GetPlayerPos(playeridx,y,z);

Cuenta[playerid][PosX] = x;

Cuenta[playerid][PosY] = y;

Cuenta[playerid][PosZ] = z;

GuardarCuenta(playerid);

ReiniciarD(playerid);

return 
1;

}



public 
OnDialogResponse(playerid,dialogid,response,listitem,inputtext[])

{



if(
dialogid == DIALOGO_INGRESO)

{

if(!
response)Kick(playerid);

if(
response){

new 
query[(76�)];

format(query,sizeof(query),"SELECT * FROM usuarios WHERE Nombre = '%s' AND Llave = '%s' COLLATE NOCASE",DB_Escape(Nombre(playerid)),DB_Escape(inputtext));

new 
DBResult:db_query(sqldb,query);

if(
db_num_rows(R)){

Cuenta[playerid][ID]? ? ? = db_get_field_assoc_int(R,"ID");

Cuenta[playerid][Nivel]? ? = db_get_field_assoc_int(R,"Nivel");

Cuenta[playerid][NivelStaff]? ? = db_get_field_assoc_int(R,"NivelStaff");

Cuenta[playerid][Dinero]? = db_get_field_assoc_int(R,"Dinero");

Cuenta[playerid][Vida] = db_get_field_assoc_int(R,"Vida");

Cuenta[playerid][Chaleco] = db_get_field_assoc_int(R,"Chaleco");

Cuenta[playerid][Vip]? ? ? = db_get_field_assoc_int(R,"Vip");

? ? 
Cuenta[playerid][Muteado]? = db_get_field_assoc_int(R,"Muteado");

? ? 
Cuenta[playerid][Genero] = db_get_field_assoc_int(R,"Genero");

? ? 
Cuenta[playerid][PosX] = db_get_field_assoc_float(R"PosX");

? ? 
Cuenta[playerid][PosY] = db_get_field_assoc_float(R"PosY");

? ? 
Cuenta[playerid][PosZ] = db_get_field_assoc_float(R"PosZ");

format(query,sizeof(query),"~y~%s~n~~b~usted Ingreso con exito.",Nombre(playerid));

GameTextForPlayer(playerid,query,4000,5);

Cuenta[playerid][Ingreso] = true;

Cuenta[playerid][NewSpawn] = false;

}else return 
ShowPlayerDialog(playerid,DIALOGO_INGRESO,DIALOG_STYLE_PASSWORD,""GRISCLARO"? "AZULMARINO"Bienvenido de nuevo al servidor",""TURQUESA"Escribe tu contrase?a para ingresar al servidor.\n"ROJO"La contrase?a que has ingresado es incorrecta.",""TURQUESA"Ingresar",""ROJO"Salir");

db_free_result(R);

}}





if(
dialogid == DIALOGO_REGISTRO)

{

if(!
response)Kick(playerid);

if(
response)

{

if(
strlen(inputtext) < || strlen(inputtext) > 32) return ShowPlayerDialog(playerid,DIALOGO_REGISTRO,DIALOG_STYLE_INPUT,""GRISCLARO"? "AZULMARINO"Bienvenido al servidor",""ROJO"Escribe tu contrase?a para poder guardar tus datos.",""TURQUESA"Registrar",""ROJO"Salir");

ShowPlayerDialog(playeridDIALOGO_GENERODIALOG_STYLE_MSGBOX""GRISCLARO"? "AZULMARINO"?Excelente!",""ROJO"Selecciona tu genero para poder continuar.""Hombre""Mujer");

new 
query[(144�)];

format(query,sizeof(query),"INSERT INTO usuarios (Nombre,Llave,Dinero,NivelStaff,Vip,Nivel,Muteado,PosX,PosY,PosZ) VALUES ('%s','%s','0','0','0','0','0','0', '0', '0')",Nombre(playerid),inputtext);

db_query(sqldb,query);

format(query,sizeof(query),"~y~%s~n~~b~usted fue registrado con exito.",Nombre(playerid));

GameTextForPlayer(playerid,query,4000,5);

Cuenta[playerid][Ingreso] = true;

Cuenta[playerid][NewSpawn] = true;

}

}



if(
dialogid == DIALOGO_GENERO)

{

if(!
response)Kick(playerid);

if(!
response)

{

new 
query[60];

format(query,sizeof(query),"INSERT INTO usuarios (Genero) VALUES ('1')");

Cuenta[playerid][Genero] = 1;

}

else

{

new 
query[60];

format(query,sizeof(query),"INSERT INTO usuarios (Genero) VALUES ('0')");

Cuenta[playerid][Genero] = 0;

}

}



return 
1;

}





// Evitar bugs //

public OnPlayerRequestSpawn(playerid)

{

if(
Cuenta[playerid][Ingreso] == false)

{

GameTextForPlayer(playerid,"~r~~n~~n~Primero debes ingresar/registrarte.",2000,5);

return 
0;

}

return 
1;

}



public 
OnPlayerUpdate(playerid)

{

if(
GetPlayerMoney(playerid) != Cuenta[playerid][Dinero])

{

ResetPlayerMoney(playerid);

GivePlayerMoney(playerid,Cuenta[playerid][Dinero]);

}



if(
GetPlayerScore(playerid) != Cuenta[playerid][Nivel])

{

SetPlayerScore(playerid,Cuenta[playerid][Nivel]);

}



if(
IsPlayerAdmin(playerid) && !TienePermisos(playerid))

{

new 
msg[(57)];

format(msg,sizeof(msg),"%s fue expulsado por ingresar a la rcon sin autorizaci?n.",Nombre(playerid));

SendClientMessageToAll(-1,msg);

Kick(playerid);

}

return 
1;

}



public 
OnPlayerSpawn(playerid)

{

if(
Cuenta[playerid][NewSpawn] == false)

{

SetPlayerPos(playeridCuenta[playerid][PosX], Cuenta[playerid][PosY], Cuenta[playerid][PosZ]);

SetPlayerInterior(playerid0);

}

else 

{

new 
posal random(3);

switch(
posal)

{

case 
0SetPlayerPos(playerid1682.7462,-2292.2656,13.5168);

case 
1SetPlayerPos(playerid1663.3788,-2286.2458,5.2656);

case 
2SetPlayerPos(playerid1682.0084,-2286.5540,-1.2325);

}

SetPlayerInterior(playerid0);

}

return 
1;

}





// GuardarCuentas //



public GuardarCuentas()

{

for(new 
i=0;i<MAX_PLAYERS;i)

{

if(
IsPlayerConnected(i))

{

GuardarCuenta(i);

}

}

return 
1;

}







// Restablecer datos por defecto //

stock ReiniciarD(playerid)

{

Cuenta[playerid][Ingreso]? = false;

Cuenta[playerid][ID] = -1;

Cuenta[playerid][Dinero]? ? = 0;

Cuenta[playerid][Vida] = 0;

Cuenta[playerid][Chaleco] = 0;

Cuenta[playerid][NivelStaff]? ? = 0;

Cuenta[playerid][Vip]? ? ? = 0;

Cuenta[playerid][Nivel]? ? = 0;

Cuenta[playerid][Muteado]? = 0;

Cuenta[playerid][Genero] = 0;

Cuenta[playerid][PosX] = 0.0;

Cuenta[playerid][PosY] = 0.0;

Cuenta[playerid][PosZ] = 0.0;

}





// Verificar si la Cuenta existe //

stock CuentaExistente(name[])

{

new 
query[(42)];

format(query,sizeof(query),"SELECT * FROM usuarios WHERE Nombre = '%s'",name);

new 
DBResult:db_query(sqldb,query);

if(
db_num_rows(R))

{

return 
true;

}

db_free_result(R);

return 
false;

}



// Escape //

stock DB_Escape(text[]){

new 
ret[80 2],

ch,

i,

j;

while ((
ch text[i]) && sizeof (ret))

{

if (
ch == '\'')

{

if (
sizeof (ret) - 2)

{

ret[j] = '\'';

ret[j] = '\'';

}

}

else if (
sizeof (ret))

{

ret[j] = ch;

}

else

{

j;

}

}

ret[sizeof (ret) - 1] = '\0';

return 
ret;

}



stock Nombre(playerid)

{

new 
name[24];

GetPlayerName(playerid,name,sizeof(name));

return 
name;

}







stock GuardarCuenta(playerid)

{

if(
CuentaExistente(Nombre(playerid)))

{

new 
query[400];

format(query,sizeof(query),"UPDATE usuarios SET Nivel = '%d', Dinero = '%d', NivelStaff = '%d', Vip = '%d', Muteado = '%d', PosX = '%f', PosY = '%f' PosZ = '%f' WHERE Nombre = '%s'",Cuenta[playerid][Nivel],Cuenta[playerid][Dinero],Cuenta[playerid][NivelStaff],Cuenta[playerid][Vip],Cuenta[playerid][Muteado],Cuenta[playerid][PosX],Cuenta[playerid][PosY],Cuenta[playerid][PosZ],Nombre(playerid));

db_query(sqldb,query);

}

}









Los logs:



PHP Code:
[15:43:41] [db_log_queries]: CREATE TABLE IF NOT EXISTS `usuarios` (ID INTEGER PRIMARY KEY AUTOINCREMENTNombre TEXTLlave TEXTNivel NUMERICNivelStaff NUMERICVip NUMERICMuteado NUMERICVida NUMERICChaleco NUMERICDinero NUMERICGenero NUMERICPosX FLOATPosY FLOATPosZ FLOAT)

[
15:43:41Nova Roleplay.

[
15:43:41Number of vehicle models0

[15:44:34] [connection127.0.0.1:61684 requests connection cookie.

[
15:44:35] [connectionincoming connection127.0.0.1:61684 id0

[15:44:35] [joinPhillip_Blackstone has joined the server (0:127.0.0.1)

[
15:44:35] [db_log_queries]: SELECT FROM usuarios WHERE Nombre 'Phillip_Blackstone' COLLATE NOCASE

[15:44:39] [db_log_queries]: INSERT INTO usuarios (Nombre,Llave,Dinero,NivelStaff,Vip,Nivel,Muteado,PosX,PosY,PosZVALUES ('Phillip_Blackstone','20061219','0','0','0','0','0','0''0''0')

[
15:44:54] [db_log_queries]: SELECT FROM usuarios WHERE Nombre 'Phillip_Blackstone'

[15:44:54] [db_log_queries]: UPDATE usuarios SET Nivel '0'Dinero '0'NivelStaff '0'Vip '0'Muteado '0'PosX '1668.851074'PosY '-2242.367187' PosZ '7.907007' WHERE Nombre 'Phillip_Blackstone'

[15:44:54] [partPhillip_Blackstone has left the server (0:1)

[
15:45:47] [connection127.0.0.1:63435 requests connection cookie.

[
15:45:48] [connectionincoming connection127.0.0.1:63435 id0

[15:45:48] [joinPhillip_Blackstone has joined the server (0:127.0.0.1)

[
15:45:48] [db_log_queries]: SELECT FROM usuarios WHERE Nombre 'Phillip_Blackstone' COLLATE NOCASE

[15:45:51] [db_log_queries]: SELECT FROM usuarios WHERE Nombre 'Phillip_Blackstone'

[15:45:51] [db_log_queries]: UPDATE usuarios SET Nivel '0'Dinero '0'NivelStaff '0'Vip '0'Muteado '0'PosX '0.000000'PosY '0.000000' PosZ '0.000000' WHERE Nombre 'Phillip_Blackstone'

[15:45:59] [db_log_queries]: SELECT FROM usuarios WHERE Nombre 'Phillip_Blackstone' AND Llave '20061219' COLLATE NOCASE

[15:46:06] [db_log_queries]: SELECT FROM usuarios WHERE Nombre 'Phillip_Blackstone'

[15:46:06] [db_log_queries]: UPDATE usuarios SET Nivel '0'Dinero '0'NivelStaff '0'Vip '0'Muteado '0'PosX '0.000000'PosY '0.000000' PosZ '-87.565048' WHERE Nombre 'Phillip_Blackstone'

[15:46:06] [partPhillip_Blackstone has left the server (0:1