Description
Returns name of unit's primary weapon. This command will also return a weapon class name if the weapon is not used by the player, for example, it is on the unit's back. Use currentWeapon to get the weapon the unit is using.
Syntax
primaryWeapon unit
Parameters:
unit: Object
Returns: String - weapon class name or "" if no primary weapon
Examples
Example 1
_pWeap = primaryWeapon player;
Example 2
hint primaryWeapon player; // "arifle_MX_ACO_pointer_F"
See also
primaryWeaponMagazine · primaryWeaponItems · addPrimaryWeaponItem · removePrimaryWeaponItem · removeAllPrimaryWeaponItems · secondaryWeapon · handgunWeapon · currentWeapon · weapons