From c3bded1c6ded22c3affec4d9d45ffe984c56b976 Mon Sep 17 00:00:00 2001 From: Jesse Boyd Date: Mon, 28 Nov 2016 17:33:53 +1100 Subject: [PATCH] Fix nukkit parallel set --- .../fawe/nukkit/optimization/queue/NukkitChunk.java | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/nukkit/src/main/java/com/boydti/fawe/nukkit/optimization/queue/NukkitChunk.java b/nukkit/src/main/java/com/boydti/fawe/nukkit/optimization/queue/NukkitChunk.java index ca020aa1..a5aeac6a 100644 --- a/nukkit/src/main/java/com/boydti/fawe/nukkit/optimization/queue/NukkitChunk.java +++ b/nukkit/src/main/java/com/boydti/fawe/nukkit/optimization/queue/NukkitChunk.java @@ -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 { @@ -61,14 +62,23 @@ public class NukkitChunk extends CharFaweChunk { 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;