25.01.2015, 13:56
Quote:
For a park command, create enough backup variables inside your function to hold all data about your current vehicle, like position, rotation, color, tunings, ...
Let's assume your vehicle had vehicleid 5. Then destroy the vehicle and cleanup your data (set it to 0) in the array where the vehicle was stored (index 5 of your vinfo array). Then re-create a new one at the new position where you want to park it using CreateVehicle. You will be given a new vehicleid, let's assume it's 3 now. Then store the temporary data from your backup variables into index 3 of your vinfo array. You could also keep the data at index 5, destroy the vehicle, re-create it using data from index 5, then copy the data from index 5 to index 3 and finally clear all data at index 5. |