From 32bb810ce777d4ee355d98db38c12f4a9742b0f3 Mon Sep 17 00:00:00 2001 From: TomyLobo Date: Thu, 15 Dec 2011 15:44:04 +0100 Subject: [PATCH] Changed all instances of new BukkitWorld to BukkitUtil.getLocalWorld, except for the one in that function. --- src/main/java/com/sk89q/worldedit/bukkit/BukkitPlayer.java | 4 ++-- src/main/java/com/sk89q/worldedit/bukkit/WorldEditPlugin.java | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/sk89q/worldedit/bukkit/BukkitPlayer.java b/src/main/java/com/sk89q/worldedit/bukkit/BukkitPlayer.java index 0d63a1839..71a613546 100644 --- a/src/main/java/com/sk89q/worldedit/bukkit/BukkitPlayer.java +++ b/src/main/java/com/sk89q/worldedit/bukkit/BukkitPlayer.java @@ -51,7 +51,7 @@ public class BukkitPlayer extends LocalPlayer { @Override public WorldVector getPosition() { Location loc = player.getLocation(); - return new WorldVector(new BukkitWorld(loc.getWorld()), + return new WorldVector(BukkitUtil.getLocalWorld(loc.getWorld()), loc.getX(), loc.getY(), loc.getZ()); } @@ -123,7 +123,7 @@ public class BukkitPlayer extends LocalPlayer { @Override public LocalWorld getWorld() { - return new BukkitWorld(player.getWorld()); + return BukkitUtil.getLocalWorld(player.getWorld()); } @Override diff --git a/src/main/java/com/sk89q/worldedit/bukkit/WorldEditPlugin.java b/src/main/java/com/sk89q/worldedit/bukkit/WorldEditPlugin.java index b6dc0142e..b18611113 100644 --- a/src/main/java/com/sk89q/worldedit/bukkit/WorldEditPlugin.java +++ b/src/main/java/com/sk89q/worldedit/bukkit/WorldEditPlugin.java @@ -415,7 +415,7 @@ public class WorldEditPlugin extends JavaPlugin { LocalSession session = controller.getSession(wrapPlayer(player)); RegionSelector sel = selection.getRegionSelector(); - session.setRegionSelector(new BukkitWorld(player.getWorld()), sel); + session.setRegionSelector(BukkitUtil.getLocalWorld(player.getWorld()), sel); session.dispatchCUISelection(wrapPlayer(player)); } }