14.07.2016, 02:43
script
mysql log
PHP код:
forward OnAccountLoad(playerid);
public OnAccountLoad(playerid)
{
pInfo[playerid][ID] = cache_get_field_content_int(0, "ID");
pInfo[playerid][pAdminLevel] = cache_get_field_content_int(0, "pAdminLevel");
pInfo[playerid][Premium] = cache_get_field_content_int(0, "Premium");
pInfo[playerid][pEXP] = cache_get_field_content_int(0, "pEXP");
TogglePlayerSpectating(playerid, false);
GivePlayerMoney(playerid, pInfo[playerid][pEXP]);
SendClientMessage(playerid, -1, "You have successfully logged in.");
SpawnPlayer(playerid);
return true;
}
PHP код:
[09:26:03] [DEBUG] mysql_format - connection: 1, len: 214, format: "SELECT * FROM `users` WHERE `Name` = '%e'"
[09:26:03] [DEBUG] mysql_tquery - connection: 1, query: "SELECT * FROM `users` WHERE `Name` = ''", callback: "OnAccountLoad", format: "i"
[09:26:03] [DEBUG] CMySQLQuery::Execute[OnAccountLoad] - starting query execution
[09:26:03] [DEBUG] CMySQLQuery::Execute[OnAccountLoad] - query was successfully executed within 0.339 milliseconds
[09:26:03] [DEBUG] CMySQLResult::CMySQLResult() - constructor called
[09:26:03] [DEBUG] Calling callback "OnAccountLoad"..
[09:26:03] [DEBUG] cache_get_field_content_int - row: 0, field_name: "ID", connection: 1
[09:26:03] [ERROR] CMySQLResult::GetRowDataByName() - invalid row index ('0')
[09:26:03] [ERROR] cache_get_field_content_int - invalid datatype
[09:26:03] [DEBUG] cache_get_field_content_int - row: 0, field_name: "pAdminLevel", connection: 1
[09:26:03] [ERROR] CMySQLResult::GetRowDataByName() - invalid row index ('0')
[09:26:03] [ERROR] cache_get_field_content_int - invalid datatype
[09:26:03] [DEBUG] cache_get_field_content_int - row: 0, field_name: "Premium", connection: 1
[09:26:03] [ERROR] CMySQLResult::GetRowDataByName() - invalid row index ('0')
[09:26:03] [ERROR] cache_get_field_content_int - invalid datatype
[09:26:03] [DEBUG] cache_get_field_content_int - row: 0, field_name: "pEXP", connection: 1
[09:26:03] [ERROR] CMySQLResult::GetRowDataByName() - invalid row index ('0')
[09:26:03] [ERROR] cache_get_field_content_int - invalid datatype
[09:26:03] [DEBUG] CMySQLResult::~CMySQLResult() - deconstructor called