mirror of
https://git.do.srb2.org/STJr/UltimateZoneBuilder.git
synced 2025-02-17 01:22:18 +00:00
fixed crash on Undo after creating a sector with Make Sector tool and keeping the same highlighted
This commit is contained in:
parent
005e011435
commit
1982f07ab7
1 changed files with 12 additions and 0 deletions
|
@ -240,6 +240,17 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
|
||||
#region ================== Events
|
||||
|
||||
// When the mapset changes (undo/redo)
|
||||
public override void OnMapSetChangeBegin()
|
||||
{
|
||||
// No valid region
|
||||
nearestside = null;
|
||||
allsides = null;
|
||||
alllines = null;
|
||||
|
||||
base.OnMapSetChangeBegin();
|
||||
}
|
||||
|
||||
// Cancel mode
|
||||
public override void OnCancel()
|
||||
{
|
||||
|
@ -333,6 +344,7 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
// Quickly flash this sector to indicate it was created
|
||||
General.Map.IsChanged = true;
|
||||
General.Map.Map.Update();
|
||||
General.Interface.RedrawDisplay();
|
||||
flashpolygon = new FlatVertex[s.FlatVertices.Length];
|
||||
s.FlatVertices.CopyTo(flashpolygon, 0);
|
||||
flashintensity = 1.0f;
|
||||
|
|
Loading…
Reference in a new issue