diff --git a/Source/Plugins/3DFloorMode/ThreeDFloor.cs b/Source/Plugins/3DFloorMode/ThreeDFloor.cs index 9380beba..c102c5ed 100644 --- a/Source/Plugins/3DFloorMode/ThreeDFloor.cs +++ b/Source/Plugins/3DFloorMode/ThreeDFloor.cs @@ -225,10 +225,10 @@ namespace CodeImp.DoomBuilder.ThreeDFloorMode sd.SetTextureMid(bordertexture); if (sd.Line.Action == 160) - { - sd.Line.Args[1] = type; - sd.Line.Args[2] = flags; - sd.Line.Args[3] = alpha; + { + // We need to update the linedef's args, but we can't do it directly because otherwise their state will not be saved for the undo snapshot, + // so we're using the linedef's update method + sd.Line.Update(sd.Line.GetFlags(), sd.Line.Activate, sd.Line.Tags, sd.Line.Action, new int[] { sd.Line.Args[0], type, flags, alpha, sd.Line.Args[4] }); } } }