Fix lighting 1.14

Dieser Commit ist enthalten in:
Jesse Boyd 2019-11-24 02:26:52 +00:00
Ursprung ee54dcd809
Commit 913ada31fb
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 59F1DE6293AF6E1F
3 geänderte Dateien mit 13 neuen und 8 gelöschten Zeilen

3
.gitignore vendored
Datei anzeigen

@ -22,4 +22,5 @@ logs/
worldedit-bukkit/src/main/java/ignore/*
todo.txt
mvn/*
docs/
docs/
*.sh

Datei anzeigen

@ -14,6 +14,7 @@ import com.boydti.fawe.bukkit.adapter.mc1_14.nbt.LazyCompoundTag_1_14;
import com.boydti.fawe.object.collection.AdaptedMap;
import com.boydti.fawe.object.collection.BitArray4096;
import com.boydti.fawe.util.ReflectionUtils;
import com.boydti.fawe.util.TaskManager;
import com.google.common.base.Suppliers;
import com.google.common.collect.Iterables;
import com.sk89q.jnbt.CompoundTag;
@ -41,11 +42,13 @@ import java.util.UUID;
import java.util.concurrent.Callable;
import java.util.concurrent.Future;
import java.util.function.Function;
import java.util.function.Supplier;
import javax.annotation.Nullable;
import net.minecraft.server.v1_14_R1.BiomeBase;
import net.minecraft.server.v1_14_R1.BlockPosition;
import net.minecraft.server.v1_14_R1.Chunk;
import net.minecraft.server.v1_14_R1.ChunkSection;
import net.minecraft.server.v1_14_R1.ChunkStatus;
import net.minecraft.server.v1_14_R1.DataBits;
import net.minecraft.server.v1_14_R1.DataPalette;
import net.minecraft.server.v1_14_R1.DataPaletteBlock;
@ -54,6 +57,8 @@ import net.minecraft.server.v1_14_R1.DataPaletteLinear;
import net.minecraft.server.v1_14_R1.Entity;
import net.minecraft.server.v1_14_R1.EntityTypes;
import net.minecraft.server.v1_14_R1.IBlockData;
import net.minecraft.server.v1_14_R1.LightEngine;
import net.minecraft.server.v1_14_R1.LightEngineThreaded;
import net.minecraft.server.v1_14_R1.NBTTagCompound;
import net.minecraft.server.v1_14_R1.NBTTagInt;
import net.minecraft.server.v1_14_R1.TileEntity;
@ -444,12 +449,11 @@ public class BukkitGetBlocks_1_14 extends CharGetBlocks {
};
}
// {//Lighting
// for (int layer = 0; layer < 16; layer++) {
// if (!set.hasSection(layer)) continue;
// //TODO lighting
// }
// }
{//Lighting
// TODO optimize, cause this is really slow
LightEngineThreaded engine = (LightEngineThreaded) nmsChunk.e();
engine.a(nmsChunk, false);
}
Runnable callback;
if (bitMask == 0 && biomes == null) {

Datei anzeigen

@ -192,7 +192,7 @@ public class BukkitWorld extends AbstractWorld {
public boolean regenerate(Region region, EditSession editSession) {
BukkitImplAdapter adapter = WorldEditPlugin.getInstance().getBukkitImplAdapter();
if (adapter != null) {
return adapter.regenerate(getWorld(), region, editSession);
return adapter.regenerate(getWorld(), region, null, null, editSession);
}
/*
BaseBlock[] history = new BaseBlock[16 * 16 * (getMaxY() + 1)];