From 9146e3ea3527cc6249fa695dfcb86543aac989e2 Mon Sep 17 00:00:00 2001 From: Anders Jenbo Date: Sun, 27 Oct 2019 19:06:38 +0100 Subject: [PATCH] Enable FPS meter for releases --- Source/diablo.cpp | 8 +++++--- Source/diablo.h | 2 +- Source/scrollrt.cpp | 4 +--- Source/scrollrt.h | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Source/diablo.cpp b/Source/diablo.cpp index 39fddf4cf..6d46ca0c2 100644 --- a/Source/diablo.cpp +++ b/Source/diablo.cpp @@ -51,11 +51,11 @@ int dbgplr; int dbgqst; int dbgmon; int arrowdebug; +#endif int frameflag; int frameend; int framerate; int framestart; -#endif BOOL FriendlyMode = TRUE; char *spszMsgTbl[4] = { "I need help! Come Here!", @@ -292,8 +292,8 @@ void diablo_parse_flags(char *args) { c = tolower(*args); args++; -#ifdef _DEBUG switch (c) { +#ifdef _DEBUG case '^': debug_mode_key_inverted_v = 1; break; @@ -309,9 +309,11 @@ void diablo_parse_flags(char *args) showintrodebug = 0; debug_mode_key_d = 1; break; +#endif case 'f': EnableFrameCount(); break; +#ifdef _DEBUG case 'i': debug_mode_key_i = 1; break; @@ -413,8 +415,8 @@ void diablo_parse_flags(char *args) case 'x': fullscreen = FALSE; break; - } #endif + } } } } diff --git a/Source/diablo.h b/Source/diablo.h index 2407c53b1..7848145b6 100644 --- a/Source/diablo.h +++ b/Source/diablo.h @@ -171,11 +171,11 @@ extern int dbgplr; extern int dbgqst; extern int dbgmon; extern int arrowdebug; +#endif extern int frameflag; extern int frameend; extern int framerate; extern int framestart; -#endif extern BOOL FriendlyMode; extern char *spszMsgTbl[4]; extern char *spszMsgHotKeyTbl[4]; diff --git a/Source/scrollrt.cpp b/Source/scrollrt.cpp index fa3247da8..45cbde6c1 100644 --- a/Source/scrollrt.cpp +++ b/Source/scrollrt.cpp @@ -1022,6 +1022,7 @@ void ScrollView() if (scroll) ScrollInfo._sdir = SDIR_NONE; } +#endif /** * @brief Initialize the FPS meter @@ -1056,7 +1057,6 @@ static void DrawFPS() PrintGameStr(8, 65, String, COL_RED); } } -#endif /** * @brief Update part of the screen from the backbuffer @@ -1214,9 +1214,7 @@ void DrawAndBlit() } scrollrt_draw_cursor_item(); -#ifdef _DEBUG DrawFPS(); -#endif unlock_buf(0); diff --git a/Source/scrollrt.h b/Source/scrollrt.h index b9813aa22..600af6555 100644 --- a/Source/scrollrt.h +++ b/Source/scrollrt.h @@ -18,8 +18,8 @@ void DrawView(int StartX, int StartY); void ClearScreenBuffer(); #ifdef _DEBUG void ScrollView(); -void EnableFrameCount(); #endif +void EnableFrameCount(); void scrollrt_draw_game_screen(BOOL draw_cursor); void DrawAndBlit();