I have recently had the problem that my Chatclear Command is not working. This error message appears when starting:
[09:03:02 ERROR]: Error occurred while enabling plugin v1.0 (Is it up to date?)
java.lang.NullPointerException
at de.name.plugin.main.Main.onEnable (Main.java:25) ~ [?:?]
at org.bukkit.plugin.java.JavaPlugin.setEnabled (JavaPlugin.java:321) ~ [spigot.jar: git-Spigot-c3c767f-33d5de3]
at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin (JavaPluginLoader.java:335) [spigot.jar: git-Spigot-c3c767f-33d5de3]
at org.bukkit.plugin.SimplePluginManager.enablePlugin (SimplePluginManager.java:405) [spigot.jar: git-Spigot-c3c767f-33d5de3]
at org.bukkit.craftbukkit.v1_8_R1.CraftServer.loadPlugin (CraftServer.java:356) [spigot.jar: git-Spigot-c3c767f-33d5de3]
at org.bukkit.craftbukkit.v1_8_R1.CraftServer.enablePlugins (CraftServer.java:316) [spigot.jar: git-Spigot-c3c767f-33d5de3]
at org.bukkit.craftbukkit.v1_8_R1.CraftServer.reload (CraftServer.java:746) [spigot.jar: git-Spigot-c3c767f-33d5de3]
at org.bukkit.Bukkit.reload (Bukkit.java:534) [spigot.jar: git-Spigot-c3c767f-33d5de3]
at org.bukkit.command.defaults.ReloadCommand.execute (ReloadCommand.java:25) [spigot.jar: git-Spigot-c3c767f-33d5de3]
at org.bukkit.command.SimpleCommandMap.dispatch (SimpleCommandMap.java:141) [spigot.jar: git-Spigot-c3c767f-33d5de3]
at org.bukkit.craftbukkit.v1_8_R1.CraftServer.dispatchCommand (CraftServer.java:646) [spigot.jar: git-Spigot-c3c767f-33d5de3]
at org.bukkit.craftbukkit.v1_8_R1.CraftServer.dispatchServerCommand (CraftServer.java:632) [spigot.jar: git-Spigot-c3c767f-33d5de3]
at net.minecraft.server.v1_8_R1.DedicatedServer.aM (DedicatedServer.java:353) [spigot.jar: git-Spigot-c3c767f-33d5de3]
at net.minecraft.server.v1_8_R1.DedicatedServer.z (DedicatedServer.java:317) [spigot.jar: git-Spigot-c3c767f-33d5de3]
at net.minecraft.server.v1_8_R1.MinecraftServer.y (MinecraftServer.java:634) [spigot.jar: git-Spigot-c3c767f-33d5de3]
at net.minecraft.server.v1_8_R1.MinecraftServer.run (MinecraftServer.java:537) [spigot.jar: git-Spigot-c3c767f-33d5de3]
at java.lang.Thread.run (Unknown Source) [?: 1.8.0_241]
The command is entered in the plugin.yml and in the main. Eclipse itself does not recognize any errors
Eclipse itself does not recognize any errors
It is also a runtime error. With a NullPointerException, an object is accessed that does not exist. Look in the line:
at de.name.plugin.main.Main.onEnable (Main.java:25
and check what might be zero there at runtime.