Fix nukkit parallel set

This commit is contained in:
Jesse Boyd 2016-11-28 17:33:53 +11:00
parent 585496b489
commit c3bded1c6d
No known key found for this signature in database
GPG Key ID: 59F1DE6293AF6E1F

View File

@ -15,6 +15,7 @@ import com.sk89q.jnbt.CompoundTag;
import com.sk89q.worldedit.LocalWorld;
import com.sk89q.worldedit.Vector2D;
import com.sk89q.worldedit.world.biome.BaseBiome;
import java.io.IOException;
import java.util.Map;
public class NukkitChunk extends CharFaweChunk<BaseFullChunk, NukkitQueue> {
@ -61,14 +62,23 @@ public class NukkitChunk extends CharFaweChunk<BaseFullChunk, NukkitQueue> {
private int index;
private boolean place = true;
@Override
public void start() {
try {
getChunk().load(true);
} catch (IOException e) {
e.printStackTrace();
}
}
@Override
public NukkitChunk call() {
// Set heightmap
getParent().setHeightMap(this, heightMap);
NukkitQueue parent = (NukkitQueue) getParent();
Level world = ((NukkitQueue) getParent()).getWorld();
world.clearCache(true);
final BaseFullChunk chunk = getChunk();
getParent().setHeightMap(this, heightMap);
char[][] sections = getCombinedIdArrays();
final int[][] biomes = getBiomeArray();
final int X = getX() << 4;