Coding bukkit in java

Discussion in 'Plugin Development' started by jkjames6, Jan 28, 2014.

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


    I have been starting to code in java and when I try a command it says nothing to me.
    Here's my only class:
    Im quite new with this java stuff so please no hate ^_^
  2. Offline


    jkjames6 did you put the command in the plugin.yml
  3. Offline


    Well, first off, don't use commandLabel. Start your command like this

    if (cmd.getName().equalsIgnoreCase("cmd")) {

    commandLabel is getting the command alias.
  4. Offline


    Follow a coding standard. Use proper spacing, and remember bracket syntax (semicolons don't come directly after "if" statements, you should have closing brackets, etc)
  5. Offline


    Yea here's the plugin.yml

    OO thanks i didn't see that sneaky ; come in there

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
    Last edited by a moderator: Jun 6, 2016
  6. Offline


    ah you need to add this to the public void onEnable
    this.getConfig.addDefault(msg1, (Default Message);
Thread Status:
Not open for further replies.

Share This Page