fix more compile errors

This commit is contained in:
Jake Potrebic
2023-03-14 16:10:18 -07:00
parent e277e6a990
commit 8b4edb6f19
22 changed files with 90 additions and 71 deletions

View File

@@ -20,7 +20,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+
+ @Override
+ public Location locateNearestBiome(Location origin, Biome biome, int radius, int step) {
+ BlockPos originPos = new BlockPos(origin.getX(), origin.getY(), origin.getZ());
+ BlockPos originPos = io.papermc.paper.util.MCUtil.toBlockPos(origin);
+ Pair<BlockPos, Holder<net.minecraft.world.level.biome.Biome>> pair = getHandle().findClosestBiome3d(holder -> holder.is(CraftNamespacedKey.toMinecraft(biome.getKey())), originPos, radius, step, step);
+ if (pair == null) {
+ return null;
@@ -92,7 +92,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+ }
+
+ public static net.minecraft.core.BlockPos toBlockPos(org.bukkit.util.Vector bukkit) {
+ return new net.minecraft.core.BlockPos(bukkit.getX(), bukkit.getY(), bukkit.getZ());
+ return net.minecraft.core.BlockPos.containing(bukkit.getX(), bukkit.getY(), bukkit.getZ());
+ }
+ // Paper end
}