setUnitPos: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - "[[Category:Scripting_Commands_Take_On_Helicopters" to "[[Category:Scripting Commands Take On Helicopters") |
Lou Montana (talk | contribs) m (Text replacement - "<sqf>([^↵][^<]*↵[^<]*)<\/sqf>" to "<sqf> $1 </sqf>") |
||
(41 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
{{ | {{RV|type=command | ||
| ofp | | |game1= ofp | ||
|version1= 1.00 | |||
|1.00 | |game2= ofpe | ||
|version2= 1.00 | |||
| | |game3= arma1 | ||
| | |version3= 1.00 | ||
| | |game4= arma2 | ||
|version4= 1.00 | |||
| | |game5= arma2oa | ||
|version5= 1.50 | |||
| | |game6= tkoh | ||
|version6= 1.00 | |||
| | |game7= arma3 | ||
|version7= 0.50 | |||
| | |eff= global | ||
| | |arg= local | ||
| | |gr1= Unit Control | ||
|descr= Set unit position rules. This command will not change the stance of the human player, even though it will change the output of [[unitPos]] command. To change player stance use [[playAction]] or [[playActionNow]]: | |||
<sqf> | |||
player playAction "PlayerProne"; // DOWN | |||
player playAction "PlayerStand"; // UP | |||
player playAction "PlayerCrouch"; // MIDDLE | |||
</sqf> | |||
|s1= unit [[setUnitPos]] mode | |||
|p1= unit: [[Object]] | |||
|p2= mode: [[String]] - can be: | |||
* "DOWN" - Unit goes prone and stays prone. | |||
* "UP" - Unit stands and stays standing. | |||
* "MIDDLE" - Kneel Position. {{GVI|arma1|1.04}} - Unit will not kneel if it is unarmed | |||
* "AUTO" - Unit chooses mode according to circumstances. | |||
|r1= [[Nothing]] | |||
|x1= <sqf>_soldier setUnitPos "UP";</sqf> | |||
|seealso= [[setUnitPosWeak]] [[unitPos]] | |||
}} | }} | ||
<dl class="command_description"> | <dl class="command_description"> | ||
<dd class="notedate">Posted on 18 September | <dt><dt> | ||
<dt class="note"> | <dd class="notedate">Posted on 18 September 2008 </dd> | ||
<dt class="note">[[User:Dwarden|Dwarden]]</dt> | |||
<dd class="note"> | <dd class="note"> | ||
Command most likely only works if run before [[join]] into group after [[createUnit]]. | Command most likely only works if run before [[join]] into group after [[createUnit]]. | ||
<dt><dt> | |||
<dd class="notedate">Posted on 11 March 2011 | <dd class="notedate">Posted on 11 March 2011</dd> | ||
<dt class="note"> | <dt class="note">[[User:.kju|.kju]]</dt> | ||
<dd class="note"> | <dd class="note"> | ||
The above comment by [[User:Dwarden|Dwarden]] about 'an additional join required' is no longer true for Operation Arrowhead. | The above comment by [[User:Dwarden|Dwarden]] about 'an additional join required' is no longer true for Operation Arrowhead. | ||
<dt><dt> | |||
<dd class="notedate">Posted on 26 September | <dd class="notedate">Posted on 26 September 2013</dd> | ||
<dt class="note"> | <dt class="note">[[User:Katulobotomia|Katulobotomia]]</dt> | ||
<dd class="note"> | <dd class="note"> | ||
A unit might not always go prone when ordered to [[setUnitPos]] "DOWN", if the unit doesn't agree with the command. To force the unit to go prone, stop the unit from firing by [[setCombatMode]] "BLUE" and then order the unit to prone. | A unit might not always go prone when ordered to [[setUnitPos]] "DOWN", if the unit doesn't agree with the command. To force the unit to go prone, stop the unit from firing by [[setCombatMode]] "BLUE" and then order the unit to prone. | ||
</dl> | </dl> | ||
Latest revision as of 19:42, 3 September 2024
Description
- Description:
- Set unit position rules. This command will not change the stance of the human player, even though it will change the output of unitPos command. To change player stance use playAction or playActionNow:
player playAction "PlayerProne"; // DOWN player playAction "PlayerStand"; // UP player playAction "PlayerCrouch"; // MIDDLE
- Groups:
- Unit Control
Syntax
- Syntax:
- unit setUnitPos mode
- Parameters:
- unit: Object
- mode: String - can be:
- "DOWN" - Unit goes prone and stays prone.
- "UP" - Unit stands and stays standing.
- "MIDDLE" - Kneel Position. 1.04 - Unit will not kneel if it is unarmed
- "AUTO" - Unit chooses mode according to circumstances.
- Return Value:
- Nothing
Examples
- Example 1:
- _soldier setUnitPos "UP";
Additional Information
- See also:
- setUnitPosWeak unitPos
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
- Posted on 18 September 2008
- Dwarden
- Command most likely only works if run before join into group after createUnit.
- Posted on 11 March 2011
- .kju
- The above comment by Dwarden about 'an additional join required' is no longer true for Operation Arrowhead.
- Posted on 26 September 2013
- Katulobotomia
- A unit might not always go prone when ordered to setUnitPos "DOWN", if the unit doesn't agree with the command. To force the unit to go prone, stop the unit from firing by setCombatMode "BLUE" and then order the unit to prone.
Categories:
- Scripting Commands
- Introduced with Operation Flashpoint version 1.00
- Operation Flashpoint: New Scripting Commands
- Operation Flashpoint: Scripting Commands
- Operation Flashpoint: Elite: Scripting Commands
- ArmA: Armed Assault: Scripting Commands
- Arma 2: Scripting Commands
- Arma 2: Operation Arrowhead: Scripting Commands
- Take On Helicopters: Scripting Commands
- Arma 3: Scripting Commands
- Command Group: Unit Control
- Scripting Commands: Global Effect