MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / InitEditGameSystems

Function InitEditGameSystems

editor/gameeditor.cpp:907–944  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

905}
906
907void InitEditGameSystems() {
908 tUIInitInfo uiinit;
909#if defined(RELEASE)
910 SetDebugBreakHandlers(NULL, NULL);
911#else
912 SetDebugBreakHandlers(D3DebugStopHandler, D3DebugResumeHandler);
913#endif
914
915 Descent->set_defer_handler(D3DeferHandler);
916
917 LoadAllFonts();
918 InitControls();
919 ddio_KeyFlush();
920 ddio_MouseMode(MOUSE_EXCLUSIVE_MODE);
921
922 // Sound initialization
923 InitD3Music(FindArg("-nomusic") ? false : true);
924 Sound_system.InitSoundLib(Descent, Sound_mixer, Sound_quality, false);
925
926 // UI init.
927 uiinit.window_font = SMALL_FONT;
928 uiinit.w = 640;
929 uiinit.h = 480;
930 ui_Init(Descent, &uiinit);
931 ui_UseCursor("StdCursor.ogf");
932
933 NewUIInit();
934
935 // Load up the pilot selected by default
936 if (cfexist(Default_pilot)) {
937 mprintf(0, "Loading up Default Pilot: %s\n", Default_pilot);
938 Current_pilot.set_filename(Default_pilot);
939 PltReadFile(&Current_pilot, true, true);
940 } else {
941 strcpy(Default_pilot, " ");
942 Current_pilot.set_filename("");
943 }
944}
945
946void InitGameEditSystems() {
947 // UnLoad the pilot and fill in the default

Callers 1

EditorToGameFunction · 0.85

Calls 15

SetDebugBreakHandlersFunction · 0.85
LoadAllFontsFunction · 0.85
InitControlsFunction · 0.85
ddio_KeyFlushFunction · 0.85
ddio_MouseModeFunction · 0.85
InitD3MusicFunction · 0.85
ui_InitFunction · 0.85
ui_UseCursorFunction · 0.85
NewUIInitFunction · 0.85
cfexistFunction · 0.85
PltReadFileFunction · 0.85
set_filenameMethod · 0.80

Tested by

no test coverage detected