spawnVehicle_dest 67

Spawn a vehicle and give it a destination. For Auto-Transport vehicles, this is where units will be deployed. Vehicle Ids can be acquired in the Script Settings menu -> Id tables section


Return value

Return TypeDescription
VehicleReference to the vehicle

Parameters

ParameterTypeDescription
1stringId of the vehicle to spawn
2vec3Location where to spawn the vehicle
3vec3Euler rotation for the vehicle
4vec3Destination where to send the Auto-Transport vehicle

Examples

Example 117

-- Spawn a vehicle with destination
local vehicle1 = spawnVehicle_camo("JeepWillys", vec3(0, 1.5, 0), vec3(0, 90, 0), vec3(50, 0, 50))
if vehicle1 then
    print("Basic vehicle spawned!", 3)
end

Back to Scripting API