Error message states:
java.lang.NullPointerException: Cannot invoke "org.bukkit.command.PluginCommand.setExecutor(org.bukkit.command.CommandExecutor)" because the return value of "me.mackaroni.testplugin.TestPlugin.getCommand(String)" is null
for reference this is my onEnable:
public void onEnable() {
// Plugin startup logic
Bukkit.getConsoleSender().sendMessage("[TEST PLUGIN]This Plugin Works!");
Bukkit.getPluginManager().registerEvents(new JoinMessage(), this);
// THIS SPECIFIC LINE IS THE ISSUE
this.getCommand("Doctor").setExecutor(new Heal());
}
and my plugin.yml contains
commands:
Doctor:
