attackEnabled: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
mNo edit summary
m (Some wiki formatting)
 
(35 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= global |Multiplayer Arguments=
|game3= arma2
|version3= 1.00


|gr1= Object Manipulation |GROUP1=
|game4= arma2oa
____________________________________________________________________________________________
|version4= 1.50


| Return whether a group's leader can issue attack commands to soldiers under his command. |DESCRIPTION=
|game5= tkoh
____________________________________________________________________________________________
|version5= 1.00


| [[Boolean]] <nowiki>=</nowiki> '''attackEnabled''' name |SYNTAX=
|game6= arma3
|version6= 0.50


|p1= name: [[Object]] or [[Group]] |PARAMETER1=
|arg= global


| [[Boolean]] |RETURNVALUE=
|gr1= Groups
____________________________________________________________________________________________
 
|x1= <code>if (not '''attackEnabled''' _soldier) then {_soldier [[setCombatMode]] "Careless"} </code> |EXAMPLE1=
____________________________________________________________________________________________


| [[enableAttack]] |SEEALSO=
|gr2= Unit Control


}}
|descr= Return whether a group's leader can issue attack commands to soldiers under his command.


<h3 style="display:none">Notes</h3>
|s1= [[attackEnabled]] name
<dl class="command_description">


<!-- Note Section BEGIN -->
|p1= name: [[Object]] or [[Group]]


<!-- Note Section END -->
|r1= [[Boolean]]
</dl>


<h3 style="display:none">Bottom Section</h3>
|x1= <sqf>if (not attackEnabled _soldier) then { _soldier setCombatMode "Careless" };</sqf>


[[Category:Scripting Commands|{{uc:{{PAGENAME}}}}]]
|seealso= [[enableAttack]]
[[Category:Scripting Commands OFP Elite|{{uc:{{PAGENAME}}}}]]
}}
[[Category:Scripting Commands Armed Assault|{{uc:{{PAGENAME}}}}]]
[[Category:Command_Group: Object Manipulation|{{uc:{{PAGENAME}}}}]]
[[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 16:07, 13 May 2022

Hover & click on the images for description

Description

Description:
Return whether a group's leader can issue attack commands to soldiers under his command.
Groups:
GroupsUnit Control

Syntax

Syntax:
attackEnabled name
Parameters:
name: Object or Group
Return Value:
Boolean

Examples

Example 1:
if (not attackEnabled _soldier) then { _soldier setCombatMode "Careless" };

Additional Information

See also:
enableAttack

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