public void c(OEntityPlayerMP var1) { this.sendPacketToAll((new OPacket201PlayerInfo(var1.v, true, 1000))); this.b.add(var1); OWorldServer var2 = (OWorldServer) ((CanaryDimension) var1.getDimension().getWorld().getDimension(Type.fromId(var1.w))) .getHandle(); var1.bi = var2; // re-set world var2.G.c((int) var1.bm >> 4, (int) var1.bo >> 4); while (var2.a(var1, var1.bw).size() != 0) { var1.c(var1.bm, var1.bn + 1.0D, var1.bo); } var2.b(var1); // CanaryMod var1.getDimension().getPlayerManager().addPlayer(var1.getPlayer()); this.u(); for (int var3 = 0; var3 < this.b.size(); ++var3) { OEntityPlayerMP var4 = (OEntityPlayerMP) this.b.get(var3); var1.a.b((new OPacket201PlayerInfo(var4.v, true, var4.i))); } Canary.hooks().callHook(new LoginHook(var1.getPlayer())); var1.getPlayer().refreshCreativeMode(); }
public void a(OEntityPlayerMP var1) { // this.d[0].b(var1); // this.d[1].b(var1); // this.d[2].b(var1); for (World w : Canary.getServer().getWorldManager().getAllWorlds()) { for (Dimension dim : w.getDimensions()) { dim.getPlayerManager().removePlayer(var1.getPlayer()); } } // this.a(var1.w).a(var1); //remove again? rly? // OWorldServer var2 = this.c.a(var1.w); var1.getDimension().getPlayerManager().addPlayer(var1.getPlayer()); OWorldServer var2 = (OWorldServer) ((CanaryDimension) var1.getDimension()).getHandle(); var2.G.c((int) var1.bm >> 4, (int) var1.bo >> 4); }