diff options
author | Travis Watkins <amaranth@ubuntu.com> | 2012-08-05 18:42:03 -0500 |
---|---|---|
committer | Travis Watkins <amaranth@ubuntu.com> | 2012-08-05 18:42:03 -0500 |
commit | beb71069b71be1474ba1d9b18310812e094dc74e (patch) | |
tree | 4986a0d4c6393d05f508a4ca106df588b5a79756 /src | |
parent | 0e013fa4b088eee3e99526e1a2b10b9fcb385838 (diff) | |
download | craftbukkit-beb71069b71be1474ba1d9b18310812e094dc74e.tar craftbukkit-beb71069b71be1474ba1d9b18310812e094dc74e.tar.gz craftbukkit-beb71069b71be1474ba1d9b18310812e094dc74e.tar.lz craftbukkit-beb71069b71be1474ba1d9b18310812e094dc74e.tar.xz craftbukkit-beb71069b71be1474ba1d9b18310812e094dc74e.zip |
Don't use Packet56 and clear client cache on world changes.
Diffstat (limited to 'src')
-rw-r--r-- | src/main/java/net/minecraft/server/EntityPlayer.java | 8 | ||||
-rw-r--r-- | src/main/java/net/minecraft/server/ServerConfigurationManagerAbstract.java | 2 |
2 files changed, 9 insertions, 1 deletions
diff --git a/src/main/java/net/minecraft/server/EntityPlayer.java b/src/main/java/net/minecraft/server/EntityPlayer.java index e5a30da3..bffdca79 100644 --- a/src/main/java/net/minecraft/server/EntityPlayer.java +++ b/src/main/java/net/minecraft/server/EntityPlayer.java @@ -167,7 +167,13 @@ public class EntityPlayer extends EntityHuman implements ICrafting { } if (!arraylist.isEmpty()) { - this.netServerHandler.sendPacket(new Packet56MapChunkBulk(arraylist)); + // CraftBukkit start - don't use map chunk bulk for now TODO: fix this + for (Object object : arraylist) { + this.netServerHandler.sendPacket(new Packet51MapChunk((Chunk) object, true, 0xffff)); + } + // this.netServerHandler.sendPacket(new Packet56MapChunkBulk(arraylist)); + // CraftBukkit end + Iterator iterator1 = arraylist1.iterator(); while (iterator1.hasNext()) { diff --git a/src/main/java/net/minecraft/server/ServerConfigurationManagerAbstract.java b/src/main/java/net/minecraft/server/ServerConfigurationManagerAbstract.java index 35fa2cdd..bbc50403 100644 --- a/src/main/java/net/minecraft/server/ServerConfigurationManagerAbstract.java +++ b/src/main/java/net/minecraft/server/ServerConfigurationManagerAbstract.java @@ -380,6 +380,8 @@ public abstract class ServerConfigurationManagerAbstract { // CraftBukkit start byte actualDimension = (byte) (worldserver.getWorld().getEnvironment().getId()); + // Force the client to refresh their chunk cache. + entityplayer1.netServerHandler.sendPacket(new Packet9Respawn((byte) (actualDimension >= 0 ? -1 : 0), (byte) worldserver.difficulty, worldserver.getWorldData().getType(), worldserver.getHeight(), entityplayer.itemInWorldManager.getGameMode())); entityplayer1.netServerHandler.sendPacket(new Packet9Respawn(actualDimension, (byte) worldserver.difficulty, worldserver.getWorldData().getType(), worldserver.getHeight(), entityplayer.itemInWorldManager.getGameMode())); entityplayer1.spawnIn(worldserver); entityplayer1.dead = false; |