Is it possible to make a plugin execute player commands

Discussion in 'Spigot Plugin Development' started by tarpers, May 12, 2015.

  1. I want to make a plugin which is pretty much a GUI and in the gui when you click different items it executes a command for the player. Is it possible to do this?
     
  2. You can answer most of these questions by glancing over the api https://hub.spigotmc.org/javadocs/spigot/


    Method under Player object:
    • performCommand
      boolean performCommand(String command)
      Makes the player perform the given command
      Parameters:
      command - Command to perform
      Returns:
      true if the command was successful, otherwise false
     
  3. Would anybody be able to make me a plugin which puts an item in players inventory on death and on spawn so they can't drop the specific item which when you right click the item it opens a GUI menu and in the menu it will execute commands for players eg. in the gui it has a wardrobe with the item of a leather cap so when you click it this will execute the command /wardrobe for the player?
     
  4. http://www.spigotmc.org/search/12203305/?q=wardrobe&t=resource_update&o=relevance
    boom.

    I believe this one is very popular though: http://www.spigotmc.org/resources/wardrobegui.2473/
     
  5. Not what I asked i asked for somebody to develop me a plugin which will open a gui menu when right clicking a item in a players inventory. What is in the Gui menu would execute commands as the player for example one of the items in the gui menu executes /wardrobe when it is clicked. I want a few things in there like pets etc which I already have plugins for. The plugin would have to also keep that specific item on spawn and join but made so it cannot by moved from the inventory. I am willing to pay!
     
  6. clip

    Benefactor

    You need to post in the correct forum if you are looking to hire a developer. The Spigot plugin development forum is a place to seek help or discuss plugin development / java related questions.
     
  7. You can use ChestCommands for the GUI part, not sure about the other stuff.
     
    • Informative Informative x 1
  8. Using this plugin does not allow commands on the chests to open a new GUI. I want a plugin which can have a GUI with items in which when you click them it sends a command to open a new GUI. Would i need a custom plugin for this??
     
    • Creative Creative x 1
  9. No I figured it out I made my own small plugin works fine thanks for all the help :)