private void initChunkRaw(Point p) { int x = p.getChunkX(); int y = p.getChunkY(); // + SEALEVEL_CHUNK; int z = p.getChunkZ(); RepositionManager rm = getRepositionManager(); int cY = rm.convertChunkY(y); if (cY < 0 || cY >= p.getWorld().getHeight() >> Chunk.BLOCKS.BITS) { return; } TSyncIntHashSet column = initializedChunks.get(x, z); if (column == null) { column = new TSyncIntHashSet(); synchronized (initChunkLock) { TSyncIntHashSet oldColumn = initializedChunks.putIfAbsent(x, z, column); if (oldColumn != null) { column = oldColumn; } } } column.add(y); }
@Override protected void initChunk(Point p) { int x = p.getChunkX(); int y = p.getChunkY(); // + SEALEVEL_CHUNK; int z = p.getChunkZ(); if (y < 0 || y >= p.getWorld().getHeight() >> Chunk.BLOCKS.BITS) { return; } TSyncIntHashSet column = initializedChunks.get(x, z); if (column == null) { column = new TSyncIntHashSet(); synchronized (initChunkLock) { TSyncIntHashSet oldColumn = initializedChunks.putIfAbsent(x, z, column); if (oldColumn != null) { column = oldColumn; } } } column.add(y); }