From 24516cbf8440b7534602292073a2093997be7910 Mon Sep 17 00:00:00 2001 From: Latapostrophe Date: Sat, 16 Feb 2019 13:38:50 +0100 Subject: [PATCH] Move ping display in i_video for consistency with showfps display --- src/djgppdos/i_video.c | 5 +++++ src/hu_stuff.c | 3 ++- src/sdl/i_video.c | 7 ++++++- src/sdl12/i_video.c | 5 +++++ src/win32/win_vid.c | 5 +++++ src/win32ce/win_vid.c | 5 +++++ 6 files changed, 28 insertions(+), 2 deletions(-) diff --git a/src/djgppdos/i_video.c b/src/djgppdos/i_video.c index 612c7221..69addfb0 100644 --- a/src/djgppdos/i_video.c +++ b/src/djgppdos/i_video.c @@ -41,6 +41,7 @@ #include "../m_argv.h" #include "vid_vesa.h" #include "../i_video.h" +#include "../hu_stuff.h" //dosstuff -newly added @@ -93,6 +94,10 @@ void I_FinishUpdate (void) // draw FPS if enabled if (cv_ticrate.value) SCR_DisplayTicRate(); + + // this is now handled here so that wipes and other things don't overlap it for the sake of consistency. + // no additional checks are needed here, this function does them all so no need to worry. :) + HU_drawLocalPing(); //blast it to the screen // this code sucks diff --git a/src/hu_stuff.c b/src/hu_stuff.c index 3bc28c17..404b4509 100644 --- a/src/hu_stuff.c +++ b/src/hu_stuff.c @@ -2329,7 +2329,8 @@ void HU_Drawer(void) } // draw the ping if the user wishes to - HU_drawLocalPing(); + // THIS IS NOW HANDLED IN I_VIDEO + //HU_drawLocalPing(); } //====================================================================== diff --git a/src/sdl/i_video.c b/src/sdl/i_video.c index 2a77604d..9e5e4b60 100644 --- a/src/sdl/i_video.c +++ b/src/sdl/i_video.c @@ -64,9 +64,10 @@ #include "../m_menu.h" #include "../d_main.h" #include "../s_sound.h" -#include "../i_sound.h" // midi pause/unpause +#include "../i_sound.h" // midi pause/unpause #include "../i_joy.h" #include "../st_stuff.h" +#include "../hu_stuff.h" // ping drawer #include "../g_game.h" #include "../i_video.h" #include "../console.h" @@ -1360,6 +1361,10 @@ void I_FinishUpdate(void) if (cv_ticrate.value) SCR_DisplayTicRate(); + + // this is now handled here so that wipes and other things don't overlap it for the sake of consistency. + // no additional checks are needed here, this function does them all so no need to worry. :) + HU_drawLocalPing(); if (rendermode == render_soft && screens[0]) { diff --git a/src/sdl12/i_video.c b/src/sdl12/i_video.c index 69cf5ca9..08e6bd94 100644 --- a/src/sdl12/i_video.c +++ b/src/sdl12/i_video.c @@ -99,6 +99,7 @@ #include "../i_sound.h" // midi pause/unpause #include "../i_joy.h" #include "../st_stuff.h" +#include "../hu_stuff.h" #include "../g_game.h" #include "../i_video.h" #include "../console.h" @@ -1342,6 +1343,10 @@ void I_FinishUpdate(void) if (cv_ticrate.value) SCR_DisplayTicRate(); + + // this is now handled here so that wipes and other things don't overlap it for the sake of consistency. + // no additional checks are needed here, this function does them all so no need to worry. :) + HU_drawLocalPing(); if (render_soft == rendermode && screens[0]) { diff --git a/src/win32/win_vid.c b/src/win32/win_vid.c index 9f3d13f8..cba0c209 100644 --- a/src/win32/win_vid.c +++ b/src/win32/win_vid.c @@ -28,6 +28,7 @@ #include "../m_argv.h" #include "../v_video.h" #include "../st_stuff.h" +#include "../hu_stuff.h" #include "../i_video.h" #include "../z_zone.h" #include "fabdxlib.h" @@ -365,6 +366,10 @@ void I_FinishUpdate(void) // display a graph of ticrate if (cv_ticrate.value) SCR_DisplayTicRate(); + + // this is now handled here so that wipes and other things don't overlap it for the sake of consistency. + // no additional checks are needed here, this function does them all so no need to worry. :) + HU_drawLocalPing(); // if (bDIBMode) diff --git a/src/win32ce/win_vid.c b/src/win32ce/win_vid.c index 5e8e7e1f..c6610fa0 100644 --- a/src/win32ce/win_vid.c +++ b/src/win32ce/win_vid.c @@ -26,6 +26,7 @@ #include "../m_argv.h" #include "../v_video.h" #include "../st_stuff.h" +#include "../hu_stuff.h" #include "../i_video.h" #include "../z_zone.h" #include "fabdxlib.h" @@ -198,6 +199,10 @@ void I_FinishUpdate(void) if (cv_ticrate.value) SCR_DisplayTicRate(); + // this is now handled here so that wipes and other things don't overlap it for the sake of consistency. + // no additional checks are needed here, this function does them all so no need to worry. :) + HU_drawLocalPing(); + // if (bDIBMode) {