Arma 3 Scripting

focusOn

  • Arma 3 v2.16

Command · also in Remote Control · Markdown · JSON · original wiki page

Description

Returns the person the camera is focused on. If you need the vehicle, see cameraOn.

Syntax

focusOn

Returns: 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";
};

See also

switchCamera · cameraView · cameraEffect · cameraOn · remoteControl