31.05.2015, 14:29
It's the second reason I mentioned.
Player A spawns a vehicle with vehicle ID 1.
Player A's vehicle gets destroyed.
Player B spawns a vehicle with ID 1.
Player A spawns a vehicle with vehicle ID 2 but the server destroys Player B's vehicle as the variable was never reset (previous vehicle of Player A was the vehicle with ID 1).
Whenever the vehicle is destroyed, find who player had it stored and reset the variable CarId[playerid] to INVALID_VEHICLE_ID.
Player A spawns a vehicle with vehicle ID 1.
Player A's vehicle gets destroyed.
Player B spawns a vehicle with ID 1.
Player A spawns a vehicle with vehicle ID 2 but the server destroys Player B's vehicle as the variable was never reset (previous vehicle of Player A was the vehicle with ID 1).
Whenever the vehicle is destroyed, find who player had it stored and reset the variable CarId[playerid] to INVALID_VEHICLE_ID.