Command Args In Different Classes

Discussion in 'Plugin Development' started by Epicballzy, May 10, 2014.

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

    Epicballzy

    Is it possible to have command arguments in different classes? Say your command is /hello, could you make an argument separated from that command into a different class and make the argument "you". So in one class, the command is /hello then in the other class, the argument is you?

    Sorry if I go you confused. I sort of typing fast and not re-reading what I'm typing.
     
  2. Offline

    oaschi

    Code:
    public class HelloCommand implements CommandExecutor{
        public boolean onCommand(...){
            if(args.length > 0 && args[0].equals("you")){
                new HelloYouCommand();
            }
            return true;
        }
    }
    something like that?
     
  3. Offline

    xTigerRebornx

  4. Offline

    Epicballzy

Thread Status:
Not open for further replies.

Share This Page