BIS fnc scriptedMove: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - " <h3 style="display:none">Notes</h3> <dl class="command_description"> <!-- Note Section BEGIN --> <!-- Note Section END --> </dl> " to "")
m (Text replacement - " *\| *([Cc]omments|COMMENTS|[Gg]ame [Nn]ame|Game [Vv]ersion|Game Version \(number surrounded by NO SPACES\)|Multiplayer Arguments \("local" or "global"\)|Multiplayer Effects \("local" or "global"\)|Multiplayer Execution \("server" o...)
Line 1: Line 1:
{{Function|Comments=
{{Function


| arma2oa |Game name=
| arma2oa


|1.51|Game version=
|1.51


|gr1 = Object Manipulation |GROUP1=
|gr1 = Object Manipulation


| Force a unit to turn towards and walk to |Description=
| Force a unit to turn towards and walk to


| [unit, waypoints'', code, walkAnim, animLength''] call [[BIS_fnc_scriptedMove]] |Syntax=
| [unit, waypoints'', code, walkAnim, animLength''] call [[BIS_fnc_scriptedMove]]


|p1= unit: [[Object]] |Parameter 1=
|p1= unit: [[Object]]


|p2= waypoints: [[Array]] of [[Position|Positions]] |Parameter 2=
|p2= waypoints: [[Array]] of [[Position|Positions]]


|p3= code: [[Code]] - (Optional, default {{Inline code|<nowiki>{}</nowiki>}}) code to run after waypoint completion |Parameter 3=
|p3= code: [[Code]] - (Optional, default {{Inline code|<nowiki>{}</nowiki>}}) code to run after waypoint completion


|p4= walkAnim: [[String]] - (Optional, default "AmovPercMwlkSnonWnonDf") |Parameter 4=
|p4= walkAnim: [[String]] - (Optional, default "AmovPercMwlkSnonWnonDf")


|p5= animLength: [[Number]] - ('''not''' optional if ''walkAnim'' is defined) |Parameter 5=
|p5= animLength: [[Number]] - ('''not''' optional if ''walkAnim'' is defined)


| [[Script_(Handle)|Script Handle]] |Return value=
| [[Script_(Handle)|Script Handle]]


|x1= <code>[myUnit, [<nowiki/>[[getMarkerPos]] "wp1", [[getMarkerPos]] "wp2", [[getMarkerPos]] "wp3"]] [[call]] [[BIS_fnc_scriptedMove]];</code> |Example 1=
|x1= <code>[myUnit, [<nowiki/>[[getMarkerPos]] "wp1", [[getMarkerPos]] "wp2", [[getMarkerPos]] "wp3"]] [[call]] [[BIS_fnc_scriptedMove]];</code>


| [[move]], [[setDriveOnPath]] |See also=
| [[move]], [[setDriveOnPath]]
}}
}}



Revision as of 23:44, 17 January 2021

Hover & click on the images for description

Description

Description:
Force a unit to turn towards and walk to
Execution:
call
Groups:
Object Manipulation

Syntax

Syntax:
[unit, waypoints, code, walkAnim, animLength] call BIS_fnc_scriptedMove
Parameters:
unit: Object
waypoints: Array of Positions
code: Code - (Optional, default {}) code to run after waypoint completion
walkAnim: String - (Optional, default "AmovPercMwlkSnonWnonDf")
animLength: Number - (not optional if walkAnim is defined)
Return Value:
Script Handle

Examples

Example 1:
[myUnit, [getMarkerPos "wp1", getMarkerPos "wp2", getMarkerPos "wp3"]] call BIS_fnc_scriptedMove;

Additional Information

See also:
movesetDriveOnPath

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

Bottom Section