This commit is contained in:
Jesse Boyd 2018-04-18 17:51:40 +10:00
parent bd346bc4c5
commit 124cc02350
No known key found for this signature in database
GPG Key ID: 59F1DE6293AF6E1F

View File

@ -525,8 +525,10 @@ public class ClipboardCommands extends MethodCommands {
Region region = clipboard.getRegion().clone();
if (selectPasted) {
Vector max = to.add(region.getMaximumPoint().subtract(region.getMinimumPoint()));
RegionSelector selector = new CuboidRegionSelector(player.getWorld(), to, max);
Vector clipboardOffset = clipboard.getRegion().getMinimumPoint().subtract(clipboard.getOrigin());
Vector realTo = to.add(new Vector(holder.getTransform().apply(clipboardOffset)));
Vector max = realTo.add(new Vector(holder.getTransform().apply(region.getMaximumPoint().subtract(region.getMinimumPoint()))));
RegionSelector selector = new CuboidRegionSelector(player.getWorld(), realTo, max);
session.setRegionSelector(player.getWorld(), selector);
selector.learnChanges();
selector.explainRegionAdjust(player, session);