MCPcopy Create free account
hub / github.com/Svxy/The-Simpsons-Hit-and-Run / LoadScript

Method LoadScript

game/code/mission/missionscriptloader.cpp:632–646  ·  view source on GitHub ↗

============================================================================= MissionScriptLoader::LoadScript ============================================================================= Description: Comment Parameters: ( char* filename ) Return: void =============================================================================

Source from the content-addressed store, hash-verified

630//
631//=============================================================================
632void MissionScriptLoader::LoadScript( char* filename )
633{
634 mFirstObjective = true;
635
636 HeapMgr()->PushHeap (GMA_LEVEL_MISSION);
637
638 //
639 // NOTE: This has to stay sync because the scripts queue requests to the
640 // loading manager and these do not get processed if the loadmanager is
641 // already busy loading something
642 //
643 GetConsole()->ExecuteScriptSync( filename );
644
645 HeapMgr()->PopHeap (GMA_LEVEL_MISSION);
646}
647
648void MissionScriptLoader::LoadScriptAsync( char* filename, LoadingManager::ProcessRequestsCallback* callback )
649{

Callers 1

OnStartMethod · 0.45

Calls 5

HeapMgrFunction · 0.85
GetConsoleFunction · 0.85
PushHeapMethod · 0.80
ExecuteScriptSyncMethod · 0.80
PopHeapMethod · 0.80

Tested by

no test coverage detected