hasWeapon: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - " " to " ") |
Lou Montana (talk | contribs) m (Text replacement - " +<\/code>" to "</code>") |
||
Line 33: | Line 33: | ||
<dd class="note"> | <dd class="note"> | ||
This command doesn't work for Items in Arma 3, use this instead. | This command doesn't work for Items in Arma 3, use this instead. | ||
<code>"[[Arma_3_CfgWeapons_Items#ItemGPS|ItemGPS]]" [[in]] ([[items]] [[player]] [[valuea_plus_valueb|+]] [[assignedItems]] [[player]])<br>'''OR'''<br>'[[Arma_3_CfgWeapons_Items#ItemGPS|ItemGPS]]' [[in]] ([[items]] [[player]] [[valuea_plus_valueb|+]] [[assignedItems]] [[player]]) </code> | <code>"[[Arma_3_CfgWeapons_Items#ItemGPS|ItemGPS]]" [[in]] ([[items]] [[player]] [[valuea_plus_valueb|+]] [[assignedItems]] [[player]])<br>'''OR'''<br>'[[Arma_3_CfgWeapons_Items#ItemGPS|ItemGPS]]' [[in]] ([[items]] [[player]] [[valuea_plus_valueb|+]] [[assignedItems]] [[player]])</code> | ||
Returns [[true]] if unit has gps in inventory, assigned or not. | Returns [[true]] if unit has gps in inventory, assigned or not. | ||
Revision as of 22:49, 10 June 2021
Description
- Description:
- Description needed
- Groups:
- WeaponsUnit Inventory
Syntax
- Syntax:
- Syntax needed
- Parameters:
- unitName: Object
- weaponName: String - the name of the weapon to check for.
- Return Value:
- Return value needed
Examples
- Example 1:
if !(player hasWeapon "arifle_MX_ACO_pointer_F") then { player addWeapon "arifle_MX_ACO_pointer_F" };
Additional Information
- See also:
- weapons
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