4 private CreditsMenu m_CreditsMenu;
19 #ifdef PLATFORM_CONSOLE
20 if (
g_Game.GetGameState() != DayZGameState.PARTY )
34 #ifdef PLATFORM_CONSOLE
35 delete m_IntroSceneXbox;
37 delete m_IntroScenePC;
45 #ifdef PLATFORM_CONSOLE
46 Error(
"missionMainMenu->GetIntroScenePC on PLATFORM_CONSOLE is not implemented!");
49 return m_IntroScenePC;
55 #ifdef PLATFORM_CONSOLE
56 return m_IntroSceneXbox;
58 Error(
"missionMainMenu->GetIntroScenePC on PLATFORM_PC is not implemented!");
63 void CreateIntroScene()
65 #ifdef PLATFORM_CONSOLE
72 override void UpdateInputDevicesAvailability()
74 super.UpdateInputDevicesAvailability();
76 g_Game.GetInput().UpdateConnectedInputDeviceList();
77 g_Game.UpdateInputDeviceDisconnectWarning();
80 override void OnMissionStart()
86 g_Game.GetUIManager().ShowUICursor(
true);
87 g_Game.SetMissionState( DayZGame.MISSION_STATE_MAINMENU );
95 override void OnMissionFinish()
99 GetGame().GetUIManager().CloseAll();
102 m_IntroScenePC =
null;
103 m_IntroSceneXbox =
null;
104 m_CreditsMenu =
null;
105 #ifndef FEATURE_CURSOR
106 g_Game.GetUIManager().ShowUICursor(
false);
110 override void OnUpdate(
float timeslice)
112 super.OnUpdate(timeslice);
114 #ifdef DIAG_DEVELOPER
115 UpdateInputDeviceDiag();
125 m_IntroScenePC.Update();
129 void OnMenuEnter(
int menu_id)
135 m_CreditsMenu = CreditsMenu.Cast(
GetGame().GetUIManager().GetMenu());
144 m_CreditsMenu.UpdateInfoPanelText(device);
154 SoundObject soundObject = soundBuilder.BuildSoundObject();
155 soundObject.SetKind(
WaveKind.WAVEMUSIC );
156 m_MenuMusic =
GetGame().GetSoundScene().Play2D(soundObject, soundBuilder);
157 m_MenuMusic.Loop(
true );
173 int SortedInsert(
array<int> list,
int number )
175 int find_number = number;
177 int index_max = list.Count() - 1;
178 int target_index =
Math.Floor( index_max / 2 );
180 if ( index_max == -1 )
182 list.Insert( number );
188 int target_value = list[target_index];
190 if ( find_number == target_value || ((index_max - index_min) <= 1) )
192 for (
int i = index_min; i <= index_max; i++ )
194 if ( find_number <= list[i] )
196 list.InsertAt( find_number, i );
202 list.InsertAt( find_number, index_max );
205 else if ( find_number < target_value )
207 index_max = target_index;
208 target_index =
Math.Floor( target_index / 2 );
210 else if ( find_number > target_value )
212 index_min = target_index;
213 target_index +=
Math.Floor( (index_max - index_min) / 2 );