19.01.2019, 18:43
Don't work, if i set " PlayerInfo[playerid][pEmail] = 0; " To: " PlayerInfo[playerid][pEmail] = ""; "pawno give me that error
but if i turn set " PlayerInfo[playerid][pEmail] = 0; " work... but
in the registration part, set in the db name and password to "NULL" and the email is ok, but when the player left the server, set the email like name and the psw, and i have in the db
name= "NULL"
password= "NULL"
email= ""
I don't know what i should to do for fix
take a look: https://pastebin.com/zvF2GkMB
Code:
C:\Users\ouday\OneDrive\Desktop\Giochi\samp\samp rp\samp03DL_svr_R1_win32\gamemodes\gamemoderp.pwn(239) : error 047: array sizes do not match, or destination array is too small Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 1 Error.
in the registration part, set in the db name and password to "NULL" and the email is ok, but when the player left the server, set the email like name and the psw, and i have in the db
name= "NULL"
password= "NULL"
email= ""
I don't know what i should to do for fix
take a look: https://pastebin.com/zvF2GkMB
Quote:
Change the following:
Code:
pEmail, Code:
pEmail[64], Code:
PlayerInfo[playerid][pEmail] = 0; Code:
PlayerInfo[playerid][pEmail] = ""; Code:
cache_get_value_name(0, "email", PlayerInfo[playerid][pEmail]); Code:
cache_get_value_name(0, "email", PlayerInfo[playerid][pEmail],64); Code:
new playeremail = PlayerInfo[playerid][pEmail]; Code:
new playeremail[64]; format(playeremail, 64, PlayerInfo[playerid][pEmail]); Code:
mysql_format(handle, query, sizeof(query), "UPDATE users SET email = '%d', level = '%d', admin = '%d', money = '%d', kills = '%d', deaths = '%d' WHERE id = '%d'", playeremail, livello, adminl, soldi, uccisioni, morti, idgiocatore); Code:
mysql_format(handle, query, sizeof(query), "UPDATE users SET email = '%s', level = '%d', admin = '%d', money = '%d', kills = '%d', deaths = '%d' WHERE id = '%d'", playeremail, livello, adminl, soldi, uccisioni, morti, idgiocatore); And make sure that "email" is defined as VARCHAR with LENGTH 64 in MySQL Database. |