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_TutorialInstructorComponent.c
Go to the documentation of this file.
1
class
SCR_TutorialInstructorComponentClass
:
ScriptComponentClass
2
{
3
}
4
5
class
SCR_TutorialInstructorComponent :
ScriptComponent
6
{
7
[
Attribute
(defvalue:
"0"
, uiwidget:
UIWidgets
.ComboBox, enums: ParamEnumArray.FromEnum(
SCR_ETutorialCourses
))]
8
protected
SCR_ETutorialCourses
m_eStageConfig;
9
10
protected
SCR_TutorialGamemodeComponent
m_TutorialComponent
;
11
protected
bool
m_bIsEnabled
=
true
;
12
13
//------------------------------------------------------------------------------------------------
14
bool
IsEnabled
()
15
{
16
return
m_bIsEnabled
;
17
}
18
19
//------------------------------------------------------------------------------------------------
20
void
EnableCourse
(
bool
enable)
21
{
22
m_bIsEnabled
= enable;
23
}
24
25
//------------------------------------------------------------------------------------------------
26
SCR_ETutorialCourses
GetCourseType
()
27
{
28
return
m_eStageConfig;
29
}
30
31
//------------------------------------------------------------------------------------------------
32
string
GetAssignedCourseName
()
33
{
34
if
(!
m_TutorialComponent
)
35
return
string
.Empty;
36
37
SCR_TutorialCoursesConfig
coursesConfig =
m_TutorialComponent
.GetCoursesConfig();
38
if
(!coursesConfig)
39
return
string
.Empty;
40
41
if
(!m_eStageConfig)
42
return
string
.Empty;
43
44
SCR_TutorialCourse
course = coursesConfig.GetCourse(m_eStageConfig);
45
if
(!course)
46
return
string
.Empty;
47
48
return
course.
GetTaskTitle
();
49
}
50
51
//------------------------------------------------------------------------------------------------
52
override
void
EOnInit
(
IEntity
owner)
53
{
54
m_TutorialComponent
= SCR_TutorialGamemodeComponent.Cast(
GetGame
().
GetGameMode
().
FindComponent
(SCR_TutorialGamemodeComponent));
55
if
(!
m_TutorialComponent
)
56
return
;
57
58
SCR_VoiceoverSystem
.
GetInstance
().
RegisterActor
(owner);
59
m_TutorialComponent
.RegisterInstructor(
this
);
60
}
61
62
//------------------------------------------------------------------------------------------------
63
override
void
OnPostInit
(
IEntity
owner)
64
{
65
if
(!
GetGame
().InPlayMode())
66
return
;
67
68
SetEventMask
(owner,
EntityEvent
.INIT);
69
}
70
71
//------------------------------------------------------------------------------------------------
72
void
~SCR_TutorialInstructorComponent
()
73
{
74
if
(
m_TutorialComponent
)
75
m_TutorialComponent
.UnregisterInstructor(
this
);
76
}
77
}
GetGame
ArmaReforgerScripted GetGame()
Definition
game.c:1398
GetGameMode
SCR_BaseGameMode GetGameMode()
Definition
SCR_BaseGameModeComponent.c:15
SCR_ETutorialCourses
SCR_ETutorialCourses
Definition
SCR_ETutorialCourses.c:2
m_bIsEnabled
bool m_bIsEnabled
Definition
SCR_PlayerSupplyAllocationComponent.c:23
GetAssignedCourseName
string GetAssignedCourseName()
Definition
SCR_TutorialInstructorComponent.c:32
~SCR_TutorialInstructorComponent
void ~SCR_TutorialInstructorComponent()
Definition
SCR_TutorialInstructorComponent.c:72
EnableCourse
void EnableCourse(bool enable)
Definition
SCR_TutorialInstructorComponent.c:20
m_TutorialComponent
SCR_TutorialGamemodeComponent m_TutorialComponent
Definition
SCR_TutorialInstructorComponent.c:10
GetCourseType
SCR_ETutorialCourses GetCourseType()
Definition
SCR_TutorialInstructorComponent.c:26
GenericComponent::SetEventMask
proto external int SetEventMask(notnull IEntity owner, int mask)
GenericComponent::FindComponent
proto external GenericComponent FindComponent(typename typeName)
IEntity
Definition
IEntity.c:13
SCR_TutorialCourse
Definition
SCR_TutorialCourse.c:3
SCR_TutorialCourse::GetTaskTitle
string GetTaskTitle()
Definition
SCR_TutorialCourse.c:137
SCR_TutorialCoursesConfig
Definition
SCR_TutorialCoursesConfig.c:3
SCR_TutorialInstructorComponentClass
Definition
SCR_TutorialInstructorComponent.c:2
SCR_VoiceoverSystem
Definition
SCR_VoiceoverSystem.c:3
SCR_VoiceoverSystem::RegisterActor
void RegisterActor(notnull IEntity entity)
Definition
SCR_VoiceoverSystem.c:556
SCR_VoiceoverSystem::GetInstance
static SCR_VoiceoverSystem GetInstance()
Definition
SCR_VoiceoverSystem.c:159
ScriptComponentClass
Definition
ScriptComponentClass.c:8
ScriptComponent
Definition
ScriptComponent.c:24
ScriptComponent::EOnInit
void EOnInit(IEntity owner)
UIWidgets
Definition
attributes.c:40
Attribute
SCR_FieldOfViewSettings Attribute
Definition
SendGoalMessage.c:170
EntityEvent
EntityEvent
Various entity events.
Definition
EntityEvent.c:14
IsEnabled
int IsEnabled()
Returns true if the light is enabled.
Definition
SCR_BaseManualCameraComponent.c:239
OnPostInit
@ OnPostInit
Definition
SndComponentCallbacks.c:15
scripts
Game
GameMode
Tutorial
Logic
SCR_TutorialInstructorComponent.c
Generated by
1.17.0