Need help with shop

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.

KJK

Member
Jul 8, 2021
2
0
1
22
Cant figure out how to make it so they cant buy it if they dont have enough $


command /petshop:
trigger:
open chest with 3 row named "Pet Shop" to player
wait 1 tick
format slot 0 of player with light gray glass named "ignore" with lore "ignore" to close then run "ingore test"
format slot 10 of player with sheep spawn egg named "&a&lCommon Pet Egg" with lore "&7Price: &a10,000" to close then run [make console execute command "/ep giveegg %player% COMMON"]->[make console execute command "/eco take %player% 10000"]

using vault and skquery
 
I couldn't figure out skript-gui and Tuske is broken af on 1.17
skript-gui is basically the same syntax as Tuske and works in 1.17
Code:
command /petshop:
    trigger:
        create a gui with virtual chest inventory with 3 rows named named "Pet Shop"
          make gui 10 with sheep spawn egg named "&a&lCommon Pet Egg" with lore "&7Price: &a10,000":
              if balance of player >= 10000:
                  remove 10000 from balance of player
                  make console execute command "/ep giveegg %player% COMMON"
        open last gui to player
 
Status
Not open for further replies.