Compiler issues v4
This commit is contained in:
@@ -4098,11 +4098,14 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
+import java.util.function.Supplier;
|
||||
+import net.minecraft.core.BlockPos;
|
||||
+import net.minecraft.core.Vec3i;
|
||||
+import net.minecraft.resources.ResourceKey;
|
||||
+import net.minecraft.server.MinecraftServer;
|
||||
+import net.minecraft.world.level.ChunkPos;
|
||||
+import net.minecraft.world.level.Level;
|
||||
+import net.minecraft.world.phys.Vec3;
|
||||
+import org.bukkit.Location;
|
||||
+import org.bukkit.NamespacedKey;
|
||||
+import org.bukkit.craftbukkit.util.CraftNamespacedKey;
|
||||
+import org.bukkit.craftbukkit.util.Waitable;
|
||||
+
|
||||
+public final class MCUtil {
|
||||
@@ -4256,6 +4259,17 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
+ public static void scheduleAsyncTask(Runnable run) {
|
||||
+ asyncExecutor.execute(run);
|
||||
+ }
|
||||
+
|
||||
+ public static <T> ResourceKey<T> toResourceKey(
|
||||
+ final ResourceKey<? extends net.minecraft.core.Registry<T>> registry,
|
||||
+ final NamespacedKey namespacedKey
|
||||
+ ) {
|
||||
+ return ResourceKey.create(registry, CraftNamespacedKey.toMinecraft(namespacedKey));
|
||||
+ }
|
||||
+
|
||||
+ public static NamespacedKey fromResourceKey(final ResourceKey<?> key) {
|
||||
+ return CraftNamespacedKey.fromMinecraft(key.location());
|
||||
+ }
|
||||
+}
|
||||
diff --git a/src/main/java/io/papermc/paper/util/StackWalkerUtil.java b/src/main/java/io/papermc/paper/util/StackWalkerUtil.java
|
||||
new file mode 100644
|
||||
|
||||
Reference in New Issue
Block a user