SetVehicleToRespawn
From SA-MP Wiki
(Difference between revisions)
Revision as of 09:48, 23 October 2011 Garsino (Talk | contribs) (Vehicle IDs start from 1, not 0.) ← Previous diff |
Revision as of 17:27, 4 February 2014 Connor Mead (Talk | contribs) Next diff → |
||
Line 1: | Line 1: | ||
{{Scripting}} | {{Scripting}} | ||
- | {{Title}} | ||
{{Description|Sets a vehicle back to the position at where it was created}} | {{Description|Sets a vehicle back to the position at where it was created}} | ||
Line 28: | Line 27: | ||
[[Category:Scripting Functions]] | [[Category:Scripting Functions]] | ||
+ | |||
+ | [[fr:SetVehicleToRespawn]] |
Revision as of 17:27, 4 February 2014
Description:
Sets a vehicle back to the position at where it was created
(vehicleid)
vehicleid | The ID of the vehicle to respawn |
Return Values:
This function does not return any specific values.
// Respawns the first vehicle. SetVehicleToRespawn(1);
Or you can also make every vehicle in the whole script to respawn:
for(new i = 1; i <= MAX_VEHICLES; i++) { SetVehicleToRespawn(i); }
Related Functions
The following functions may be useful, as they are related to this function in one way or another.
- CreateVehicle: Create a vehicle.
- DestroyVehicle: Destroy a vehicle.