Guten Tag,
komischerweise Speichern die Positionen nicht (?).
Code
mysql_format(dbhandle,query,sizeof(query),"UPDATE `user` SET `skin` = '%d', `alter` = '%d', `geschlecht` = '%d', `neuling` = '%d', `leben` = '%.0f', `russi` = '%.0f', `Posx` = '%.0f', `Posy` = '%.0f', `Posz` = '%.0f', `Posa` = '%.0f', `Interior` = '%d', `Virtualworld` = '%d', WHERE `ID` = '%i'",GetPlayerSkin(playerid),
pInfo[playerid][palter],pInfo[playerid][pgeschlecht],pInfo[playerid][pneuling],pInfo[playerid][pleben],pInfo[playerid][prussi],x,y,z,a,GetPlayerInterior(playerid),GetPlayerVirtualWorld(playerid),pInfo[playerid][pid]);
Code
//Spieler-Position-Laden [ ! ]
pInfo[playerid][px]=cache_get_field_content_float(0,"Posx",dbhandle);
pInfo[playerid][py]=cache_get_field_content_float(0,"Posy",dbhandle);
pInfo[playerid][pz]=cache_get_field_content_float(0,"Posz",dbhandle);
pInfo[playerid][pa]=cache_get_field_content_float(0,"Posa",dbhandle);
pInfo[playerid][pint]=cache_get_field_content_int(0,"Interior",dbhandle);
pInfo[playerid][pvit]=cache_get_field_content_int(0,"Virtualworld",dbhandle);
//Spieler-Position-Laden [ ! ]
Wenn ich das ganze printe kommt das beim Server.exe:
SQL
INSERT INTO user (username, password) VALUES ('Reste',MD5('test'))
UPDATE `user` SET `skin` = '247', `alter` = '23', `geschlecht` = '1', `neuling` = '0', `leben` = '0', `russi` = '0', `Posx` = '0', `Posy` = '0', `Posz` = '0', `Posa` = '0', `Interior` = '0', `Virtualworld` = '0', WHERE `ID` = '63'
/e MySQL Log
Code
[19:35:26] [DEBUG] mysql_format - connection: 1, len: 256, format: "INSERT INTO user (username, password) VALUES ('%e',MD5('%e'))"
[19:35:26] [DEBUG] mysql_tquery - connection: 1, query: "INSERT INTO user (username, password) VALUES ('Reste',MD5('xxxx", callback: "OnPlayerRegister", format: "i"
[19:35:26] [DEBUG] CMySQLQuery::Execute[OnPlayerRegister] - starting query execution
[19:35:26] [DEBUG] CMySQLQuery::Execute[OnPlayerRegister] - query was successfully executed within 2.755 milliseconds
[19:35:26] [DEBUG] CMySQLResult::CMySQLResult() - constructor called
[19:35:26] [DEBUG] Calling callback "OnPlayerRegister"..
[19:35:26] [DEBUG] cache_insert_id - connection: 1
[19:35:26] [DEBUG] CMySQLResult::~CMySQLResult() - deconstructor called
[19:35:26] [DEBUG] mysql_format - connection: 1, len: 256, format: "UPDATE `user` SET `skin` = '%d', `alter` = '%d', `geschlecht` = '%d', `neuling` = '%d', `leben` = '%.0f', `russi` = '%.0f', `Pos..."
[19:35:26] [DEBUG] mysql_pquery - connection: 1, query: "UPDATE `user` SET `skin` = '247', `alter` = '23', `geschlecht` =", callback: "(null)", format: "(null)"
[19:35:26] [DEBUG] CMySQLQuery::Execute[] - starting query execution
[19:35:26] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'WHERE `ID` = '63'' at line 1
[19:35:26] [DEBUG] CMySQLQuery::Execute[] - error will be triggered in OnQueryError
Alles anzeigen