From baf766d2b35bc5120e7b2cbff368f906c7476e1d Mon Sep 17 00:00:00 2001 From: xGinko Date: Tue, 13 Aug 2024 01:35:33 +0200 Subject: [PATCH] use XMaterial in util --- shared/src/main/java/me/xginko/aef/utils/ChunkUtil.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/shared/src/main/java/me/xginko/aef/utils/ChunkUtil.java b/shared/src/main/java/me/xginko/aef/utils/ChunkUtil.java index eeeeff15..0e393cc6 100644 --- a/shared/src/main/java/me/xginko/aef/utils/ChunkUtil.java +++ b/shared/src/main/java/me/xginko/aef/utils/ChunkUtil.java @@ -1,8 +1,8 @@ package me.xginko.aef.utils; +import com.cryptomorin.xseries.XMaterial; import org.bukkit.Chunk; import org.bukkit.Location; -import org.bukkit.Material; import org.bukkit.util.NumberConversions; public class ChunkUtil { @@ -37,9 +37,9 @@ public static long getInhabitedTime(Chunk chunk) { public static void createBedrockLayer(Chunk chunk, int y) { for (int x = 0; x < 16; x++) { for (int z = 0; z < 16; z++) { - if (chunk.getBlock(x, y, z).getType() != Material.BEDROCK) { + if (chunk.getBlock(x, y, z).getType() != XMaterial.BEDROCK.parseMaterial()) { // prevent physics to avoid loading nearby chunks which causes infinite chunk loading loops - chunk.getBlock(x, y, z).setType(Material.BEDROCK, false); + chunk.getBlock(x, y, z).setType(XMaterial.BEDROCK.parseMaterial(), false); } } }