Fix biome setting

This commit is contained in:
Alexander Söderberg 2020-04-20 23:36:56 +02:00
parent 558df450b5
commit 8db8a30455
No known key found for this signature in database
GPG Key ID: C0207FF7EA146678

View File

@ -517,17 +517,8 @@ public class BukkitUtil extends WorldUtil {
for (int x = region.getMinimumPoint().getX(); x <= region.getMaximumPoint().getX(); x++) {
for (int z = region.getMinimumPoint().getZ();
z <= region.getMaximumPoint().getZ(); z++) {
for (int y = 0; y < world.getMaxHeight(); y++) {
try {
if (biomeSetter != null) {
biomeSetter.invoke(world, x, z, biome);
} else {
world.setBiome(x, y, z, biome);
}
} catch (final Exception e) {
PlotSquared.log("An error occurred setting the biome:");
e.printStackTrace();
}
if (world.getBiome(x, 64, z) != biome) {
world.setBiome(x, z, biome);
}
}
}