From c7b8b5d2da84cbde85a419e58a4991869fa3e036 Mon Sep 17 00:00:00 2001 From: yoyosource Date: Mon, 8 Apr 2024 08:28:52 +0200 Subject: [PATCH] Hotfix RegionCommand --- .../de/steamwar/bausystem/features/region/RegionCommand.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/BauSystem_Main/src/de/steamwar/bausystem/features/region/RegionCommand.java b/BauSystem_Main/src/de/steamwar/bausystem/features/region/RegionCommand.java index eb30b112..6d8d6f4d 100644 --- a/BauSystem_Main/src/de/steamwar/bausystem/features/region/RegionCommand.java +++ b/BauSystem_Main/src/de/steamwar/bausystem/features/region/RegionCommand.java @@ -22,7 +22,6 @@ package de.steamwar.bausystem.features.region; import com.sk89q.worldedit.EditSession; import com.sk89q.worldedit.WorldEdit; import com.sk89q.worldedit.bukkit.BukkitAdapter; -import com.sk89q.worldedit.bukkit.BukkitWorld; import com.sk89q.worldedit.extent.clipboard.Clipboard; import com.sk89q.worldedit.function.operation.Operations; import com.sk89q.worldedit.math.BlockVector3; @@ -287,7 +286,7 @@ public class RegionCommand extends SWCommand { break; } - try (EditSession e = WorldEdit.getInstance().getEditSessionFactory().getEditSession(new BukkitWorld(Bukkit.getWorlds().get(0)), -1)) { + try (EditSession e = WorldEditUtils.getEditSession(p)) { Operations.completeBlindly(clipboardHolder.createPaste(e).ignoreAirBlocks(ignoreAir).to(toBlockVector3(region.getCopyPoint())).build()); WorldEditUtils.addToPlayer(p, e);