Fixed, vertex/linedef/sector dragging: in some cases middle textures were removed from dragged double-sided lines.

Fixed, ACC compiler: fixed a crash when trying to compile SCRIPTS lump of a new map, which wasn't ever saved.
This commit is contained in:
MaxED 2016-05-30 00:18:22 +00:00 committed by spherallic
parent e69163a646
commit 14e372cb91

View file

@ -2409,6 +2409,13 @@ namespace CodeImp.DoomBuilder.Map
line.FlipVertices();
line.FlipSidedefs();
}
// Adjust textures
if(line.Front != null) line.Front.RemoveUnneededTextures(line.Back != null, false, true);
if(line.Back != null) line.Back.RemoveUnneededTextures(line.Front != null, false, true);
// Correct the sided flags
line.ApplySidedFlags();
}
foreach(KeyValuePair<Linedef, Sector> group in linebacksectorref)
@ -2428,16 +2435,13 @@ namespace CodeImp.DoomBuilder.Map
line.FlipVertices();
line.FlipSidedefs();
}
}
// Adjust textures
foreach(Linedef l in changedlines)
{
if(l.Front != null) l.Front.RemoveUnneededTextures(l.Back != null);
if(l.Back != null) l.Back.RemoveUnneededTextures(l.Front != null);
// Adjust textures
if(line.Front != null) line.Front.RemoveUnneededTextures(line.Back != null, false, true);
if(line.Back != null) line.Back.RemoveUnneededTextures(line.Front != null, false, true);
// Correct the sided flags
l.ApplySidedFlags();
line.ApplySidedFlags();
}
}