Made map detection logic a bit more strict. If BEHAVIOUR lump is present, a map can no longer be detected as a map in Doom map format.

This commit is contained in:
MaxED 2013-08-09 08:39:45 +00:00
parent 457cfc8221
commit a347afaf66
2 changed files with 12 additions and 1 deletions

View file

@ -280,6 +280,11 @@ doommaplumpnames
nodebuild = true;
allowempty = false;
}
BEHAVIOR //mxd
{
forbidden = true;
}
}

View file

@ -271,8 +271,14 @@ namespace CodeImp.DoomBuilder.Windows
while(((scanindex + checkoffset) < wadfile.Lumps.Count) &&
maplumpnames.Contains(wadfile.Lumps[scanindex + checkoffset].Name))
{
// Count the lump when it is marked as required
lumpname = wadfile.Lumps[scanindex + checkoffset].Name;
//mxd. Lump cannot present in current map format, fail this check
if(cfg.ReadSetting("maplumpnames." + lumpname + ".forbidden", false)) {
lumpsfound = -1;
break;
}
// Count the lump when it is marked as required
if(cfg.ReadSetting("maplumpnames." + lumpname + ".required", false)) lumpsfound++;
// Check the next lump