Arma Reforger Explorer 1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Loading...
Searching...
No Matches
SCR_HideWidgetPlatformBased.c
Go to the documentation of this file.
3 WINDOWS = 1 << EPlatform.WINDOWS,
4 LINUX = 1 << EPlatform.LINUX,
5 XBOX_ONE = 1 << EPlatform.XBOX_ONE,
6 XBOX_ONE_S = 1 << EPlatform.XBOX_ONE_S,
7 XBOX_ONE_X = 1 << EPlatform.XBOX_ONE_X,
8 XBOX_SERIES_S = 1 << EPlatform.XBOX_SERIES_S,
9 XBOX_SERIES_X = 1 << EPlatform.XBOX_SERIES_X,
10 PS4 = 1 << EPlatform.PS4,
11 PS5 = 1 << EPlatform.PS5,
12 PS5_PRO = 1 << EPlatform.PS5_PRO,
13 UNKNOWN = 1 << EPlatform.UNKNOWN,
14}
15
16class SCR_HideWidgetPlatformBased : ScriptedWidgetComponent
17{
18 [Attribute(uiwidget: UIWidgets.Flags, enums: ParamEnumArray.FromEnum(SCR_EPlatform))]
19 private SCR_EPlatform m_eHideOnPlatform;
20
21 //------------------------------------------------------------------------------------------------
22 override void HandlerAttached(Widget w)
23 {
24 // Get current Platform in EPlatform enum
25 EPlatform currentPlatform = System.GetPlatform();
26
27 w.SetVisible(!(m_eHideOnPlatform & (1 << currentPlatform)) == (1 << currentPlatform));
28 }
29}
override void HandlerAttached(Widget w)
SCR_FieldOfViewSettings Attribute
EPlatform
Definition EPlatform.c:13
@ XBOX_SERIES_X
Definition EPlatform.c:20
@ XBOX_ONE
Definition EPlatform.c:16
@ XBOX_ONE_X
Definition EPlatform.c:18
@ PS5_PRO
Definition EPlatform.c:23
@ PS5
Definition EPlatform.c:22
@ XBOX_SERIES_S
Definition EPlatform.c:19
@ PS4
Definition EPlatform.c:21
@ UNKNOWN
Definition EPlatform.c:24
@ LINUX
Definition EPlatform.c:15
@ XBOX_ONE_S
Definition EPlatform.c:17
@ WINDOWS
Definition EPlatform.c:14