Support both ModExt.txt and ModEXT.txt

This commit is contained in:
Daniel Gibson 2016-06-06 04:28:42 +02:00
parent 882c7773b5
commit 1b895d7478

View File

@ -169,7 +169,13 @@ void InitStreams(void)
} }
// find eventual extension for the mod's dlls // find eventual extension for the mod's dlls
_strModExt = ""; _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); LoadStringVar(CTString("ModEXT.txt"), _strModExt);
} else {
LoadStringVar(CTString("ModExt.txt"), _strModExt);
}
CPrintF(TRANSV("Loading group files...\n")); CPrintF(TRANSV("Loading group files...\n"));