Added a check to prevent a crash with overlapping resource lump ranges

This commit is contained in:
codeimp 2009-05-14 21:36:25 +00:00
parent 08478f5e44
commit 0c5b437f64

View file

@ -304,10 +304,13 @@ namespace CodeImp.DoomBuilder.Data
// Process textures // Process textures
foreach(KeyValuePair<long, ImageData> t in texturesonly) foreach(KeyValuePair<long, ImageData> t in texturesonly)
{
if(!textures.ContainsKey(t.Key))
{ {
textures.Add(t.Key, t.Value); textures.Add(t.Key, t.Value);
texturenames.Add(t.Value.Name); texturenames.Add(t.Value.Name);
} }
}
// Process flats // Process flats
foreach(KeyValuePair<long, ImageData> f in flatsonly) foreach(KeyValuePair<long, ImageData> f in flatsonly)