enableAI: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - "\[\[Category\: ?Command[ _]Group\:.*\|\{\{uc\:\{\{PAGENAME\}\}\}\}\]\] " to "")
No edit summary
 
(42 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{Command|Comments=
{{RV|type=command
____________________________________________________________________________________________


| arma |Game name=
|game1= ofpe
|version1= 1.00


|1.00|Game version=
|game2= arma1
|version2= 1.00


|arg= local |Multiplayer Arguments=
|game3= arma2
|version3= 1.00


|eff= global |Multiplayer Effects=
|game4= arma2oa
|version4= 1.50


|gr1= Object Manipulation |GROUP1=
|game5= tkoh
|version5= 1.00


|gr2= Unit Control |GROUP2=
|game6= arma3
____________________________________________________________________________________________
|version6= 0.50


| Enables parts of the AI behavior that was disabled by [[disableAI]].
|arg= local
<br><br>
{{Important |When player switches and leaves behind AI unit, you need to enable "TeamSwitch" AI on it <tt>_unit [[enableAI]] "TeamSwitch"</tt> so that the unit continues with [[waypoints]] }}
{{Feature Arma3 | Since Arma 3 v1.95.145843 it is possible to return the state of the given AI flag via [[checkAIFeature]] or set it using alias command [[enableAIFeature]]}}|DESCRIPTION=
____________________________________________________________________________________________


| unit '''enableAI''' skilltype |SYNTAX=
|eff= global


|p1= unit: [[Object]]  |PARAMETER1=
|gr1= AI Behaviour


|p2= skilltype: [[String]] - See [[disableAI]] for possible values. |PARAMETER2=
|descr= Enables parts of the AI behavior that was disabled by [[disableAI]].
{{Feature|important|When player switches and leaves behind AI unit, you need to enable "TeamSwitch" AI on it <sqf inline>_unit enableAI "TeamSwitch";</sqf> so that the unit continues with [[waypoints]].}}
{{Feature|arma3|Since Arma 3 v1.96 it is possible to return the state of the given AI flag via [[checkAIFeature]] or set it using alias command [[enableAIFeature]].}}


| [[Nothing]] |RETURNVALUE=
|s1= unit [[enableAI]] skilltype
____________________________________________________________________________________________
 
|x1= <code>_soldierOne [[enableAI]] "Move";</code> |EXAMPLE1=
____________________________________________________________________________________________


| [[disableAI]], [[checkAIFeature]], [[enableAIFeature]], [[vehicleMoveInfo]] |SEEALSO=
|p1= unit: [[Object]]


}}
|p2= skilltype: [[String]] - see [[disableAI]] for possible values.


<h3 style="display:none">Notes</h3>
|r1= [[Nothing]]
<dl class="command_description">
<!-- Note Section BEGIN -->


|x1= <sqf>_soldierOne enableAI "Move";</sqf>


<!-- Note Section END -->
|seealso= [[disableAI]] [[checkAIFeature]] [[enableAIFeature]] [[vehicleMoveInfo]] [[getUnitState]]
</dl>
}}
 
<h3 style="display:none">Bottom Section</h3>
 
[[Category:Scripting Commands|ENABLEAI]]
[[Category:Scripting Commands OFP Elite |ENABLEAI]]
[[Category:Scripting Commands Armed Assault|ENABLEAI]]
[[Category:Scripting Commands Arma 2|{{uc:{{PAGENAME}}}}]]
[[Category:Scripting Commands Arma 3|{{uc:{{PAGENAME}}}}]]
[[Category:Scripting Commands Take On Helicopters|{{uc:{{PAGENAME}}}}]]

Latest revision as of 13:39, 22 October 2024

Hover & click on the images for description

Description

Description:
Enables parts of the AI behavior that was disabled by disableAI.
When player switches and leaves behind AI unit, you need to enable "TeamSwitch" AI on it _unit enableAI "TeamSwitch"; so that the unit continues with waypoints.
Arma 3
Since Arma 3 v1.96 it is possible to return the state of the given AI flag via checkAIFeature or set it using alias command enableAIFeature.
Groups:
AI Behaviour

Syntax

Syntax:
unit enableAI skilltype
Parameters:
unit: Object
skilltype: String - see disableAI for possible values.
Return Value:
Nothing

Examples

Example 1:
_soldierOne enableAI "Move";

Additional Information

See also:
disableAI checkAIFeature enableAIFeature vehicleMoveInfo getUnitState

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