Difference between revisions of "Spawn a vehicle"

From GTAMods Wiki
Jump to navigation Jump to search
Line 1: Line 1:
How to make CLEO Car spawns:
+
How to make [[CLEO]] car spawns:
  
'''Template code'''
+
{$CLEO .cs}
 +
 +
//-------------MAIN---------------
 +
 +
[[014B]]: 0@ = init_parked_car_generator #HOTRING color -1 -1 1 alarm 0 door_lock 0 0 10000 at -2335.069 -1613.274 483.7184 angle 0.0
 +
[[014C]]: set_parked_car_generator 0@ cars_to_generate_to 101
 +
[[0A95]]: enable_thread_saving
 +
[[0A93]]: end_custom_thread
  
{$CLEO .cs}
+
[[Category:GTA_SA]][[Category:Code Snippets]][[Category:Mission Script]]
 
 
//-------------MAIN---------------
 
 
 
014B: 0@ = init_parked_car_generator #HOTRING color -1 -1 1 alarm 0 door_lock 0 0 10000 at -2335.069 -1613.274 483.7184 angle 0.0
 
 
 
014C: set_parked_car_generator 0@ cars_to_generate_to 101
 
 
 
0A95: enable_thread_saving
 
 
 
0A93: end_custom_thread
 
 
 
'''Detailed look:'''
 
 
 
Part:[http://www.gtamodding.com/index.php?title=014B 014B]: This tells the game it's going to be a car spawn (see the article for full documentation)
 
 
 
Part:init_parked_car_generator: Tells the game it's a parked car
 
 
 
Part: #HOTRING: Tells the game what car to spawn, replace the 'HOTRING' part with a vehicle of your own, e.g,    androm=#ANDROM
 
Bf-400= #Bf400
 
At-400= #AT400
 
Nrg-500= #NRG500
 
 
 
Part: colour -1 -1 1: Only expert coders should touch this part
 
 
 
Part: alarm 0: Determines whether the car has its alarm on or off (alarm 0 is alarm off, and alarm 1 is alarm on
 
 
 
Part: -2335.069 -1613.274 483.7184: The co-ordinates where the car will spawn.
 
 
 
Part: angle 0.0: The angle in which the car is facing (e.g, 0.0=North 180.0=South 90.0=East 270.0= West
 

Revision as of 09:26, 1 January 2009

How to make CLEO car spawns:

{$CLEO .cs}

//-------------MAIN---------------

014B: 0@ = init_parked_car_generator #HOTRING color -1 -1 1 alarm 0 door_lock 0 0 10000 at -2335.069 -1613.274 483.7184 angle 0.0 
014C: set_parked_car_generator 0@ cars_to_generate_to 101 
0A95: enable_thread_saving
0A93: end_custom_thread