isUIContext

From Bohemia Interactive Community
Jump to: navigation, search
Introduced with Arma 3 version 1.76
  

Click on the images for descriptions

Introduced in

Game:
Arma 3
Version:
1.76

Description

Description:
Returns true if the script originated from some UI control event, for example from "onButtonDown" EH. Exists within parent scope and immediate child scopes.

Syntax

Syntax:
isUIContext
Return Value:
Boolean

Examples

Example 1:
if (isUIContext) then {hint "UI control event"};
Example 2:
_button ctrlSetEventHandler ['ButtonDown',"call {diag_log isUIContext}"]; // Outputs true
Example 3:
_button ctrlSetEventHandler ['ButtonDown',"[] spawn {diag_log isUIContext}"]; // Outputs false

Additional Information

Multiplayer:
-
See also:
canSuspendisRemoteExecutedisRemoteExecutedJIP

Notes

Only post proven facts here. Report bugs on the feedback tracker. Use the talk page or the forums for discussions.
Add New Note | How To

Notes

Bottom Section