misc cleanup 4

This commit is contained in:
Leijurv 2018-09-16 17:58:35 -07:00
parent 543c0d0a33
commit b7cc707737
No known key found for this signature in database
GPG Key ID: 44A3EA646EADAC6A
4 changed files with 5 additions and 5 deletions

View File

@ -414,7 +414,7 @@ public class Settings {
}
}
} catch (IllegalAccessException e) {
throw new RuntimeException(e);
throw new IllegalStateException(e);
}
byLowerName = Collections.unmodifiableMap(tmpByName);
allSettings = Collections.unmodifiableList(tmpAll);

View File

@ -100,7 +100,7 @@ public final class CachedRegion implements IBlockTypeAccess {
return res;
}
final synchronized void updateCachedChunk(int chunkX, int chunkZ, CachedChunk chunk) {
public final synchronized void updateCachedChunk(int chunkX, int chunkZ, CachedChunk chunk) {
this.chunks[chunkX][chunkZ] = chunk;
hasUnsavedChanges = true;
}

View File

@ -116,7 +116,7 @@ public class AStarPathFinder extends AbstractNodeCostSearch implements Helper {
int chunkZ = currentNodePos.z >> 4;
if (dest.x >> 4 != chunkX || dest.z >> 4 != chunkZ) {
// only need to check if the destination is a loaded chunk if it's in a different chunk than the start of the movement
if (chunkProvider.getLoadedChunk(chunkX, chunkZ) == null) {
if (chunkProvider.isChunkGeneratedAt(chunkX, chunkZ)) {
// see issue #106
if (cachedWorld == null || !cachedWorld.isCached(dest)) {
numEmptyChunk++;

View File

@ -83,7 +83,7 @@ class LinkedListOpenSet implements IOpenSet {
}
public static class Node { //wrapper with next
Node nextOpen;
PathNode val;
private Node nextOpen;
private PathNode val;
}
}