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_Tutorial_Intro_WakeUp.c
Go to the documentation of this file.
1
[
EntityEditorProps
(insertable:
false
)]
2
class
SCR_Tutorial_Intro_WakeUpClass
:
SCR_BaseTutorialStageClass
3
{
4
};
5
6
//------------------------------------------------------------------------------------------------
7
class
SCR_Tutorial_Intro_WakeUp
:
SCR_BaseTutorialStage
8
{
9
SCR_CharacterControllerComponent
m_CharController;
10
11
//------------------------------------------------------------------------------------------------
12
override
protected
void
Setup
()
13
{
14
if
(!
m_Player
)
15
m_TutorialComponent
.GetOnPlayerSpawned().Insert(
OnPlayerSpawned
);
16
else
17
OnPlayerSpawned
();
18
}
19
20
//------------------------------------------------------------------------------------------------
21
protected
void
OnPlayerSpawned
()
22
{
23
m_fStartTimestamp
=
GetGame
().GetWorld().GetWorldTime();
24
25
GetGame
().GetCallqueue().Remove(
ShowHint
);
26
GetGame
().GetCallqueue().CallLater(
ShowHint
,
m_StageInfo
.GetFailsafeHintTimeout() * 1000,
false
, 0);
27
28
if
(!
m_Player
)
29
m_Player
=
m_TutorialComponent
.GetPlayer();
30
31
m_CharController =
SCR_CharacterControllerComponent
.Cast(
m_Player
.FindComponent(
SCR_CharacterControllerComponent
));
32
33
m_TutorialComponent
.GetOnPlayerSpawned().Remove(
OnPlayerSpawned
);
34
m_TutorialComponent
.PlayBedAnimation(
true
);
35
36
//Delete items from player inventory for intro reasons
37
const
SCR_InventoryStorageManagerComponent inventory =
m_TutorialComponent
.GetPlayerInventory();
38
IEntity
binoculars = inventory.FindItem(SCR_ResourceNamePredicate(
"{0CF54B9A85D8E0D4}Prefabs/Items/Equipment/Binoculars/Binoculars_M22/Binoculars_M22.et"
),
EStoragePurpose
.PURPOSE_ANY);
39
SCR_EntityHelper
.DeleteEntityAndChildren(binoculars);
40
41
IEntity
gloves = inventory.FindItem(SCR_ResourceNamePredicate(
"{D19C474FA0F42CC4}Prefabs/Characters/Handwear/Gloves_Pilot_US_01/Gloves_Pilot_US_01.et"
),
EStoragePurpose
.PURPOSE_ANY);
42
SCR_EntityHelper
.DeleteEntityAndChildren(gloves);
43
44
SCR_VoiceoverSystem
.
GetInstance
().
RegisterActor
(
GetGame
().
GetWorld
().FindEntityByName(
"Soldier_DoorGuard"
));
45
46
GetGame
().GetCallqueue().CallLater(
PlayNarrativeCharacterStage
, 1000,
false
,
"Soldier_DoorGuard"
, 3);
47
48
SCR_TutorialLogic_FreeRoam
logic =
SCR_TutorialLogic_FreeRoam
.Cast(
m_Logic
);
49
if
(!logic)
50
return
;
51
52
logic.
SetUpAmbulance
();
53
logic.
PrepareDrivingCourseInstructor
();
54
}
55
56
//------------------------------------------------------------------------------------------------
57
override
protected
bool
GetIsFinished
()
58
{
59
if
(!m_CharController)
60
return
false
;
61
62
return
!m_CharController.IsLoitering() &&
GetDuration
() > 2000;
63
}
64
}
GetGame
ArmaReforgerScripted GetGame()
Definition
game.c:1398
EntityEditorProps
enum SCR_ECompassType EntityEditorProps(category:"GameScripted/Gadgets", description:"Compass", color:"0 0 255 255")
Prefab data class for compass component.
Definition
SCR_CompassComponent.c:10
IEntity::IEntity
void IEntity(IEntitySource src, IEntity parent)
protected script Constructor
IEntity::GetWorld
proto external BaseWorld GetWorld()
SCR_BaseTutorialStageClass
Definition
SCR_BaseTutorialStage.c:3
SCR_BaseTutorialStage
Definition
SCR_BaseTutorialStage.c:8
SCR_BaseTutorialStage::ShowHint
void ShowHint(int index=0)
Definition
SCR_BaseTutorialStage.c:192
SCR_BaseTutorialStage::m_Player
ChimeraCharacter m_Player
Definition
SCR_BaseTutorialStage.c:27
SCR_BaseTutorialStage::m_StageInfo
SCR_TutorialStageInfo m_StageInfo
Definition
SCR_BaseTutorialStage.c:32
SCR_BaseTutorialStage::m_Logic
SCR_BaseTutorialCourseLogic m_Logic
Definition
SCR_BaseTutorialStage.c:33
SCR_BaseTutorialStage::GetDuration
float GetDuration()
Definition
SCR_BaseTutorialStage.c:42
SCR_BaseTutorialStage::m_fStartTimestamp
float m_fStartTimestamp
Definition
SCR_BaseTutorialStage.c:22
SCR_BaseTutorialStage::m_TutorialComponent
SCR_TutorialGamemodeComponent m_TutorialComponent
Definition
SCR_BaseTutorialStage.c:29
SCR_BaseTutorialStage::PlayNarrativeCharacterStage
void PlayNarrativeCharacterStage(string characterName, int stage)
Definition
SCR_BaseTutorialStage.c:510
SCR_CharacterControllerComponent
Definition
SCR_CharacterControllerComponent.c:36
SCR_EntityHelper
Definition
SCR_EntityHelper.c:2
SCR_Tutorial_Intro_WakeUpClass
Definition
SCR_Tutorial_Intro_WakeUp.c:3
SCR_Tutorial_Intro_WakeUp
Definition
SCR_Tutorial_Intro_WakeUp.c:8
SCR_Tutorial_Intro_WakeUp::OnPlayerSpawned
void OnPlayerSpawned()
Definition
SCR_Tutorial_Intro_WakeUp.c:21
SCR_Tutorial_Intro_WakeUp::GetIsFinished
bool GetIsFinished()
Definition
SCR_Tutorial_Intro_WakeUp.c:57
SCR_Tutorial_Intro_WakeUp::Setup
void Setup()
Definition
SCR_Tutorial_Intro_WakeUp.c:12
SCR_TutorialLogic_FreeRoam
Definition
SCR_TutorialLogic_FreeRoam.c:3
SCR_TutorialLogic_FreeRoam::PrepareDrivingCourseInstructor
void PrepareDrivingCourseInstructor()
Definition
SCR_TutorialLogic_FreeRoam.c:147
SCR_TutorialLogic_FreeRoam::SetUpAmbulance
void SetUpAmbulance()
Definition
SCR_TutorialLogic_FreeRoam.c:6
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
EStoragePurpose
EStoragePurpose
Definition
EStoragePurpose.c:13
scripts
Game
GameMode
Tutorial
Stages
INTRO
SCR_Tutorial_Intro_WakeUp.c
Generated by
1.17.0