15.09.2009, 12:13
Quote:
Originally Posted by Betamaster
The EraseVehicle function you call is very poorly coded so I am not surprised you are having problems. You do not need the for loop (which should be limited to less then MAX_PLAYERS anyway) to get/set player positions for those in a vehicle you are destroying. You also don't need to use SetVehicleToRespawn and SetVehicleParamsForPlayerEx, and calling DestroyVehicle via the timer is not needed. Call DestroyVehicle directly and you shouldn't have a problem.
|
The SetVehicleParamsForPlayerEx (formerly SetVehicleParamsForPlayer) is there for this exact reason, when DestroyVehicle fails it locks the vehicle to anyone because cars in this system or generally admin created. If you look at LAdminV4 you'll see exactly what I mean.