From 593540a3f9c73731847ce2a3fea5d8ca8db472ec Mon Sep 17 00:00:00 2001 From: Alug Date: Mon, 22 Jun 2026 20:56:53 +0200 Subject: [PATCH] add flag "COMPAT_VANILLA" undefine to enable features that are not vanilla compatible --- src/doomdef.h | 11 +++++++++++ src/p_spec.c | 2 ++ src/p_tick.c | 2 ++ 3 files changed, 15 insertions(+) diff --git a/src/doomdef.h b/src/doomdef.h index 69347f05a..69c072827 100644 --- a/src/doomdef.h +++ b/src/doomdef.h @@ -602,6 +602,9 @@ extern const char *compdate, *comptime, *comprevision, *compbranch; // None of these that are disabled in the normal build are guaranteed to work perfectly // Compile them at your own risk! +// undefine to enable fixes and features that are not vanilla compatible +#define COMPAT_VANILLA + //-- SATURN __ /// Detect if a client is on Saturn in the clientconfig. /// To seperately allow them to join or block joining from vanilla clients. @@ -666,6 +669,14 @@ extern const char *compdate, *comptime, *comprevision, *compbranch; #undef UPDATE_ALERT #endif +// overwrite some of those +// when not compiling in vanilla compat mode +#ifndef COMPAT_VANILLA + #define SATURNJOIN + #define SATURNPAK + #undef SEENAMES +#endif + #ifdef __cplusplus } // extern "C" #endif diff --git a/src/p_spec.c b/src/p_spec.c index 032fdbfbd..38b075feb 100644 --- a/src/p_spec.c +++ b/src/p_spec.c @@ -4609,11 +4609,13 @@ void P_UpdateSpecials(void) // POINT LIMIT P_CheckPointLimit(); +#ifdef COMPAT_VANILLA // Dynamic slopeness // we run this here only when not joined midrace // for vanilla compat reasons :chaosleep: if (!midgamejoin) P_RunDynamicSlopes(); +#endif P_UpdateAnimFlats(); } diff --git a/src/p_tick.c b/src/p_tick.c index 3692f9205..d0d25be69 100644 --- a/src/p_tick.c +++ b/src/p_tick.c @@ -646,7 +646,9 @@ void P_Ticker(boolean run) if (run) { // Dynamic slopeness +#ifdef COMPAT_VANILLA if (midgamejoin) // only run here if we joined midgame to fix some desynchs +#endif P_RunDynamicSlopes(); PS_START_TIMING(ps_thinkertime);