{"name":"createVehicleLocal","title":"createVehicleLocal","type":"command","url":"https://community.bistudio.com/wiki/createVehicleLocal","revid":377538,"updated":"2026-01-02T06:54:18Z","groups":["Object Manipulation"],"status":"ok","games":{"arma1":"1.00","arma2":"1.00","arma2oa":"1.50","tkoh":"1.00","arma3":"0.50"},"since":"arma1 1.00","arma3_since":"0.50","locality":{"effect":"local"},"description":"Creates an object of the given type. The Created object is not transferred through network in MP games.\nnetId of such vehicle in multiplayer will be \"0:0\". To disable local vehicle creation, use CfgDisabledCommands to blacklist this command.\nAlternatively, you can use createSimpleObject with local option enabled where applicable.","syntaxes":[{"syntax":"type createVehicleLocal position","params":[{"name":"type","type":"String","description":"vehicle/object className","type_expr":"String"},{"name":"position","type":"PositionAGL","type_expr":"PositionAGL"}],"returns":{"type":"Object","type_expr":"Object"},"form":"binary","left":{"text":"type"},"right":{"text":"position"}},{"syntax":"createVehicleLocal [type, position, markers, placement, special]","since":"arma3 2.14","params":[{"name":"type","type":"String","description":"vehicle/object className","type_expr":"String"},{"name":"position","type":"Object, Position2D or PositionATL (PositionAGL if watercraft or amphibious)","description":"desired placement position","type_expr":"Object | Position2D | PositionATL | PositionAGL"},{"name":"markers","type":"Array of Strings","optional":true,"default":"`[]`","description":"if the markers array contains any markers, the position is randomly picked from array of given markers plus desired placement position.\nIf any of the markers were given z coordinate with setMarkerPos, the vehicle will also be created at given z coordinate.","type_expr":"Array<String>","text":"markers: Array of Strings - (Optional, default `[]`) if the markers array contains any markers, the position is randomly picked from array of given markers plus desired placement position.\nIf any of the markers were given z coordinate with setMarkerPos, the vehicle will also be created at given z coordinate."},{"name":"placement","type":"Number","optional":true,"default":"0","description":"the vehicle is placed inside a circle with given position as center and placement as its radius.","type_expr":"Number","text":"placement: Number - (Optional, default 0) the vehicle is placed inside a circle with given position as center and placement as its radius."},{"name":"special","type":"String","optional":true,"default":"\"NONE\"","description":"can be one of the following:\n\n- `\"NONE\"` - will look for suitable empty position near given position (subject to other placement params) before placing vehicle there.\n- `\"CAN_COLLIDE\"` - places vehicle at given position (subject to other placement params), without checking if others objects can cross its 3D model.\n- `\"FLY\"` - if vehicle is capable of flying and has crew, it will be made airborne at default height.\n\nIf *special* is \"\" or not specified, default `\"NONE\"` is used.","type_expr":"String","text":"special: String - (Optional, default \"NONE\") can be one of the following:\n\n- `\"NONE\"` - will look for suitable empty position near given position (subject to other placement params) before placing vehicle there.\n- `\"CAN_COLLIDE\"` - places vehicle at given position (subject to other placement params), without checking if others objects can cross its 3D model.\n- `\"FLY\"` - if vehicle is capable of flying and has crew, it will be made airborne at default height.\n\nIf *special* is \"\" or not specified, default `\"NONE\"` is used."}],"returns":{"type":"Object","type_expr":"Object","description":"created vehicle or objNull if failed"},"form":"unary","right":{"text":"[type, position, markers, placement, special]"}}],"examples":[{"code":["_lightSource = \"#lightpoint\" createVehicleLocal _pos;"]},{"text":"Multiple types:\n\n```sqf\nprivate _lightSource =        \"#lightsource\"        createVehicleLocal _pos;    // see Light Source Tutorial\nprivate _lightReflector =    \"#lightreflector\"    createVehicleLocal _pos;    // see Light Source Tutorial - since Arma 3 v2.06\nprivate _particleSource =    \"#particlesource\"    createVehicleLocal _pos;    // see Particles Tutorial\nprivate _dynamicSound =        \"#dynamicsound\"        createVehicleLocal _pos;    // see createSoundSource\n```","code":["private _lightSource =\t\t\"#lightsource\"\t\tcreateVehicleLocal _pos;\t// see Light Source Tutorial\nprivate _lightReflector =\t\"#lightreflector\"\tcreateVehicleLocal _pos;\t// see Light Source Tutorial - since Arma 3 v2.06\nprivate _particleSource =\t\"#particlesource\"\tcreateVehicleLocal _pos;\t// see Particles Tutorial\nprivate _dynamicSound =\t\t\"#dynamicsound\"\t\tcreateVehicleLocal _pos;\t// see createSoundSource"]},{"code":["// since Arma 3 v2.14\nprivate _lightPoint = createVehicleLocal [\"#lightpoint\", getMarkerPos \"marker1\", [\"marker2\", \"marker3\"], 0, \"NONE\"];"]}],"see_also":["createVehicle","createMine","deleteVehicle","createUnit"],"notes":[{"user":"Kronzky","date":"2008-06-05T07:18:00Z","text":"If the object that is created is of the type ammo, then it will created on **all** clients (*tested only on VBS2*)."},{"user":"DamonDaemon","date":"2013-09-05T18:04:00Z","text":"Indeed the type of Ammo is transfered to **ALL** clients, but apparently also the muzzle effects (firing sound, light, etc.); this includes muzzles from Horns (Truck or Car Horn, Bicycle bells, etc.) as well as any other weapon. Tested on ArmA - Arma 2:OA (latest patch)."},{"user":"demellion","date":"2018-11-02T12:16:00Z","text":"**WARNING:** Do not instigate createVehicle or createVehicleLocal within a server function executed with preInit flag.\nThis will cause *\"You cannot play/edit this mission\"* for a vehicles compiled from a -mod and make server skip/loop that mission init."}]}