Get fabric 1.21.3 building
This commit is contained in:
parent
a5ee1ddd00
commit
231a3b2c6c
7 changed files with 8 additions and 63 deletions
|
|
@ -163,7 +163,7 @@ public class DynmapPlugin {
|
|||
}
|
||||
statename += p.getName() + "=" + bs.get(p).toString();
|
||||
}
|
||||
int lightAtten = bs.isOpaqueFullCube(EmptyBlockView.INSTANCE, BlockPos.ORIGIN) ? 15 : (bs.isTransparent(EmptyBlockView.INSTANCE, BlockPos.ORIGIN) ? 0 : 1);
|
||||
int lightAtten = bs.isOpaqueFullCube() ? 15 : (bs.isTransparent() ? 0 : 1);
|
||||
//Log.info("statename=" + bn + "[" + statename + "], lightAtten=" + lightAtten);
|
||||
// Fill in base attributes
|
||||
bld.setBaseState(basebs).setStateIndex(idx - baseidx).setBlockName(bn).setStateName(statename).setLegacyBlockID(idx).setAttenuatesLight(lightAtten);
|
||||
|
|
|
|||
|
|
@ -8,12 +8,12 @@ import net.minecraft.util.collection.PackedIntegerArray;
|
|||
import net.minecraft.util.math.ChunkPos;
|
||||
import net.minecraft.util.math.MathHelper;
|
||||
import net.minecraft.util.math.WordPackedArray;
|
||||
import net.minecraft.world.ChunkSerializer;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.biome.Biome;
|
||||
import net.minecraft.world.biome.BiomeEffects;
|
||||
import net.minecraft.world.chunk.ChunkManager;
|
||||
import net.minecraft.world.chunk.ChunkStatus;
|
||||
import net.minecraft.world.chunk.SerializedChunk;
|
||||
|
||||
import org.dynmap.DynmapChunk;
|
||||
import org.dynmap.DynmapCore;
|
||||
|
|
@ -66,7 +66,8 @@ public class FabricMapChunkCache extends GenericMapChunkCache {
|
|||
if (cps.isChunkLoaded(chunk.x, chunk.z)) {
|
||||
NbtCompound nbt = null;
|
||||
try {
|
||||
nbt = ChunkSerializer.serialize((ServerWorld) w, cps.getWorldChunk(chunk.x, chunk.z, false));
|
||||
SerializedChunk sc = SerializedChunk.fromChunk((ServerWorld) w, cps.getWorldChunk(chunk.x, chunk.z, false));
|
||||
nbt = sc.serialize();
|
||||
} catch (NullPointerException e) {
|
||||
// TODO: find out why this is happening and why it only seems to happen since 1.16.2
|
||||
Log.severe("ChunkSerializer.serialize threw a NullPointerException", e);
|
||||
|
|
|
|||
|
|
@ -60,7 +60,7 @@ public class FabricServer extends DynmapServerInterface {
|
|||
public FabricServer(DynmapPlugin plugin, MinecraftServer server) {
|
||||
this.plugin = plugin;
|
||||
this.server = server;
|
||||
this.biomeRegistry = server.getRegistryManager().get(RegistryKeys.BIOME);
|
||||
this.biomeRegistry = server.getRegistryManager().getOrThrow(RegistryKeys.BIOME);
|
||||
}
|
||||
|
||||
private Optional<GameProfile> getProfileByName(String player) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue