currentVisionMode: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Some wiki formatting) |
Lou Montana (talk | contribs) (Add more examples) |
||
Line 54: | Line 54: | ||
|r4= [[Array]] in format [vision mode, FLIR index] | |r4= [[Array]] in format [vision mode, FLIR index] | ||
|x1= <sqf> | |x1= <sqf>_visionMode = currentVisionMode gunner _tank;</sqf> | ||
|x2= <sqf> | |x2= <sqf> | ||
Line 62: | Line 62: | ||
}; | }; | ||
</sqf> | </sqf> | ||
|x3= <sqf> | |||
private _detailedVisionMode = currentVisionMode [gunner _tank]; | |||
_detailedVisionMode params ["_mode", "_flirIndex"]; | |||
</sqf> | |||
|x4= <sqf>private _detailedGunnerVisionMode = _tank currentVisionMode [0];</sqf> | |||
|x5= <sqf>private _detailedWeaponVisionMode = player currentVisionMode "";</sqf> | |||
|seealso= [[disableNVGEquipment]] [[disableTIEquipment]] [[camUseNVG]] [[setCamUseTI]] [[currentMagazine]] [[currentWeapon]] [[currentMuzzle]] [[currentWeaponMode]] [[currentZeroing]] [[magazinesTurret]] [[weaponsTurret]] | |seealso= [[disableNVGEquipment]] [[disableTIEquipment]] [[camUseNVG]] [[setCamUseTI]] [[currentMagazine]] [[currentWeapon]] [[currentMuzzle]] [[currentWeaponMode]] [[currentZeroing]] [[magazinesTurret]] [[weaponsTurret]] |
Latest revision as of 16:19, 16 December 2022
Description
- Description:
- Returns current vision mode of unit's weapon. Vision mode could be one of:
- 0 - normal vision
- 1 - night vision
- 2 - thermal vision
- Groups:
- Weapons
Syntax 1
- Syntax:
- currentVisionMode entity
- Parameters:
- entity: Object - unit or vehicle. Unit query returns current vision mode of the unit. Vehicle query returns driver seat vision mode
- Return Value:
- Number - vision mode
Syntax 2
- Syntax:
- currentVisionMode [entity]
- Parameters:
- entity: Object - unit or vehicle. Unit query returns current vision mode of the unit. Vehicle query returns driver seat vision mode
- Return Value:
- Array in format [vision mode, FLIR index]
Syntax 3
- Syntax:
- vehicle currentVisionMode turretPath
- Parameters:
- vehicle: Object - vehicle with vision modes
- turretPath: Array format Turret Path - path to vehicle's turret. Use [-1] for driver turret, [] for default primary gunner turret
- Return Value:
- Array in format [vision mode, FLIR index]
Syntax 4
- Syntax:
- unit currentVisionMode weapon
- Parameters:
- unit: Object - soldier
- weapon: String - unit's weapon. Use "" for current weapon
- Return Value:
- Array in format [vision mode, FLIR index]
Examples
- Example 1:
- Example 2:
- Example 3:
- Example 4:
- Example 5:
Additional Information
- See also:
- disableNVGEquipment disableTIEquipment camUseNVG setCamUseTI currentMagazine currentWeapon currentMuzzle currentWeaponMode currentZeroing magazinesTurret weaponsTurret
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
- Posted on Apr 29, 2016 - 21:31 (UTC)
-
The return value is somewhat erratic for UAVs. For example, if you are connected to a UAV, with the turret set to thermal vision and PIP feed enabled, "currentVisionMode gunner _uav" returns 2 when controlling the turret, but returns 0 after releasing control, even thought the PIP feed is still in thermal mode. WIth nightvision, it will return 1 whether or not you are controlling the turret, but if you switch from 1st to 3rd person before releasing control, then it returns 0 afterwards...