getUnitTrait: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) (Fix Category:Pages using duplicate arguments in template calls and add getAllUnitTraits link) |
Lou Montana (talk | contribs) |
||
Line 10: | Line 10: | ||
|p2= skillName: [[String]] - Name of the skill |PARAMETER2= | |p2= skillName: [[String]] - Name of the skill |PARAMETER2= | ||
| | | | ||
* [[ | * [[Boolean]] or [[Number]] - trait's value | ||
* [[Nothing]] - if ''unit'' is invalid, e.g an empty vehicle |RETURNVALUE= | * [[Nothing]] - if ''unit'' is invalid, e.g an empty vehicle |RETURNVALUE= | ||
|x1= <code>[[player]] [[getUnitTrait]] "Medic";</code>|EXAMPLE1= | |x1= <code>[[player]] [[getUnitTrait]] "Medic";</code>|EXAMPLE1= |
Revision as of 00:22, 24 August 2020
Description
- Description:
- Gets the current value of a trait of the given unit.
- Groups:
- Uncategorised
Syntax
- Syntax:
- unit getUnitTrait skillName
- Parameters:
- Unit: Object
- skillName: String - Name of the skill
- Return Value:
Examples
- Example 1:
player getUnitTrait "Medic";
Additional Information
- See also:
- setUnitTraitgetAllUnitTraits
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