MCPcopy Create free account
hub / github.com/OpenRCT2/OpenRCT2 / LoadTrackManager

Function LoadTrackManager

src/openrct2/Editor.cpp:213–235  ·  view source on GitHub ↗

* * rct2: 0x006729FD */

Source from the content-addressed store, hash-verified

211 * rct2: 0x006729FD
212 */
213 void LoadTrackManager()
214 {
215 // TODO: replace with dedicated scene
216 auto* sceneMgr = GetContext()->GetSceneManager();
217 sceneMgr->setActiveScene(sceneMgr->getGameScene());
218
219 Audio::StopAll();
220 gLegacyScene = LegacyScene::trackDesignsManager;
221 gScreenAge = 0;
222
223 auto& gameState = getGameState();
224 gameStateInitAll(gameState, kDefaultMapSize);
225 SetAllLandOwned();
226 gameState.editorStep = Editor::Step::objectSelection;
227 ObjectListLoad();
228 ContextResetSubsystems();
229 WindowBase* mainWindow = OpenEditorWindows();
230 mainWindow->setViewportLocation(TileCoordsXYZ{ 75, 75, 14 }.ToCoordsXYZ());
231 LoadPalette();
232
233 GameLoadScripts();
234 GameNotifyMapChanged();
235 }
236
237 /**
238 *

Callers 2

onDropdownMethod · 0.85
reopenTrackManagerMethod · 0.85

Calls 15

GetContextFunction · 0.85
StopAllFunction · 0.85
gameStateInitAllFunction · 0.85
SetAllLandOwnedFunction · 0.85
ObjectListLoadFunction · 0.85
ContextResetSubsystemsFunction · 0.85
OpenEditorWindowsFunction · 0.85
LoadPaletteFunction · 0.85
GameLoadScriptsFunction · 0.85
GameNotifyMapChangedFunction · 0.85
GetSceneManagerMethod · 0.80
setActiveSceneMethod · 0.80

Tested by

no test coverage detected