- Fixed a crash when undoing 3D floor plugin actions while being in visual mode. Fixes #309.

This commit is contained in:
biwa 2019-11-01 17:23:41 +01:00 committed by spherallic
parent 4f4f074c3f
commit b31dec526c

View file

@ -247,7 +247,7 @@ namespace CodeImp.DoomBuilder.BuilderModes
}
//mxd. Create a floor
if(floorRequired)
if(floorRequired && ef.Ceiling.sector.IsDisposed == false)
{
VisualFloor vf = (i < extrafloors.Count) ? extrafloors[i] : new VisualFloor(mode, this);
if(vf.Setup(ef.Ceiling, ef))
@ -285,7 +285,7 @@ namespace CodeImp.DoomBuilder.BuilderModes
}
//mxd. Create a ceiling
if(ceilingRequired)
if(ceilingRequired && ef.Floor.sector.IsDisposed == false)
{
VisualCeiling vc = (i < extraceilings.Count) ? extraceilings[i] : new VisualCeiling(mode, this);
if(vc.Setup(ef.Floor, ef))