summaryrefslogtreecommitdiffstats
path: root/src/main/java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/net/minecraft/server/ServerConfigurationManagerAbstract.java8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/main/java/net/minecraft/server/ServerConfigurationManagerAbstract.java b/src/main/java/net/minecraft/server/ServerConfigurationManagerAbstract.java
index 102d1626..3332cdf1 100644
--- a/src/main/java/net/minecraft/server/ServerConfigurationManagerAbstract.java
+++ b/src/main/java/net/minecraft/server/ServerConfigurationManagerAbstract.java
@@ -160,8 +160,12 @@ public abstract class ServerConfigurationManagerAbstract {
this.cserver.onPlayerJoin(playerJoinEvent.getPlayer());
// CraftBukkit end
- worldserver.addEntity(entityplayer);
- this.a(entityplayer, (WorldServer) null);
+ // CraftBukkit start - only add if the player wasn't moved in the event
+ if (entityplayer.world == worldserver && !worldserver.players.contains(entityplayer)) {
+ worldserver.addEntity(entityplayer);
+ this.a(entityplayer, (WorldServer) null);
+ }
+ // CraftBukkit end
// CraftBukkit start - sendAll above replaced with this loop
Packet201PlayerInfo packet = new Packet201PlayerInfo(entityplayer.listName, true, 1000);