diff options
author | Erik Broes <erikbroes@grum.nl> | 2011-02-23 13:56:36 +0100 |
---|---|---|
committer | Erik Broes <erikbroes@grum.nl> | 2011-02-23 14:12:33 +0100 |
commit | 09aa37fe4a126c5fc2e557ae5b68bb58cd0a3059 (patch) | |
tree | 4d813de09480cee3083997ee192c3c9b9e35e863 /src/main/java/net/minecraft/server/ChunkProviderServer.java | |
parent | 332d9c4f1884a03152c11ccb0b63c2e3127618ea (diff) | |
download | craftbukkit-09aa37fe4a126c5fc2e557ae5b68bb58cd0a3059.tar craftbukkit-09aa37fe4a126c5fc2e557ae5b68bb58cd0a3059.tar.gz craftbukkit-09aa37fe4a126c5fc2e557ae5b68bb58cd0a3059.tar.lz craftbukkit-09aa37fe4a126c5fc2e557ae5b68bb58cd0a3059.tar.xz craftbukkit-09aa37fe4a126c5fc2e557ae5b68bb58cd0a3059.zip |
Generic code cleanup
Diffstat (limited to 'src/main/java/net/minecraft/server/ChunkProviderServer.java')
-rw-r--r-- | src/main/java/net/minecraft/server/ChunkProviderServer.java | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/main/java/net/minecraft/server/ChunkProviderServer.java b/src/main/java/net/minecraft/server/ChunkProviderServer.java index 1153e688..ae85702e 100644 --- a/src/main/java/net/minecraft/server/ChunkProviderServer.java +++ b/src/main/java/net/minecraft/server/ChunkProviderServer.java @@ -23,8 +23,8 @@ public class ChunkProviderServer implements IChunkProvider { private IChunkProvider c; private IChunkLoader d; public LongHashtable<Chunk> e = new LongHashtable<Chunk>(); // CraftBukkit - public List f = new ArrayList(); // Craftbukkit - public WorldServer g; // Craftbukkit + public List f = new ArrayList(); // CraftBukkit + public WorldServer g; // CraftBukkit public ChunkProviderServer(WorldServer worldserver, IChunkLoader ichunkloader, IChunkProvider ichunkprovider) { this.b = new EmptyChunk(worldserver, new byte['\u8000'], 0, 0); @@ -34,7 +34,7 @@ public class ChunkProviderServer implements IChunkProvider { } public boolean a(int i, int j) { - return this.e.containsKey(i, j); // Craftbukkit - entire method removed + return this.e.containsKey(i, j); // CraftBukkit } public void c(int i, int j) { @@ -109,7 +109,7 @@ public class ChunkProviderServer implements IChunkProvider { return chunk == null ? (this.g.r ? this.d(i, j) : this.b) : chunk; } - public Chunk e(int i, int j) { // Craftbukkit - public + public Chunk e(int i, int j) { // CraftBukkit - private->public if (this.d == null) { return null; } else { @@ -128,7 +128,7 @@ public class ChunkProviderServer implements IChunkProvider { } } - public void a(Chunk chunk) { // Craftbukkit - public + public void a(Chunk chunk) { // CraftBukkit - private->public if (this.d != null) { try { this.d.b(this.g, chunk); @@ -138,7 +138,7 @@ public class ChunkProviderServer implements IChunkProvider { } } - public void b(Chunk chunk) { // Craftbukkit - public + public void b(Chunk chunk) { // CraftBukkit - private->public if (this.d != null) { try { chunk.r = this.g.k(); @@ -201,9 +201,9 @@ public class ChunkProviderServer implements IChunkProvider { Chunk chunk = e.get(chunkcoordinates); if (chunk == null) continue; - ChunkUnloadEvent cue = new ChunkUnloadEvent(Type.CHUNK_UNLOADED, chunk.bukkitChunk); - server.getPluginManager().callEvent(cue); - if (!cue.isCancelled()) { + ChunkUnloadEvent event = new ChunkUnloadEvent(Type.CHUNK_UNLOADED, chunk.bukkitChunk); + server.getPluginManager().callEvent(event); + if (!event.isCancelled()) { g.getWorld().preserveChunk( (CraftChunk) chunk.bukkitChunk ); chunk.e(); |