From 3469ab12ba84f63c60a6ccf90a6cdb7fff0b9586 Mon Sep 17 00:00:00 2001 From: Sally Coolatta Date: Sun, 25 Oct 2020 10:48:32 -0400 Subject: [PATCH] Add extra warning for CON_STARTUP_LOADSTEPS being incorrect --- src/console.c | 2 +- src/d_main.c | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/console.c b/src/console.c index fd4afe946..4341dd003 100644 --- a/src/console.c +++ b/src/console.c @@ -1920,7 +1920,7 @@ void CON_DrawLoadBar(void) if (con_startup_loadprogress > CON_STARTUP_LOADSTEPS) { Unlock_state(); - I_Error("CON_STARTUP_LOADSTEPS has not been updated!\n"); + I_Error("CON_STARTUP_LOADSTEPS is too low! (is %d, got %d)\n", CON_STARTUP_LOADSTEPS, con_startup_loadprogress); return; } diff --git a/src/d_main.c b/src/d_main.c index b8a30aff3..434d8c360 100644 --- a/src/d_main.c +++ b/src/d_main.c @@ -1843,6 +1843,12 @@ void D_SRB2Main(void) DRPC_Init(); } #endif + + if (con_startup_loadprogress < CON_STARTUP_LOADSTEPS) + { + I_Error("CON_STARTUP_LOADSTEPS is too high! (is %d, got %d)\n", CON_STARTUP_LOADSTEPS, con_startup_loadprogress); + return; + } } const char *D_Home(void)