focusOn

From Bohemia Interactive Community
Revision as of 18:41, 26 March 2024 by Lou Montana (talk | contribs) (Text replacement - "↵|branch= dev↵↵" to " ")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
Hover & click on the images for description

Description

Description:
Returns the person the camera is focused on. If you need the vehicle, see cameraOn.
Groups:
Camera ControlRemote Control

Syntax

Syntax:
focusOn
Return Value:
Object - controlled person or objNull if no unit is controlled

Examples

Example 1:
private _currentlyControlledUnit = focusOn;
Example 2:
if (isNull player) exitWith { /* no player */ }; if (player == focusOn) then { hint "You are controlling your player unit"; } else { hint "You are remote-controlling a unit"; };

Additional Information

See also:
switchCamera cameraView cameraEffect cameraOn remoteControl

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