- Supported Minecraft Versions:
- 1.13, 1.14
Shop-Gui-Api is a simple solution to setting up shops. Rather than writing out crazy amounts of lines, you simply just need to write 1 line per shop item in your GUI
REQUIRES:
- Skript (Tested with Bensku's fork - 2.3Beta4)
- Skript-Mirror (Tested with 1.0.0)
- Tuske (Tested with TuskePikachuPatch3)
- Vault+Economy (Its a shop after all)
HOW TO INSTALL:
- Just simply throw this in your scripts folder (plugins/Skript/scripts/)
- It needs to load before any script that is using this syntax, which is why I named it starting with an A
SYNTAX:
Let me break this down for you to make this easier to understandCode (Skript):
(set|format) shop slot %number% of %player% (with|to) [%integer% of] %itemtype% [with gui name %-string%] [[and ]with gui lore %-strings%] [[and ]with sell price %-integer%] [[and ]with buy price %-integer%]:
Setting the slot number of the shop in the gui for the playerCode (Skript):
(set|format) shop slot %number% of %player%
This is the amount and item you want in your shop. (Defaults to 1 if left out)Code (Skript):
(with|to) [%integer% of] %itemtype%
The amount won't show up in the gui as that many items, but rather in the lore for sell/buy amount.
You can set the name and lore separately from the actual name and lore of the item. For instance, lets say you put a diamond sword named "SHARPIE" in as your item, well you can give it a different name to show up in your GUI, same goes for the lore.Code (Skript):
[with gui name %-string%] [[and ]with gui lore %-strings%]
Here is where you set the buy and sell price for said item, per item. The API will take care of the rest. If you are selling 10 items for 10 each, you API will automatically calculate for you, resulting in $100Code (Skript):
[[and ]with sell price %-integer%] [[and ]with buy price %-integer%]
PICTURES:
Heres some little pics to show the GUI in action
![]()
![]()
EXAMPLES:
These examples are also included in the script itself, and can be removed. They are just there for reference.
Code (Skript):
command /guitest: permission: gui.api.test trigger: open virtual chest inventory with size 3 named "&3GUI" for player #! Boring old cobble stone set shop slot 1 of player to cobblestone with gui name "&aCOBBLE" with gui lore "&cFancy Cobble" with sell price 10 and with buy price 20 set shop slot 2 of player to 10 of cobblestone with gui name "&aCOBBLE" with gui lore "&cFancy Cobble" with sell price 10 and with buy price 20 #! Custom items set {_sword} to diamond sword of sharpness 10 set name of {_sword} to "&3Super Sharp Sword" set lore of {_sword} to "&aVery sharp" and "&abe careful" set shop slot 3 of player with {_sword} with gui name "&aMystery Sword" with gui lore "&5Never know what you're going to get" with buy price 500 set shop slot 4 of player with diamond pickaxe of efficiency 10 with gui name "&aSuper Fast Pick" with gui lore "&dThis pick will break crap quickly" with buy price 1000 set shop slot 5 of player with diamond pickaxe of fortune 10 with gui name "&aSuper Lucky Pick" with gui lore "&dThis pick will give you so much stuff" with buy price 700 #! Essential stuff but making it loop to save time writing it all out set {_basics::*} to stone, dirt, cobblestone, oak log, white wool and sand set {_slot} to 6 loop {_basics::*}: set {_item} to capitalized "%loop-value%" set shop slot {_slot} of player with loop-value with gui name "&a%{_item}%" with sell price 1 and with buy price 2 add 1 to {_slot}
-
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!
Dismiss Notice
This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

API Shop-Gui-API 1.0.0
A simple 1 line solution to formatting shop GUIs