20.04.2010, 12:39
He's asking for a vehicle removal on respawn - not when it 'dies'. Additionally I have no idea why you're using a timer.
Код:
static n_aVehiclePurchased[MAX_VEHICLES] = {0, ...}; // Flag to determine a vehicle is purchased // When you create your vehicle, assign the relevant array iteration to the vehicle ID. n_aVehiclePurchased[CreateVehicle(model, x, y, z, rot, color, color2, respawntime)] = 1; // Now just check when the vehicle respawns if it's a purchased one. If so remove it. public OnVehicleRespawn(vehicleid) { if(!n_aVehiclePurchased[vehicleid]) return; n_aVehiclePurchased = 0; DestroyVehicle(vehicleid); }