Solved giveall Token/Coins

  • 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.

GK_Nico

Member
Jan 6, 2019
31
0
0
32
Good day

How do I get it when a player wins a book in case as soon as he wants to make it on all players should get tokens / coins

I have this code so far


code_language.skript:
    trigger:
        if name of player's tool is "&61'000 &aTokens &8> &cGiveall":
            remove 1 of sunflower named "&61'000 &aTokens &8> &cGiveall" from player                   
            add 1000 to all player {geld.%player%}
            broadcast "&7Jeder Spieler hat &61000 &2Tokens &7bekommen"
            play "LEVEL_UP" to player
 
loop all players, and add the money to loop-player
 
Try:

code_language.skript:
trigger:
    if name of player's tool is "&61'000 &aTokens &8> &cGiveall":
        remove 1 of sunflower named "&61'000 &aTokens &8> &cGiveall" from player
        loop all players:
            add 1000 to {geld.%loop-player%}
        broadcast "&7Jeder Spieler hat &61000 &2Tokens &7bekommen"
        play "LEVEL_UP" to player
 
Status
Not open for further replies.