Replace ConfiguredStructure api with Structure (#8642)

This commit is contained in:
Jake Potrebic
2023-02-28 08:36:01 -08:00
parent 81f79b407d
commit f8ba85ffbf
12 changed files with 139 additions and 342 deletions

View File

@@ -3470,6 +3470,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+package io.papermc.paper.util;
+
+import com.google.common.util.concurrent.ThreadFactoryBuilder;
+import io.papermc.paper.math.Position;
+import it.unimi.dsi.fastutil.objects.ObjectRBTreeSet;
+import java.lang.ref.Cleaner;
+import net.minecraft.core.BlockPos;
@@ -3933,6 +3934,10 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+ return new BlockPos(loc.getBlockX(), loc.getBlockY(), loc.getBlockZ());
+ }
+
+ public static BlockPos toBlockPos(Position pos) {
+ return new BlockPos(pos.blockX(), pos.blockY(), pos.blockZ());
+ }
+
+ public static boolean isEdgeOfChunk(BlockPos pos) {
+ final int modX = pos.getX() & 15;
+ final int modZ = pos.getZ() & 15;