diff --git a/patches/api/Add-Lifecycle-Event-system.patch b/patches/api/Add-Lifecycle-Event-system.patch index 2cf4bee882..e9c0558c60 100644 --- a/patches/api/Add-Lifecycle-Event-system.patch +++ b/patches/api/Add-Lifecycle-Event-system.patch @@ -555,7 +555,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 -public interface Plugin extends TabExecutor { +public interface Plugin extends TabExecutor, io.papermc.paper.plugin.lifecycle.event.LifecycleEventOwner { // Paper /** - * Returns the folder that the plugin data's files are located in. The + * Returns the folder that the plugin data files are located in. The * folder may not yet exist. @@ -0,0 +0,0 @@ public interface Plugin extends TabExecutor { */ diff --git a/patches/api/Fix-upstream-javadocs.patch b/patches/api/Fix-upstream-javadocs.patch index 347918afb9..d3659a64cf 100644 --- a/patches/api/Fix-upstream-javadocs.patch +++ b/patches/api/Fix-upstream-javadocs.patch @@ -1651,6 +1651,56 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 */ public interface OminousBottleMeta extends ItemMeta { +diff --git a/src/main/java/org/bukkit/plugin/Plugin.java b/src/main/java/org/bukkit/plugin/Plugin.java +index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 +--- a/src/main/java/org/bukkit/plugin/Plugin.java ++++ b/src/main/java/org/bukkit/plugin/Plugin.java +@@ -0,0 +0,0 @@ import org.jetbrains.annotations.Nullable; + */ + public interface Plugin extends TabExecutor { + /** +- * Returns the folder that the plugin data's files are located in. The ++ * Returns the folder that the plugin data files are located in. The + * folder may not yet exist. + * + * @return The folder +@@ -0,0 +0,0 @@ public interface Plugin extends TabExecutor { + public File getDataFolder(); + + /** +- * Returns the plugin.yaml file containing the details for this plugin ++ * Returns the plugin.yml file containing the details for this plugin + * +- * @return Contents of the plugin.yaml file ++ * @return Contents of the plugin.yml file + * @deprecated May be inaccurate due to different plugin implementations. + * @see Plugin#getPluginMeta() + */ +diff --git a/src/main/java/org/bukkit/plugin/java/JavaPlugin.java b/src/main/java/org/bukkit/plugin/java/JavaPlugin.java +index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 +--- a/src/main/java/org/bukkit/plugin/java/JavaPlugin.java ++++ b/src/main/java/org/bukkit/plugin/java/JavaPlugin.java +@@ -0,0 +0,0 @@ public abstract class JavaPlugin extends PluginBase { + } + + /** +- * Returns the folder that the plugin data's files are located in. The ++ * Returns the folder that the plugin data files are located in. The + * folder may not yet exist. + * + * @return The folder. +@@ -0,0 +0,0 @@ public abstract class JavaPlugin extends PluginBase { + } + + /** +- * Returns the plugin.yaml file containing the details for this plugin ++ * Returns the plugin.yml file containing the details for this plugin + * +- * @return Contents of the plugin.yaml file ++ * @return Contents of the plugin.yml file + * @deprecated No longer applicable to all types of plugins + */ + @NotNull diff --git a/src/main/java/org/bukkit/plugin/messaging/PluginMessageRecipient.java b/src/main/java/org/bukkit/plugin/messaging/PluginMessageRecipient.java index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/org/bukkit/plugin/messaging/PluginMessageRecipient.java diff --git a/patches/api/add-Plugin-getDataPath.patch b/patches/api/add-Plugin-getDataPath.patch new file mode 100644 index 0000000000..6238c6277c --- /dev/null +++ b/patches/api/add-Plugin-getDataPath.patch @@ -0,0 +1,30 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: powercas_gamer <cas@mizule.dev> +Date: Mon, 15 Jul 2024 02:07:49 +0000 +Subject: [PATCH] add Plugin#getDataPath + + +diff --git a/src/main/java/org/bukkit/plugin/Plugin.java b/src/main/java/org/bukkit/plugin/Plugin.java +index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 +--- a/src/main/java/org/bukkit/plugin/Plugin.java ++++ b/src/main/java/org/bukkit/plugin/Plugin.java +@@ -0,0 +0,0 @@ public interface Plugin extends TabExecutor, io.papermc.paper.plugin.lifecycle.e + @NotNull + public File getDataFolder(); + ++ // Paper start - add getDataPath() ++ /** ++ * Returns the path that the plugin data files are located in. ++ * The folder may not yet exist. ++ * ++ * @see #getDataFolder() ++ * @return The folder ++ */ ++ default @NotNull java.nio.file.Path getDataPath() { ++ return getDataFolder().toPath(); ++ } ++ // Paper end - add getDataPath() ++ + /** + * Returns the plugin.yml file containing the details for this plugin + *