Trouble with Skript GUI 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.

kalib

New Member
Jan 6, 2019
6
0
0
23
command /openshop:
#No perms
trigger:
open chest with 3 rows named "&8Shop" to player
format slot 12 of player with grass named "&2Blocks" to close
on right click with chest
open chest with 1 rows named "&2Blocks" to player
format slot 1 of player with dirt named "&2Dirt" to close then run [execute player command "give %player% dirt"]

I'm having a lot of trouble with this. I'm trying to make a shop plugin but I'm new so I want to learn. Can someone please check it out and fix it. That would be greatly appreciated. <3
 
Heres the way I coded GUI shops when I first began as its easy to understand and repeat. First, install TuSKe (https://www.spigotmc.org/resources/tuske.25136/). Second, try this code
code_language.skript:
command /openshop:
    trigger:
        open virtual chest with 3 rows named "&8Shop" to player
        format gui slot 12 of player with grass named "&2Blocks" to run player command "/openshopblocks"
command /openshopblocks:
    trigger:
        open virtual chest with 1 rows named "&2Blocks" to player
        format gui slot 1 of player with dirt named "&2Dirt" to run console command "give %player% dirt"
 
Heres the way I coded GUI shops when I first began as its easy to understand and repeat. First, install TuSKe (https://www.spigotmc.org/resources/tuske.25136/). Second, try this code
code_language.skript:
command /openshop:
    trigger:
        open virtual chest with 3 rows named "&8Shop" to player
        format gui slot 12 of player with grass named "&2Blocks" to run player command "/openshopblocks"
command /openshopblocks:
    trigger:
        open virtual chest with 1 rows named "&2Blocks" to player
        format gui slot 1 of player with dirt named "&2Dirt" to run console command "give %player% dirt"
Ok Thanks so much. If I need more help can I count on you? lol
[doublepost=1546800267,1546799505][/doublepost]@wesnoah3 I may be having some problems right now, but I am working on fixing them. So what is TuSKe supposed to do?
[doublepost=1546800521][/doublepost]command /openshop:
trigger:
open virtual chest with 3 rows named "&8Shop" to player
format gui slot 12 of player with grass named "&2Blocks" to run player command "/openshopblocks"
command /openshopblocks:
trigger:
open virtual chest with 1 rows named "&2Blocks" to player
format gui slot 1 of player with dirt named "&2Dirt" to run console command "give %player% dirt"
format gui slot 2 of player with Grass_Block named "&2Grass Block" to run console command "give %player% Grass_Block"
format gui slot 3 with cobblestone named "&2Cobblestone" to run console command "give %player% cobblestone"
format gui slot 3 with stone named "&2Stone" to run console command "give %player% Stone"
Here is my error message. I do have TuSKe. Please help.

[13:44:56] [Server thread/ERROR]: [Skript] indentation error: expected 8 spaces, but found 2 tabs (My Own.sk, line 9: format gui slot 2 of player with Grass_Block named "&2Grass Block" to run console command "give %player% Grass_Block"')
severe.png

[13:44:56] [Server thread/ERROR]: [Skript] indentation error: expected 8 spaces, but found 2 tabs (My Own.sk, line 10: format gui slot 3 with cobblestone named "&2Cobblestone" to run console command "give %player% cobblestone"')
severe.png

[13:44:56] [Server thread/ERROR]: [Skript] indentation error: expected 8 spaces, but found 2 tabs (My Own.sk, line 11: format gui slot 3 with stone named "&2Stone" to run console command "give %player% Stone"')
[13:44:56] [Skript update thread/INFO]: [Skript] You're currently running the latest stable version of Skript.
severe.png

[13:44:56] [Server thread/ERROR]: [Skript] 'virtual chest with 3 rows named "&8Shop"' is not an entity type (My Own.sk, line 3: open virtual chest with 3 rows named "&8Shop" to player')
severe.png

[13:44:57] [Server thread/ERROR]: [Skript] '"&2Blocks" to run player' is not a text (My Own.sk, line 4: format gui slot 12 of player with grass named "&2Blocks" to run player command "/openshopblocks"')
severe.png

[13:44:57] [Server thread/ERROR]: [Skript] 'virtual chest with 1 rows named "&2Blocks"' is not an entity type (My Own.sk, line 7: open virtual chest with 1 rows named "&2Blocks" to player')
severe.png

[13:44:57] [Server thread/ERROR]: [Skript] '"&2Dirt" to run console' is not a text (My Own.sk, line 8: format gui slot 1 of player with dirt named "&2Dirt" to run console command "give %player% dirt"')

[doublepost=1546801065][/doublepost]
code_language.skript:
command /openshop:
    trigger:
        open virtual chest with 3 rows named "&8Shop" to player
        format gui slot 12 of player with grass named "&2Blocks" to run command "/openshopblocks"
command /openshopblocks:
    trigger:
        open chest with 1 rows named "&2Blocks" to player
        format gui slot 1 of player with dirt named "&2Dirt" to run command "give %player% dirt"
        format gui slot 2 of player with Grass_Block named "&2Grass Block" to run command "give %player% Grass_Block"
        format gui slot 3 with stone named "&2Stone" to run command "give %player% Stone"
[doublepost=1546801370][/doublepost]The only problem i am having as of now is the command. It says "&2Blocks" to run player command" is not a text
 
code_language.skript:
command /openshop:
    trigger:
        open virtual chest with 3 rows named "&8Shop" to player
        format gui slot 12 of player with grass named "&2Blocks" to run command "/openshopblocks"
command /openshopblocks:
    trigger:
        open chest with 1 rows named "&2Blocks" to player
        format gui slot 1 of player with dirt named "&2Dirt" to run command "give %player% dirt"
        format gui slot 2 of player with Grass_Block named "&2Grass Block" to run command "give %player% Grass_Block"
        format gui slot 3 with stone named "&2Stone" to run command "give %player% Stone"
Here is my current code that i am having troubles with
[doublepost=1546802392,1546802222][/doublepost]@wesnoah3 can u try within your server to look at current issues
 
Please note I deleted the spaces and replaced them with tabs as its highly recommended to do so!
code_language.skript:
command /openshop:
    trigger:
        open virtual chest with 3 rows named "&8Shop" to player
        format gui slot 12 of player with grass named "&2Blocks" to run player command "/openshopblocks"
command /openshopblocks:
    trigger:
        open virtual chest with 1 rows named "&2Blocks" to player
        format gui slot 1 of player with dirt named "&2Dirt" to run player command "give %player% dirt"
        format gui slot 2 of player with grass block named "&2Grass Block" to run console command "give %player% grass block"
        format gui slot 3 of player with stone named "&2Stone" to run player command "give %player% Stone"
[doublepost=1546802815,1546802699][/doublepost]Your biggest mistakes were forgetting the "virtual" between open and chest. Also forgetting "player" or "console" between run and command
 
  • Like
Reactions: kalib
@wesnoah3 try within your server whenever I did that, it said that isnt a command
[doublepost=1546802956,1546802914][/doublepost]@wesnoah3 add my discord and we can talk in there
[doublepost=1546803184][/doublepost][14:31:59] [Server thread/ERROR]: [Skript] 'virtual chest with 3 rows named "&8Shop"' is not an entity type (My Own.sk, line 3: open virtual chest with 3 rows named "&8Shop" to player')
[14:31:59] [Skript update thread/INFO]: [Skript][m You're currently running the latest stable version of Skript.[m
severe.png

[14:32:00] [Server thread/ERROR]: [Skript] '"&2Blocks" to run player' is not a text (My Own.sk, line 4: format gui slot 12 of player with grass named "&2Blocks" to run player command "/openshopblocks"')
severe.png

[14:32:00] [Server thread/ERROR]: [Skript] 'virtual chest with 1 rows named "&2Blocks"' is not an entity type (My Own.sk, line 7: open virtual chest with 1 rows named "&2Blocks" to player')
severe.png

[14:32:00] [Server thread/ERROR]: [Skript] '"&2Dirt" to run player' is not a text (My Own.sk, line 8: format gui slot 1 of player with dirt named "&2Dirt" to run player command "give %player% dirt"')
severe.png

[14:32:00] [Server thread/ERROR]: [Skript] '"&2Grass Block" to run console' is not a text (My Own.sk, line 9: format gui slot 2 of player with grass block named "&2Grass Block" to run console command "give %player% grass block"')
severe.png

[14:32:00] [Server thread/ERROR]: [Skript] '"&2Stone" to run player' is not a text (My Own.sk, line 10: format gui slot 3 of player with stone named "&2Stone" to run player command "give %player% Stone"')
 
Status
Not open for further replies.