From 545bd4025b3f9a558ed1047d5dbb60116e37e2f7 Mon Sep 17 00:00:00 2001 From: UnknownShadow200 Date: Sat, 27 Aug 2016 10:10:38 +1000 Subject: [PATCH] Fix /paste with /transform scale. (Thanks 6 or so hours of trying to find that) --- Drawing/DrawOps/PasteDrawOp.cs | 7 +------ Drawing/TransformFactories/SimpleTransforms.cs | 1 + 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/Drawing/DrawOps/PasteDrawOp.cs b/Drawing/DrawOps/PasteDrawOp.cs index ed92a3829..083b8027e 100644 --- a/Drawing/DrawOps/PasteDrawOp.cs +++ b/Drawing/DrawOps/PasteDrawOp.cs @@ -40,12 +40,7 @@ namespace MCGalaxy.Drawing.Ops { state.GetCoords(i, out locX, out locY, out locZ); ushort x = (ushort)(locX + x1), y = (ushort)(locY + y1), z = (ushort)(locZ + z1); - byte block = lvl.GetTile(x, y, z), extBlock = 0; - if (block == Block.custom_block) extBlock = lvl.GetExtTile(x, y, z); - bool diff = b != block || (b == Block.custom_block && extB != extBlock); - - bool place = lvl.InBound(x, y, z) && diff; - if ((b != Block.air || pasteAir) && place) + if ((b != Block.air || pasteAir) && lvl.InBound(x, y, z)) yield return Place(x, y, z, b, extB); } } diff --git a/Drawing/TransformFactories/SimpleTransforms.cs b/Drawing/TransformFactories/SimpleTransforms.cs index 374b554f7..f92078492 100644 --- a/Drawing/TransformFactories/SimpleTransforms.cs +++ b/Drawing/TransformFactories/SimpleTransforms.cs @@ -83,6 +83,7 @@ namespace MCGalaxy.Drawing.Transforms { success = int.TryParse(top, out mul) && int.TryParse(bottom, out div); } + if (mul > 32 || mul < -32) { Player.Message(p, "Scale must be between -32 and 32."); return false; } if (!success) { Player.MessageLines(p, HelpString); } return success; }