From ecdcabfe99dd76aef98daba47aee6c6a789ac0ac Mon Sep 17 00:00:00 2001 From: Alibek Omarov Date: Thu, 21 Dec 2023 05:22:12 +0300 Subject: [PATCH] server: warn mod developer about reaching the GoldSrc sentences limits --- dlls/sound.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/dlls/sound.cpp b/dlls/sound.cpp index 3dbd097a..992e0ebd 100644 --- a/dlls/sound.cpp +++ b/dlls/sound.cpp @@ -1341,6 +1341,15 @@ void SENTENCEG_Init() g_engfuncs.pfnFreeFile( pMemFile ); + if( gcallsentences >= 2048 ) + { + ALERT( at_warning, "NOTE: this mod might not work properly under GoldSource (post-anniversary update) engine: more than 2048 sentences\n" ); + } + else if( gcallsentences >= 1536 ) + { + ALERT( at_warning, "NOTE: this mod might not work properly under GoldSource (pre-anniversary update) engine: more than 1536 sentences\n" ); + } + fSentencesInit = TRUE; // init lru lists