From f26fbc3bf306aa171ec7fa629ac7d7031528bd62 Mon Sep 17 00:00:00 2001 From: EvilSeph Date: Thu, 8 Mar 2012 19:24:43 -0500 Subject: [PATCH] Fixed EnderPearls not being limited to the world they were used in. Fixes BUKKIT-658 --- src/main/java/net/minecraft/server/EntityEnderPearl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/net/minecraft/server/EntityEnderPearl.java b/src/main/java/net/minecraft/server/EntityEnderPearl.java index 57b4e2f3c1..484f326ed7 100644 --- a/src/main/java/net/minecraft/server/EntityEnderPearl.java +++ b/src/main/java/net/minecraft/server/EntityEnderPearl.java @@ -36,7 +36,7 @@ public class EntityEnderPearl extends EntityProjectile { if (this.shooter != null) { if (this.shooter instanceof EntityPlayer) { CraftPlayer player = (CraftPlayer) this.shooter.bukkitEntity; - teleport = player.isOnline(); + teleport = player.isOnline() && player.getWorld() == getBukkitEntity().getWorld(); if (teleport) { teleEvent = new PlayerTeleportEvent(player, player.getLocation(), getBukkitEntity().getLocation(), PlayerTeleportEvent.TeleportCause.ENDER_PEARL);