Mirror von
https://github.com/GeyserMC/Geyser.git
synchronisiert 2024-11-20 06:50:09 +01:00
Fix stack trace when coordinate_scale isn't a DoubleTag
Dieser Commit ist enthalten in:
Ursprung
2420e33149
Commit
fd955a66af
@ -27,7 +27,6 @@ package org.geysermc.geyser.util;
|
|||||||
|
|
||||||
import com.github.steveice10.mc.protocol.data.game.entity.metadata.Position;
|
import com.github.steveice10.mc.protocol.data.game.entity.metadata.Position;
|
||||||
import com.github.steveice10.opennbt.tag.builtin.CompoundTag;
|
import com.github.steveice10.opennbt.tag.builtin.CompoundTag;
|
||||||
import com.github.steveice10.opennbt.tag.builtin.DoubleTag;
|
|
||||||
import com.github.steveice10.opennbt.tag.builtin.IntTag;
|
import com.github.steveice10.opennbt.tag.builtin.IntTag;
|
||||||
import com.nukkitx.math.vector.Vector2i;
|
import com.nukkitx.math.vector.Vector2i;
|
||||||
import com.nukkitx.math.vector.Vector3i;
|
import com.nukkitx.math.vector.Vector3i;
|
||||||
@ -40,14 +39,14 @@ import it.unimi.dsi.fastutil.ints.IntLists;
|
|||||||
import lombok.experimental.UtilityClass;
|
import lombok.experimental.UtilityClass;
|
||||||
import org.geysermc.geyser.entity.type.ItemFrameEntity;
|
import org.geysermc.geyser.entity.type.ItemFrameEntity;
|
||||||
import org.geysermc.geyser.entity.type.player.SkullPlayerEntity;
|
import org.geysermc.geyser.entity.type.player.SkullPlayerEntity;
|
||||||
import org.geysermc.geyser.session.GeyserSession;
|
|
||||||
import org.geysermc.geyser.level.block.BlockStateValues;
|
import org.geysermc.geyser.level.block.BlockStateValues;
|
||||||
import org.geysermc.geyser.text.GeyserLocale;
|
|
||||||
import org.geysermc.geyser.translator.level.block.entity.BedrockOnlyBlockEntity;
|
|
||||||
import org.geysermc.geyser.level.chunk.BlockStorage;
|
import org.geysermc.geyser.level.chunk.BlockStorage;
|
||||||
import org.geysermc.geyser.level.chunk.GeyserChunkSection;
|
import org.geysermc.geyser.level.chunk.GeyserChunkSection;
|
||||||
import org.geysermc.geyser.level.chunk.bitarray.SingletonBitArray;
|
import org.geysermc.geyser.level.chunk.bitarray.SingletonBitArray;
|
||||||
import org.geysermc.geyser.registry.BlockRegistries;
|
import org.geysermc.geyser.registry.BlockRegistries;
|
||||||
|
import org.geysermc.geyser.session.GeyserSession;
|
||||||
|
import org.geysermc.geyser.text.GeyserLocale;
|
||||||
|
import org.geysermc.geyser.translator.level.block.entity.BedrockOnlyBlockEntity;
|
||||||
|
|
||||||
import static org.geysermc.geyser.level.block.BlockStateValues.JAVA_AIR_ID;
|
import static org.geysermc.geyser.level.block.BlockStateValues.JAVA_AIR_ID;
|
||||||
|
|
||||||
@ -264,7 +263,7 @@ public class ChunkUtils {
|
|||||||
session.getChunkCache().setHeightY(maxY);
|
session.getChunkCache().setHeightY(maxY);
|
||||||
|
|
||||||
// Load world coordinate scale for the world border
|
// Load world coordinate scale for the world border
|
||||||
double coordinateScale = ((DoubleTag) dimensionTag.get("coordinate_scale")).getValue();
|
double coordinateScale = ((Number) dimensionTag.get("coordinate_scale").getValue()).doubleValue();
|
||||||
session.getWorldBorder().setWorldCoordinateScale(coordinateScale);
|
session.getWorldBorder().setWorldCoordinateScale(coordinateScale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren