853620298491042_ Posted December 13, 2020 Share Posted December 13, 2020 Hello, I recently started making a shop skript, and I wanted to ask if this is a good way creating the shop skript? Can I make it more compact or something? (Its fully working, but its kinda long.." ... wait 1 tick open virtual chest inventory with size 6 named "&3Slabs &7& &3Stairs" to player wait 1 tick format gui slot 0 of player with 16 oak slabs named "&c16 Oak slabs" with lore " " and "&a25$" and " " to run: if {bal::%player's uuid%} < 25: send "{@prefix} &cNot enough &a$$$&c!" else if {bal::%player's uuid%} >= 25: remove 25 from {bal::%player's uuid%} give player 16 oak slabs send "{@prefix} &bBought &c16 oak slabs&b. Current balance: &c%{bal::%player's uuid%}%&b$" Link to comment Share on other sites More sharing options...
_Tarna_ Posted December 13, 2020 Share Posted December 13, 2020 You can use functions to make it more compact. Here is a tutorial that you can look at to see how functions work. https://skripthub.net/tutorials/9 Discord - tarna256 In-game name - _Tarna_ Website - https://tarna.dev Paste Site: https://paste.tarna.dev --------------------------------------------------------- [VIP] - 7/27/2020 Community Support - 7/8/20 | 11/3/20 Helper - 11/3/20 - 2/21/21 Moderator - 2/21/21 - 5/17/21 - 5/17/21 - now Moderator - 12/20/22 - now --------------------------------------------------------- Link to comment Share on other sites More sharing options...
853620298491042_ Posted December 13, 2020 Author Share Posted December 13, 2020 I've never done functions, so this will be harder for me and I already thought about that. But thanks for sending me the tutorial! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now