Quote: (From my post on Kirby's Scripting Thread)
Spawning more than 6 vehicles in a multiplayer mapI owe all credit to kirby for theorising this script:
- Give all your vehicles names
- Place a big trigger volume around the first vehicle you placed on the map, but make sure it doesn't go over any other vehicle spawn points besides the first one
- Remove the {} fields and the text inside them, and replace with the corresponding information
(script startup vehicle_spawn
(if
(!= (unit_get_health {any vehicle from the first to sixth vehicle in the list of vehicles in sapien}) -1.00)
(begin
(object_create_anew {vehicle 1})
(object_create_anew {vehicle 2})
(object_create_anew {vehicle 3});;repeat this object_create_anew pattern for all your vehicles
;;After the vehicles respawn for some odd reason they respawn on the first vehicle you placed in the list. To counter this, use this script. Fill vehicle slots only with vehicles after the 6th vehicle
(script continuous vehicle_respawn
(if
(= (volume_test_object {name of trigger volume around first vehicle} {name of vehicle}) true)
(object_create_anew {name of vehicle})
)
(if
(= (volume_test_object {name of trigger volume around first vehicle} {name of another vehicle}) true)
(object_create_anew {name of another vehicle})
)
(if
(= (volume_test_object {name of trigger volume around first vehicle} {name of yet another vehicle}) true)
(object_create_anew {name of yet another vehicle})
)
;;repeat this pattern for all vehicles besides the first 6 vehicles
)