Arma Reforger Explorer
1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Toggle main menu visibility
Loading...
Searching...
No Matches
SCR_HintInfoDisplay.c
Go to the documentation of this file.
1
2
class
SCR_HintInfoDisplay
: SCR_InfoDisplayExtended
3
{
4
[
Attribute
(
desc
:
"Name of the widget to which the SCR_HintUIComponent is attached"
)]
5
protected
string
m_sHintComponentWidget
;
6
7
protected
SCR_HintUIComponent
m_HintComponent
;
8
protected
SCR_InfoDisplaySlotHandler
m_SlotHandler
;
9
protected
SCR_HUDSlotUIComponent
m_HUDSlotComponent
;
10
11
//------------------------------------------------------------------------------------------------
12
override
void
DisplayStartDraw
(
IEntity
owner)
13
{
14
if
(!
m_wRoot
)
15
return
;
16
17
Widget
hintWidget =
m_wRoot
.FindAnyWidget(
m_sHintComponentWidget
);
18
19
if
(!hintWidget)
20
return
;
21
22
m_HintComponent
=
SCR_HintUIComponent
.Cast(hintWidget.FindHandler(
SCR_HintUIComponent
));
23
if
(!
m_HintComponent
)
24
return
;
25
26
m_SlotHandler
=
SCR_InfoDisplaySlotHandler
.Cast(
GetHandler
(
SCR_InfoDisplaySlotHandler
));
27
if
(!
m_SlotHandler
)
28
return
;
29
31
Show
(
false
);
32
33
m_HUDSlotComponent
=
m_SlotHandler
.GetSlotUIComponent();
34
if
(!
m_HUDSlotComponent
)
35
return
;
36
37
m_HintComponent
.GetOnHintShown().Insert(
OnHintShown
);
38
m_HUDSlotComponent
.GetOnResize().Insert(
OnSlotUIResize
);
39
}
40
41
//------------------------------------------------------------------------------------------------
42
override
void
DisplayStopDraw
(
IEntity
owner)
43
{
44
if
(
m_HUDSlotComponent
)
45
m_HUDSlotComponent
.GetOnResize().Remove(
OnSlotUIResize
);
46
47
if
(
m_HintComponent
)
48
m_HintComponent
.GetOnHintShown().Remove(
OnHintShown
);
49
}
50
51
//------------------------------------------------------------------------------------------------
52
override
void
DisplayUpdate
(
IEntity
owner,
float
timeSlice)
53
{
54
//Check if the SlotUIComponent is still valid otherwise change to the new one
55
if
(
m_HUDSlotComponent
!=
m_SlotHandler
.GetSlotUIComponent())
56
{
57
if
(
m_HUDSlotComponent
)
58
m_HUDSlotComponent
.GetOnResize().Remove(
OnSlotUIResize
);
59
60
m_HUDSlotComponent
=
m_SlotHandler
.GetSlotUIComponent();
61
if
(!
m_HUDSlotComponent
)
62
return
;
63
64
m_HUDSlotComponent
.GetOnResize().Insert(
OnSlotUIResize
);
65
}
66
}
67
68
//------------------------------------------------------------------------------------------------
70
protected
void
OnHintShown
(
bool
isShown)
71
{
72
Show
(isShown);
73
}
74
75
//------------------------------------------------------------------------------------------------
77
protected
void
OnSlotUIResize
()
78
{
79
Show
(
m_HintComponent
&&
m_HintComponent
.IsHintShown());
80
}
81
}
m_wRoot
Widget m_wRoot
Definition
SCR_GameModeCleanSweep.c:25
GetHandler
SCR_InfoDisplayHandler GetHandler(typename handlerType)
Definition
SCR_InfoDisplay.c:80
desc
UI Textures DeployMenu Briefing conflict_HintBanner_1_UI desc
Definition
SCR_RespawnBriefingComponent.c:17
IEntity
Definition
IEntity.c:13
SCR_HUDSlotUIComponent
Definition
SCR_HUDSlotUIComponent.c:6
SCR_HintInfoDisplay
Handles SCR_HintUIComponent when using InfoDisplay and HudManager slotting.
Definition
SCR_HintInfoDisplay.c:3
SCR_HintInfoDisplay::OnHintShown
void OnHintShown(bool isShown)
Make it visible / invisible to trigger rezising of the Group.
Definition
SCR_HintInfoDisplay.c:70
SCR_HintInfoDisplay::m_HintComponent
SCR_HintUIComponent m_HintComponent
Definition
SCR_HintInfoDisplay.c:7
SCR_HintInfoDisplay::DisplayUpdate
override void DisplayUpdate(IEntity owner, float timeSlice)
Definition
SCR_HintInfoDisplay.c:52
SCR_HintInfoDisplay::m_HUDSlotComponent
SCR_HUDSlotUIComponent m_HUDSlotComponent
Definition
SCR_HintInfoDisplay.c:9
SCR_HintInfoDisplay::m_SlotHandler
SCR_InfoDisplaySlotHandler m_SlotHandler
Definition
SCR_HintInfoDisplay.c:8
SCR_HintInfoDisplay::m_sHintComponentWidget
string m_sHintComponentWidget
Definition
SCR_HintInfoDisplay.c:5
SCR_HintInfoDisplay::DisplayStopDraw
override void DisplayStopDraw(IEntity owner)
Definition
SCR_HintInfoDisplay.c:42
SCR_HintInfoDisplay::DisplayStartDraw
override void DisplayStartDraw(IEntity owner)
Definition
SCR_HintInfoDisplay.c:12
SCR_HintInfoDisplay::OnSlotUIResize
void OnSlotUIResize()
Make InfoDisplay in-/visible when menu is changed.
Definition
SCR_HintInfoDisplay.c:77
SCR_HintUIComponent
Definition
SCR_HintUIComponent.c:2
SCR_InfoDisplaySlotHandler
Definition
SCR_InfoDisplaySlotHandler.c:3
Widget
Definition
Widget.c:13
Show
override void Show()
Definition
gameLib.c:262
Attribute
SCR_FieldOfViewSettings Attribute
Definition
SendGoalMessage.c:170
scripts
Game
UI
HUD
SCR_HintInfoDisplay.c
Generated by
1.17.0