Solved Question about onCommand

Discussion in 'Plugin Development' started by beastman3226, Dec 2, 2013.

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

    beastman3226

    I was messing around one day and thought, "I have no idea where the Command parameter in the onCommand method comes from". I thought that this may cause problems down the road. Now I ask this, where does that command parameter come from? Also, how do I check if it is an alias that is used?
     
  2. Offline

    Mathias Eklund

    I don't think you can actually detect if a command is an alias.
     
  3. Offline

    beastman3226

    Then how do aliases work? My first question still stands aswell.

    Still have questions

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

    The_Doctor_123

    Command is an object giving information about the command that the player typed.
     
  5. Offline

    beastman3226

    What calls the onCommand method and where does the command parameter come from?
     
  6. Offline

    PolarCraft

    beastman3226 I am pretty sure you should know that since you have made a plugin with commands so yeah.
    (Not trying to be rude in any way)
     
  7. Offline

    beastman3226

    I just want to know how the behind the scenes stuff works. PolarCraft My question was to get a better understanding of what I already know.

    Thank you everyone. I took a look at Github. Whenever you set an executor the command gets found in the plugin.yml and then it finds the command. Checking the name equivalent to whatever is saying is the name I registered the same as the command I want.
     
Thread Status:
Not open for further replies.

Share This Page