spigot服务器不断出错

46scxncf  于 2021-06-27  发布在  Java
关注(0)|答案(1)|浏览(429)
Could not load 'plugins\My_first_spigiot.jar' in folder 'plugins'
org.bukkit.plugin.InvalidDescriptionException: Invalid plugin.yml
        at org.bukkit.plugin.java.JavaPluginLoader.getPluginDescription(JavaPluginLoader.java:160) ~[server.jar:git-Spigot-37d799b-3eb7236]
        at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager.java:144) ~[server.jar:git-Spigot-37d799b-3eb7236]
        at org.bukkit.craftbukkit.v1_16_R3.CraftServer.loadPlugins(CraftServer.java:383) ~[server.jar:git-Spigot-37d799b-3eb7236]
        at org.bukkit.craftbukkit.v1_16_R3.CraftServer.reload(CraftServer.java:874) ~[server.jar:git-Spigot-37d799b-3eb7236]
        at org.bukkit.Bukkit.reload(Bukkit.java:642) ~[server.jar:git-Spigot-37d799b-3eb7236]
        at org.bukkit.command.defaults.ReloadCommand.execute(ReloadCommand.java:27) ~[server.jar:git-Spigot-37d799b-3eb7236]
        at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:149) ~[server.jar:git-Spigot-37d799b-3eb7236]
        at org.bukkit.craftbukkit.v1_16_R3.CraftServer.dispatchCommand(CraftServer.java:758) ~[server.jar:git-Spigot-37d799b-3eb7236]
        at org.bukkit.craftbukkit.v1_16_R3.CraftServer.dispatchServerCommand(CraftServer.java:743) ~[server.jar:git-Spigot-37d799b-3eb7236]
        at net.minecraft.server.v1_16_R3.DedicatedServer.handleCommandQueue(DedicatedServer.java:387) ~[server.jar:git-Spigot-37d799b-3eb7236]
        at net.minecraft.server.v1_16_R3.DedicatedServer.b(DedicatedServer.java:356) ~[server.jar:git-Spigot-37d799b-3eb7236]
        at net.minecraft.server.v1_16_R3.MinecraftServer.a(MinecraftServer.java:1007) ~[server.jar:git-Spigot-37d799b-3eb7236]
        at net.minecraft.server.v1_16_R3.MinecraftServer.w(MinecraftServer.java:846) ~[server.jar:git-Spigot-37d799b-3eb7236]
        at net.minecraft.server.v1_16_R3.MinecraftServer.lambda$0(MinecraftServer.java:164) ~[server.jar:git-Spigot-37d799b-3eb7236]
        at java.lang.Thread.run(Unknown Source) [?:1.8.0_241]
Caused by: java.io.FileNotFoundException: Jar does not contain plugin.yml
cedebl8k

cedebl8k1#

您必须创建plugin.yml文件,其中包含插件的名称、作者、版本等。
plugin.yml的最简单形式如下所示:

name: //the plugins name as it should appear in the plugin list /pl
version: //the plugin's version
author: //the author's name
main: //your main class were the onEnable and onDisable methods are. (Ex: org.spigotmc.tutorial.MyPluginName)
api-version: //the version of the API you want to use, required starting with 1.13

我想分享我的插件的plugin.yml图片
这是一个资源和另一个有用的资源

相关问题