createVehicle array: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Fixed note formatting)
(changed fly param for land vehicles in example)
Line 31: Line 31:
____________________________________________________________________________________________
____________________________________________________________________________________________
   
   
|x1= <code>_veh <nowiki>=</nowiki> createVehicle ["ah1w", [[position]] [[player]], [], 0, "FLY"]  </code> |= Example 1
|x1= <code>_veh = [[createVehicle]] ["ah1w", [[position]] [[player]], [], 0, "FLY"]  </code> |= Example 1


|x2 = <code>_veh <nowiki>=</nowiki> createVehicle ["2S6M_Tunguska",getMarkerPos "marker1",["marker2","marker3"], 0, "FLY"] </code> |= Example 2
|x2 = <code>_veh = [[createVehicle]] ["2S6M_Tunguska", [[getMarkerPos]] "marker1",["marker2","marker3"], 0, "NONE"] </code> |= Example 2
____________________________________________________________________________________________
____________________________________________________________________________________________


Line 43: Line 43:
<dl class="command_description">
<dl class="command_description">
<!-- Note Section BEGIN -->
<!-- Note Section BEGIN -->
<dd class="notedate">Posted on 25 Jun, 2014 - 15:50</dd>
<dd class="notedate">Posted on 25 Jun, 2014 - 15:50
<dt class="note">[[User:ffur2007slx2_5|ffur2007slx2_5]]</dt>
<dt class="note">'''[[User:ffur2007slx2_5|ffur2007slx2_5]]'''<dd class="note">
<dd class="note">(ArmA3 1.22)Types that [[createVehicle]] can create or not:
(ArmA3 1.22)Types that [[createVehicle]] can create or not:
{| class="wikitable sortable"
{| class="wikitable sortable"


Line 87: Line 87:
| Yes
| Yes


|}</dd></dl>
|}
<!-- Note Section END -->
<!-- Note Section END -->



Revision as of 09:46, 30 July 2014

-wrong parameter ("Arma") defined!-1.00
Hover & click on the images for description

Description

Description:
Creates a vehicle of the given type (type is the name of the subclass in CfgVehicles). If the markers array contains several marker names, the position of a random one is used. Otherwise, the given position is used. The vehicle is placed inside a circle with this position as center and placement as its radius. Special properties can be: "NONE", "FLY" and "FORM". "CAN_COLLIDE" creates the vehicle exactly where asked, not checking if others objects can cross its 3D model.
Groups:
Uncategorised

Syntax

Syntax:
Object = createVehicle [type, position, markers, placement, special]
Parameters:
[type, position, markers, placement, special]: Array
type: String
position: Position
markers: Array
placement: Number
special: String
Return Value:
Object

Examples

Example 1:
_veh = createVehicle ["ah1w", position player, [], 0, "FLY"]
Example 2:
_veh = createVehicle ["2S6M_Tunguska", getMarkerPos "marker1",["marker2","marker3"], 0, "NONE"]

Additional Information

See also:
createVehiclecreateVehicleCrewcreateVehicleLocalcreateUnitcreateUnit arraydeleteVehiclecreateGroupcreateCenter

Notes

Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note

Notes

Posted on 25 Jun, 2014 - 15:50
ffur2007slx2_5
(ArmA3 1.22)Types that createVehicle can create or not:
types availability
unit Yes (unit is lifeless)
vehicles & objects Yes
Locations (Base, Area, Camp, City, Outpost, Town, Village) N/A (Only createVehicleLocal/createUnit available)
Misc (Curator, Lock, Unlock) N/A (Only createVehicleLocal/createUnit available)
Game Logic N/A (Only createVehicleLocal/createUnit available)
Sides (BULFOR, REDFOR, Independent) N/A (Only createVehicleLocal/createUnit available)
Modules N/A (Only createVehicleLocal/createUnit available)
Sources (#lightpoint, #particlesource etc) N/A (Only createVehicleLocal available)
Virtual Entities (Zeus) Yes

Bottom Section

Posted on July 30, 2014 - 01:49 (UTC)
AgentRevolution
In Arma 3, the position parameter for this command is always interpreted as PositionATL.