From 1b895d7478d01e3ed3f0986635e88a26328dd6b3 Mon Sep 17 00:00:00 2001 From: Daniel Gibson Date: Mon, 6 Jun 2016 04:28:42 +0200 Subject: [PATCH] Support both ModExt.txt and ModEXT.txt --- Sources/Engine/Base/Stream.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Sources/Engine/Base/Stream.cpp b/Sources/Engine/Base/Stream.cpp index 6c08446..79cc5d6 100755 --- a/Sources/Engine/Base/Stream.cpp +++ b/Sources/Engine/Base/Stream.cpp @@ -169,7 +169,13 @@ void InitStreams(void) } // find eventual extension for the mod's dlls _strModExt = ""; - LoadStringVar(CTString("ModEXT.txt"), _strModExt); + // DG: apparently both ModEXT.txt and ModExt.txt exist in the wild. + CTFileName tmp; + if(ExpandFilePath(EFP_READ, CTString("ModEXT.txt"), tmp) != EFP_NONE) { + LoadStringVar(CTString("ModEXT.txt"), _strModExt); + } else { + LoadStringVar(CTString("ModExt.txt"), _strModExt); + } CPrintF(TRANSV("Loading group files...\n"));