Protect placeStore. It's ugly and still needs work.

This commit is contained in:
GJ
2013-02-17 00:40:11 -05:00
parent f61aed9f6c
commit 1fe182babe
14 changed files with 90 additions and 46 deletions

View File

@ -619,11 +619,9 @@ public class HashChunkManager implements ChunkManager {
List<Entity> tempSpawnedMobs = new ArrayList<Entity>(spawnedMobs);
for (Entity entity : tempSpawnedMobs) {
if (entity.isDead())
mobsToRemove.add(entity);
if (!entity.isValid())
if (entity.isDead() || !entity.isValid()) {
mobsToRemove.add(entity);
}
}
spawnedMobs.removeAll(mobsToRemove);

View File

@ -34,7 +34,7 @@ public class BlockStoreConversionZDirectory implements Runnable {
this.world = world;
this.scheduler = mcMMO.p.getServer().getScheduler();
this.manager = new HashChunkletManager();
this.newManager = (HashChunkManager) mcMMO.placeStore;
this.newManager = (HashChunkManager) mcMMO.p.getChunkStore();
this.dataDir = dataDir;
this.xDir = xDir;