mysql car load problem [+Rep]
#2

You never passed playerid to mysql_function_query.The OnPlayerLoadVehicles Callback will be called with random playerid(could be 0 , I am not sure).

You don't need another function to call a function and needn't select all vehicles.Just directly fetch the player's vehicles.

Код:
public OnPlayerConnect(playerid)
{
   static query[128];
   mysql_format(mysql, query, sizeof(query), "SELECT * FROM `pvehicles` WHERE `vOwner` = '%s'", name);
   mysql_function_query(mysql, query, true,"OnPlayerLoadVehicles", "i",playerid);
   return 1;
}
Use the same OnPlayerLoadVehicles callback(the one which you have).
Reply


Messages In This Thread
mysql car load problem [+Rep] - by simo0000 - 24.05.2015, 09:49
Re: mysql car load problem [+Rep] - by Yashas - 24.05.2015, 10:40
Re : Re: mysql car load problem [+Rep] - by simo0000 - 24.05.2015, 12:57
Re : mysql car load problem [+Rep] - by simo0000 - 24.05.2015, 13:48
Re : mysql car load problem [+Rep] - by simo0000 - 25.05.2015, 19:57

Forum Jump:


Users browsing this thread: 3 Guest(s)