Cant open a GUI, inside a GUI

Discussion in 'Skript' started by Jonathan_Storm, May 7, 2017.

  1. Hello :)

    I was wondering if you could help me with skript.

    I have this KitGUI, that opens when i run the command /kit. Inside then gui, there is an anvil, that configs the setup. I made the anvil open another GUI, typing this:

    format slot * of player with anvil named "Kit Config" to run [ make player execute command "kitconfig"]

    it did open the kit ConfigGUI, but then when i clicked on something inside the config gui, it didn't executed the command. Then i tried doing this:

    format slot * of player with anvil named "Kit Config" to close then run [ make player execute command "kitconfig"]

    When i did this, it just closed all GUIs and did nothing when i'm clicking on the anvil.
    Thats my problem. I really hope you can help.

    Best Regards:
    Jonathan_Storm
     
  2. this is exactly my problem rn, any help people??
     
  3. You can not close menu if you want just open new menu inside of other menu. I think so.
    Code (Text):
    command /kit:
        trigger:
            open chest with 3 rows named "Kit Selector" to player
            wait 1 tick
            format slot 0 of player with diamond sword named "&aPvP" with lore "&7Here you can select kit" to run [make player execute command "/kitconfig"]
    command /kitconfig:
        trigger:
            open chest with 3 rows named "Kit Config" to player
            wait 1 tick
            format slot 0 of player with diamond sword named "&aPvP" with lore "&7Now you got new menu" to run [make player execute command "/Your command"]
     
  4. i did this, but when you click on the other gui it just closes
     
  5. What add-ons you have ?
     
  6. pirtate sk, sk query, sk, sk, skRayFall.
     
  7. Try to install Umbaska or skellet and randomsk.
     
  8. Use expression in the end of "format slot..." "to close then run ..." instead of "to run"
     
  9. tried it still, no.
     
  10. Wouldn't you need to close the first GUI before you open the second??
     
  11. Use TuSKe GUIs
    You can do that with them.
     
  12. format slot 0 of player with diamond sword named "&aPvP" with lore "&7Here you can select kit" to close then run [make player execute command "/kitconfig
     
  13. Code (Text):
    command /kit:
        trigger:
            wait 4 ticks
            open chest with 3 rows named "Kit Selector" to player
            wait 1 tick
            format slot 0 of player with diamond sword named "&aPvP" with lore "&7Here you can select kit" to close then run [make player execute command "/kitconfig"]
    command /kitconfig:
        trigger:
            wait 4 ticks
            open chest with 3 rows named "Kit Config" to player
            wait 1 tick
            format slot 0 of player with diamond sword named "&aPvP" with lore "&7Now you got new menu" to close then run [make player execute command "/Your command"]
    this should work
     
  14. Yes i ended up doing the same thing (making a delay). It works (even thoug it’s months ago)