Difference between revisions of "secondaryWeapon"

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - "[[Category:Scripting_Commands_Take_On_Helicopters" to "[[Category:Scripting Commands Take On Helicopters")
m (Text replacement - "{{uc:{{PAGENAME}}}}" to "")
 
(3 intermediate revisions by 2 users not shown)
Line 5: Line 5:
  
 
|1.75|Game version=
 
|1.75|Game version=
 +
 +
|gr1= Unit Inventory |GROUP1=
 
____________________________________________________________________________________________
 
____________________________________________________________________________________________
  
Line 43: Line 45:
 
[[Category:Scripting Commands OFP 1.96|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands OFP 1.96|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands OFP 1.99|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands OFP 1.99|{{uc:{{PAGENAME}}}}]]
[[Category:Scripting Commands ArmA|{{uc:{{PAGENAME}}}}]]
+
[[Category:Scripting Commands Armed Assault|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands Arma 2|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands Arma 2|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands Arma 3|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands Arma 3|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands Take On Helicopters|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands Take On Helicopters|{{uc:{{PAGENAME}}}}]]
[[Category:Command_Group:_Weapons|{{uc:{{PAGENAME}}}}]]
 

Latest revision as of 15:14, 27 September 2020

Introduced with Operation Flashpoint: Resistance version 1.751.75
Hover & click on the images for descriptions

Description

Description:
Returns name of a unit's secondary weapon (empty string if none).

Syntax

Syntax:
secondaryWeapon unit
Parameters:
unit: Object
Return Value:
String

Examples

Example 1:
private _secondaryWeapon = secondaryWeapon player;
Example 2:
hint secondaryWeapon player; // "launch_NLAW_F"

Additional Information

See also:
secondaryWeaponMagazinesecondaryWeaponItemsaddSecondaryWeaponItem primaryWeaponhandgunWeaponcurrentWeaponweapons
Groups:
Unit Inventory

Notes

i
Only post proven facts here. Report bugs on the Feedback Tracker and discuss on the Arma Discord or on the Forums.

Notes

Posted on August 4, 2006 - 10:58
hardrock
Notes from before the conversion: secondaryWeapon tells you what weapon the unit has irrespective of the status of the weapon. For example a unit that has a LAWLauncher on his back will still report a LAWLauncher as its secondary weapon. Use currentWeapon to detect the active weapon.

Bottom Section