From 86988c668eeaa10f218e1d4938fc5b4e42314d68 Mon Sep 17 00:00:00 2001 From: NagyD Date: Sun, 18 Apr 2021 10:45:52 +0200 Subject: [PATCH] If the prince dies on level 14, don't return to the intro after the level was restarted. --- doc/ChangeLog.txt | 2 ++ src/config.h | 5 +++++ src/seg008.c | 3 +++ 3 files changed, 10 insertions(+) diff --git a/doc/ChangeLog.txt b/doc/ChangeLog.txt index a79c44a3..b511cad4 100644 --- a/doc/ChangeLog.txt +++ b/doc/ChangeLog.txt @@ -634,3 +634,5 @@ FIXED: Fixed the prince sliding through closed gates when you are using the cape Details: See FIX_CAPED_PRINCE_SLIDING_THROUGH_GATE in config.h . DONE: Added a compilation-time flag to disable all fixes for vanilla execution. Details: https://github.com/NagyD/SDLPoP/pull/239 +FIXED: If the prince dies on level 14, don't return to the intro after the level was restarted. + Details: See FIX_LEVEL_14_RESTARTING in config.h . diff --git a/src/config.h b/src/config.h index ba122185..698e7edf 100644 --- a/src/config.h +++ b/src/config.h @@ -250,6 +250,11 @@ The authors of this program may be contacted at https://forum.princed.org // Explanation: https://forum.princed.org/viewtopic.php?p=32701#p32701 #define FIX_CAPED_PRINCE_SLIDING_THROUGH_GATE +// If the prince dies on level 14, restarting the level will not stop the "Press Button to Continue" timer, and the game will return to the intro after a few seconds. +// How to reproduce: https://forum.princed.org/viewtopic.php?p=16926#p16926 +// Technical explanation: https://forum.princed.org/viewtopic.php?p=16408#p16408 (the second half of the post) +#define FIX_LEVEL_14_RESTARTING + #endif // ifndef DISABLE_ALL_FIXES // Debug features: diff --git a/src/seg008.c b/src/seg008.c index 54ac3859..5e971ecf 100644 --- a/src/seg008.c +++ b/src/seg008.c @@ -1821,6 +1821,9 @@ void __pascal far show_time() { // seg008:25A8 void __pascal far show_level() { +#ifdef FIX_LEVEL_14_RESTARTING + text_time_remaining = text_time_total = 0; +#endif byte disp_level; char sprintf_temp[32]; disp_level = current_level;