Arma Reforger Explorer  1.1.0.42
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
SCR_TutorialNavigation7.c
Go to the documentation of this file.
1 [EntityEditorProps(insertable: false)]
3 {
4 };
5 
6 //------------------------------------------------------------------------------------------------
8 {
9  //------------------------------------------------------------------------------------------------
10  override protected void Setup()
11  {
12  SCR_MapEntity.GetOnMapClose().Remove(m_TutorialComponent.OnMapClose);
13  SCR_MapEntity.GetOnMapClose().Insert(m_TutorialComponent.OnMapClose);
14 
15  SCR_MapEntity mapEnt = SCR_MapEntity.GetMapInstance();
16  if (!mapEnt)
17  return;
18 
19  SCR_MapToolMenuUI toolMenuUI = SCR_MapToolMenuUI.Cast(mapEnt.GetMapUIComponent(SCR_MapToolMenuUI));
20  if (!toolMenuUI)
21  return;
22 
23  array<ref SCR_MapToolEntry> tools = toolMenuUI.GetMenuEntries();
24 
25  Widget toolButton;
26  SCR_MapToolEntry rulerTool;
27  foreach (int i, SCR_MapToolEntry tool : tools)
28  {
29  if (tool.m_sIconQuad == "ruler")
30  {
31  toolButton = GetGame().GetWorkspace().FindAnyWidget("ToolMenuButton"+i);
32  rulerTool = tool;
33  }
34  }
35 
36  if (!rulerTool.IsEntryActive())
37  rulerTool.m_OnClick.Invoke();
38 
39  PlaySoundSystem("Navigation_ProtractorSelected");
40  HintOnVoiceOver();
41  }
42 
43  //------------------------------------------------------------------------------------------------
44  override protected bool GetIsFinished()
45  {
46  return !m_TutorialComponent.GetIsMapOpen();
47  }
48 }
SCR_BaseCampaignTutorialArlandStage
Definition: SCR_BaseCampaignTutorialArlandStage.c:7
SCR_TutorialNavigation7Class
Definition: SCR_TutorialNavigation7.c:2
EntityEditorProps
enum EQueryType EntityEditorProps(category:"GameScripted/Sound", description:"THIS IS THE SCRIPT DESCRIPTION.", color:"0 0 255 255")
Definition: SCR_AmbientSoundsComponent.c:12
GetGame
ArmaReforgerScripted GetGame()
Definition: game.c:1424
SCR_MapToolEntry
Map tool menu entry data class.
Definition: SCR_MapToolMenuUI.c:2
SCR_MapEntity
Map entity.
Definition: SCR_MapEntity.c:20
SCR_BaseCampaignTutorialArlandStageClass
Definition: SCR_BaseCampaignTutorialArlandStage.c:2
SCR_TutorialNavigation7
Definition: SCR_TutorialNavigation7.c:7
SCR_MapToolMenuUI
void SCR_MapToolMenuUI()
Definition: SCR_MapToolMenuUI.c:389