Multiple Arguments Need In Bukkit.dispatchCommand();

Discussion in 'Plugin Development' started by thatdubstepgamer, Dec 22, 2013.

?

Please Help!

  1. Impossible

    0 vote(s)
    0.0%
  2. Help Please

    1 vote(s)
    100.0%
Thread Status:
Not open for further replies.
  1. Hello I need help I'm trying to add multiple arguments I have everything setup like the commands to activate it but when I run it this does not work please help.

    Code:java
    1. Bukkit.dispatchCommand(sender, "eco" + args[0].equals("give" + args[1].equals(player.getName() + args[2].equals("1"))));
     
  2. Offline

    sgavster

    Code:java
    1. String player = args[0];
    2. int amount = Integer.parseInt(args[1]);
    3.  
    4.  
    5. Bukkit.dispatchCommand(Bukkit.getConsoleSender(), "eco give " + player + " " + Integer.toString(amount));


    Should let you do
    /yourcommand <player> <amount>.
     
  3. It dosnt work :'(
     
  4. Offline

    sgavster

  5. Never Mind I fixed it :D
     
Thread Status:
Not open for further replies.

Share This Page