- changed: If the IWAD contains a MENUDEF lump the one in zdoom.pk3 should not print texture warnings.

The reason is that in such a case it is very likely that the IWAD defines its own menu and will most likely not provide all assets for the base definitions. See 'Adventures of Square' for an example.
This commit is contained in:
Christoph Oelckers 2016-02-29 10:45:14 +01:00
parent 7242a0ef94
commit 6c37ab2310
1 changed files with 6 additions and 1 deletions

View File

@ -60,6 +60,7 @@ static FListMenuDescriptor DefaultListMenuSettings; // contains common settings
static FOptionMenuDescriptor DefaultOptionMenuSettings; // contains common settings for all Option menus
FOptionMenuSettings OptionSettings;
FOptionMap OptionValues;
bool mustPrintErrors;
void I_BuildALDeviceList(FOptionValues *opt);
@ -99,7 +100,7 @@ static FTextureID GetMenuTexture(const char* const name)
{
const FTextureID texture = TexMan.CheckForTexture(name, FTexture::TEX_MiscPatch);
if (!texture.Exists())
if (!texture.Exists() && mustPrintErrors)
{
Printf("Missing menu texture: \"%s\"\n", name);
}
@ -956,10 +957,14 @@ void M_ParseMenuDefs()
atterm( DeinitMenus);
DeinitMenus();
int IWADMenu = Wads.CheckNumForName("MENUDEF", ns_global, FWadCollection::IWAD_FILENUM);
while ((lump = Wads.FindLump ("MENUDEF", &lastlump)) != -1)
{
FScanner sc(lump);
mustPrintErrors = lump >= IWADMenu;
sc.SetCMode(true);
while (sc.GetString())
{