1. 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!

  2. LOOKING FOR A VERSION OF SKRIPT?

    You can always check out our Wiki for downloads and any other information about Skript!

Dismiss Notice
This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Tuske GUI Update

Discussion in 'Skript' started by Nils Møller, Jan 25, 2021.

Thread Status:
Not open for further replies.
  1. Nils Møller

    Nils Møller Member

    Joined:
    Jan 22, 2021
    Messages:
    3
    Likes Received:
    0
    Code (Text):
    1. format gui slot 10 of player with 5 of red wool named "&4&l-5 Diamanter" with lore "" to run:
    2.             remove 5 from {_antal}
    3.             send "%{_antal}%"
    4.         format gui slot 11 of player with 1 of red wool named "&4&l-1 Diamant" with lore "" to run:
    5.             remove 1 from {_antal}
    6.             send "%{_antal}%"
    7.         format gui slot 13 of player with {_antal} of diamonds named "&3Spil om &e&l%{_antal}% Diamanter" with lore "" to run:
    8.             send "%{_antal}%"
    9.         format gui slot 15 of player with 1 of green wool named "&a&l+1 Diamanter" with lore "" to run:
    10.             add 1 to {_antal}
    11.             send "%{_antal}%"
    12.         format gui slot 16 of player with 5 of green wool named "&a&l+5 Diamanter" with lore "" to run:
    13.             add 5 to {_antal}
    14.             send "%{_antal}%"
    15.         format gui slot 17 of player with 10 of green wool named "&a&l+10 Diamant" with lore "" to run:
    16.             add 10 to {_antal}
    17.             send "%{_antal}%"
    18.  
    Can someone explain to my why {_antal} doesn't change when I press the item
     
  2. Killerz1243

    Killerz1243 Active Member

    Joined:
    Oct 31, 2019
    Messages:
    78
    Likes Received:
    7
    {_antal} is a local variable, it gets deleted after the trigger ends
     
Thread Status:
Not open for further replies.

Share This Page

Loading...