diff --git a/src/com/sekwah/advancedportals/coreconnector/container/PlayerContainer.java b/src/com/sekwah/advancedportals/coreconnector/container/PlayerContainer.java index f221e74d..37f086ec 100644 --- a/src/com/sekwah/advancedportals/coreconnector/container/PlayerContainer.java +++ b/src/com/sekwah/advancedportals/coreconnector/container/PlayerContainer.java @@ -32,7 +32,7 @@ public class PlayerContainer { public PlayerLocation getLoc() { Location loc = this.player.getLocation(); - return new PlayerLocation(loc.getX(), loc.getY(), loc.getZ()); + return new PlayerLocation(loc.getWorld().getName(), loc.getX(), loc.getY(), loc.getZ()); } public double getEyeHeight() { diff --git a/src/com/sekwah/advancedportals/spigot/Listeners.java b/src/com/sekwah/advancedportals/spigot/Listeners.java index 57bb9a10..f7d1ac63 100644 --- a/src/com/sekwah/advancedportals/spigot/Listeners.java +++ b/src/com/sekwah/advancedportals/spigot/Listeners.java @@ -31,7 +31,7 @@ public class Listeners implements Listener { Location blockloc = event.getClickedBlock().getLocation(); this.coreListeners.playerInteractWithBlock(new PlayerContainer(event.getPlayer()), event.getMaterial().toString(), event.getItem().getItemMeta().getDisplayName(), - new PortalLocation(blockloc.getBlockX(), blockloc.getBlockY(), blockloc.getBlockZ()), + new PortalLocation(blockloc.getWorld().getName(), blockloc.getBlockX(), blockloc.getBlockY(), blockloc.getBlockZ()), event.getAction() == Action.LEFT_CLICK_BLOCK); } }