Browse Source

Enable FPS meter for releases

pull/393/head
Anders Jenbo 7 years ago
parent
commit
9146e3ea35
  1. 8
      Source/diablo.cpp
  2. 2
      Source/diablo.h
  3. 4
      Source/scrollrt.cpp
  4. 2
      Source/scrollrt.h

8
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
}
}
}
}

2
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];

4
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);

2
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();

Loading…
Cancel
Save