Sidebar Help

  • 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.
Feb 8, 2022
20
0
1
15
can someone please help me with this skript I made for my modded survival server?
Code:
on first join:
    {money::%player%} = 0
    {playerkills::%player%} = 0

on right click:
    player is sneaking:
        event-item is emerald named "&2Money":
            add 1 to {money::%player%}

every 2 seconds:
    loop all-players:
        wipe loop-player's sidebar
        set name of sidebar of loop-player to "&c&lMaximus24"
        set score "&4Username &6>> &c%player%" in sidebar of loop-player to 1
        set score "&4Balance &6>> &c${money::%player%}" in sidebar of loop-player to 2
        set score "&4Kills &6>> &c{playerkills::%player%}" in sidebar of loop-player to 3

on death:
    victim is a player:
        attacker is a player:
            add 1 to {playerkills::%attacker%}

on load:
    register new shapeless recipe for emerald named "&2Money" with lore "&dShift + Right Click to add to &cBalance" using emerald, air, air, air, air, air, air, air, air
heres a picture of the error
 

Attachments

  • 6721E5FD-7E60-41AE-ABBA-64D002754B98.jpeg
    6721E5FD-7E60-41AE-ABBA-64D002754B98.jpeg
    135.7 KB · Views: 75
Last edited:
You cant set the "name" of the sidebar, perhaps you want to set the header instead?
To help you with this issue I need to know what plugin you are using to control scoreboards.
 
can someone please help me with this skript I made for my modded survival server?
Code:
on first join:
    {money::%player%} = 0
    {playerkills::%player%} = 0

on right click:
    player is sneaking:
        event-item is emerald named "&2Money":
            add 1 to {money::%player%}

every 2 seconds:
    loop all-players:
        wipe loop-player's sidebar
        set name of sidebar of loop-player to "&c&lMaximus24"
        set score "&4Username &6>> &c%player%" in sidebar of loop-player to 1
        set score "&4Balance &6>> &c${money::%player%}" in sidebar of loop-player to 2
        set score "&4Kills &6>> &c{playerkills::%player%}" in sidebar of loop-player to 3

on death:
    victim is a player:
        attacker is a player:
            add 1 to {playerkills::%attacker%}

on load:
    register new shapeless recipe for emerald named "&2Money" with lore "&dShift + Right Click to add to &cBalance" using emerald, air, air, air, air, air, air, air, air
heres a picture of the error

loop all-players is spelt wrong in line 11, should be loop all players.
 
Status
Not open for further replies.