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

Function LoadCockpitInfo

Descent3/cockpit.cpp:366–385  ·  view source on GitHub ↗

loads pertinent information about cockpit.

Source from the content-addressed store, hash-verified

364}
365// loads pertinent information about cockpit.
366void LoadCockpitInfo(const char *ckt_file, tCockpitCfgInfo *cfginfo) {
367 // clear out return values.
368 if (cfginfo) {
369 memset(cfginfo, 0, sizeof(tCockpitCfgInfo));
370 ASSERT(NUM_SHIELD_GAUGE_FRAMES == 5);
371 strcpy(cfginfo->shieldrings[0], TBL_GAMEFILE("shieldring01.ogf"));
372 strcpy(cfginfo->shieldrings[1], TBL_GAMEFILE("shieldring02.ogf"));
373 strcpy(cfginfo->shieldrings[2], TBL_GAMEFILE("shieldring03.ogf"));
374 strcpy(cfginfo->shieldrings[3], TBL_GAMEFILE("shieldring04.ogf"));
375 strcpy(cfginfo->shieldrings[4], TBL_GAMEFILE("shieldring05.ogf"));
376 strcpy(cfginfo->shipimg, TBL_GAMEFILE("hudship.ogf"));
377 strcpy(cfginfo->burnimg, TBL_GAMEFILE("hudburn.ogf"));
378 strcpy(cfginfo->energyimg, TBL_GAMEFILE("hudenergy.ogf"));
379 strcpy(cfginfo->invpulseimg, TBL_GAMEFILE("shieldinv.ogf"));
380 }
381 if (ckt_file[0] == 0)
382 return;
383
384 LoadHUDConfig(ckt_file, CockpitFileParse, cfginfo);
385}
386// forces opening of cockpit.
387void OpenCockpit() {
388 // this should allow for opening cockpit while in closing mode.

Callers 3

InitCockpitFunction · 0.85
OpenCockpitFunction · 0.85
QuickOpenCockpitFunction · 0.85

Calls 1

LoadHUDConfigFunction · 0.85

Tested by

no test coverage detected