Plugin not working?

Discussion in 'Plugin Development' started by iamcion, Oct 25, 2015.

Thread Status:
Not open for further replies.
  1. Offline

    iamcion

  2. Offline

    boysnnoco

    java.lang.NullPointerException
    me.iamcion.vcommands.Main.registerComand(Main.java:74)
     
  3. Offline

    iamcion

    Yeah, what should I do to fix that then? I mean.. the main class wasn't changed..

    this is the main class file
    http://pastebin.com/u0P2Mx89
     
  4. Offline

    Zombie_Striker

    getServer().getPluginCommand(alias).setExecutor(executor);

    Is the server null(most likely not)? Is alias null? IS THE PLUGIN COMMAND NULL? is the executor null?

    There is something null, you just have to find out what that is.
     
  5. Offline

    RoboticPlayer

    @iamcion
    Code:
    getServer().getPluginCommand(alias).setExecutor(executor)
    
    Why do you have this in this type of method? I just do
    Code:
    public void registerCommands() {
        getCommand(command).setExecutor(executor);
    }
    Where command is the name of the command and executor is the class which contains the code for that command.
     
  6. Offline

    iamcion

    Theres no difference really.

    it was working before I changed the plugin name.. :/
     
Thread Status:
Not open for further replies.

Share This Page