Skip to content

Commit 107061f

Browse files
committed
Properly declare ShowStaticScreen()
1 parent 58351d8 commit 107061f

File tree

4 files changed

+6
-15
lines changed

4 files changed

+6
-15
lines changed

Descent3/credits.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -299,8 +299,6 @@ static bool Credits_LoadCredits(const char *filename) {
299299
return true;
300300
}
301301

302-
extern void ShowStaticScreen(char *bitmap_filename, bool timed = false, float delay_time = 0.0f);
303-
304302
#define CREDIT_PIXELS_PER_SECOND 22
305303

306304
void Credits_Display() {

Descent3/descent.cpp

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -381,7 +381,6 @@
381381
* $NoKeywords: $
382382
*/
383383

384-
#include <algorithm>
385384
#include <cstdlib>
386385
#include <filesystem>
387386
#include <vector>
@@ -408,6 +407,7 @@
408407
#include "args.h"
409408
#include "multi_dll_mgr.h"
410409
#include "localization.h"
410+
#include "uisys.h"
411411

412412
// ---------------------------------------------------------------------------
413413
// Variables
@@ -434,10 +434,6 @@ std::filesystem::path Descent3_temp_directory; // temp directory to put temp fil
434434
// ---------------------------------------------------------------------------
435435
// #define BETA
436436

437-
#if (defined(OEM) || defined(DEMO))
438-
void ShowStaticScreen(char *bitmap_filename, bool timed = false, float delay_time = 0.0f);
439-
#endif
440-
441437
char Proxy_server[200] = "";
442438
int16_t Proxy_port = 80;
443439

@@ -597,10 +593,8 @@ void MainLoop() {
597593
SetScreenMode(SM_NULL);
598594
}
599595

600-
#if (defined(OEM) || defined(DEMO) || defined(RELEASE))
601596
// Shows a fullscreen static bitmap
602-
void ShowStaticScreen(char *bitmap_filename, bool timed, float delay_time) {
603-
extern void ui_SetScreenMode(int w, int h);
597+
void ShowStaticScreen(const char *bitmap_filename, bool timed, float delay_time) {
604598
chunked_bitmap splash_bm;
605599

606600
// do splash screen on release
@@ -615,7 +609,7 @@ void ShowStaticScreen(char *bitmap_filename, bool timed, float delay_time) {
615609

616610
bm_FreeBitmap(bm_handle);
617611
float start_time = timer_GetTime();
618-
while (1) {
612+
while (true) {
619613
StartFrame();
620614

621615
rend_DrawChunkedBitmap(&splash_bm, 0, 0, 255);
@@ -646,7 +640,6 @@ void ShowStaticScreen(char *bitmap_filename, bool timed, float delay_time) {
646640

647641
ui_SetScreenMode(Max_window_w, Max_window_h);
648642
}
649-
#endif
650643

651644
// ---------------------------------------------------------------------------
652645
// Accessor functions

Descent3/descent.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -212,6 +212,9 @@ void D3DeferHandler(bool is_active);
212212
void SetFunctionMode(function_mode mode);
213213
function_mode GetFunctionMode();
214214

215+
// Shows a fullscreen static bitmap
216+
void ShowStaticScreen(const char *bitmap_filename, bool timed = false, float delay_time = 0.0f);
217+
215218
#ifndef RELEASE
216219
// this is called when you hit a debug break!
217220
void D3DebugStopHandler();

Descent3/init.cpp

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1722,9 +1722,6 @@ void InitMessage(const char *c, float progress) {
17221722
}
17231723

17241724
//////////////////////////////////////////////////////////////////////////////
1725-
#if (defined(OEM) || defined(DEMO) || defined(RELEASE))
1726-
void ShowStaticScreen(char *bitmap_filename, bool timed = false, float delay_time = 0.0f);
1727-
#endif
17281725

17291726
void IntroScreen() {
17301727
// #if (defined(OEM) || defined(DEMO) )

0 commit comments

Comments
 (0)