02.01.2013, 03:29
(
Last edited by zDevon; 03/01/2013 at 01:13 AM.
)
Quote:
|
Originally Posted by update
Player 1 buys vehicle A.
Vehicle A is given SAMP ID 1. I save vehicle A and it is given MySQL ID 1. So far so good. Stats save and load fine. Player 2 spawns a temporary vehicle (Vehicle B) with a /veh command. Vehicle B is given SAMP ID 2. Because the vehicle is temporary and will disappear on a restart, no mysql ID is assigned. Player 3 buys vehicle C. Vehicle C is given SAMP ID 3. I save vehicle C, but it is only given MySQL ID 2. Now there's trouble. When trying to load vehicle C, the script loads the stats for MySQL ID 3 (which is non existent). |
For example:
- I buy a vehicle, it is assigned to ID 1.
Vehicle 1 saves with MySQL ID 1.
- Another vehicle is spawned with a /veh command. It is assigned (by samp) vehicle ID 2.
- Another player buys a vehicle, with samp id 3, but when it saves that vehicle is only ID 2 in the MySQL table.

