Solved Bukkit.dispatchCommand(sender, "eco reset" + player + "0");?

Discussion in 'Plugin Development' started by gaz1812, May 14, 2014.

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

    gaz1812

    Hi,

    I'm currently working on a reset account plugin which will reset the account rank, money, health etc. The only thing I'm having an issue with is the eco reset command. The eco reset command is essentials as that is what we currently use.

    I currently have: Bukkit.dispatchCommand(sender, "eco reset" + player + "0"); however the "player" part is not recognised and therefore does not reset their money... I tried using player.getName() which also didn't work. Any one know how to do this?

    Thanks
     
  2. gaz1812 Is player a thing? What is it? You used player.getName()? Is player a Player variable? Also, let's say player or player.getName() is AdamQpzm the console will try to run the command:

    /eco resetAdamQpzm0

    Which I doubt it what you want.

    You have now reached your support limit! To receive more support, please top-up your balance by inserting more code into the thread!
     
  3. Offline

    gaz1812

    AdamQpzm Nevermind it's fixed just added extra spaces
     
Thread Status:
Not open for further replies.

Share This Page