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

Can't Make Tablist Update Using SkRayFall

Discussion in 'Skript' started by Lightlyrow, Jan 28, 2017.

Thread Status:
Not open for further replies.
  1. Lightlyrow

    Lightlyrow Member

    Joined:
    Jan 27, 2017
    Messages:
    2
    Likes Received:
    0
    Skript Version: Skript 2.2-Fixes-VBb
    Skript Author: Njol
    Minecraft Version: 1.8.8
    ---
    Full Code:
    _Note: If the code is too large, feel free to use a pasting website (Pastebin or hastebin)_
    _Note: If a variable is being set in another script, but not shown, please explain how they are being set_

    `
    Code (Skript):
    1.  
    2. function updateHealth(p: player):
    3.     loop all players:
    4.         set tablist score of {_p} to ({_p}'s health*10) for loop-player
    5. on join:
    6.     updateScore(player)
    7. every 20 ticks:
    8.     loop all players:
    9.         updateHealth(loop-player)
    `

    Errors on Reload:

    `
    None
    `

    Console Errors:

    `
    None
    `

    Other Useful Info:

    Addons using (including versions):
    SkRayFall 1.9.7

    Troubleshooting:

    Have you tried searching the docs? Yes
    Have you tried searching the Forums? Yes
    What other methods have you tried to fix it? I think what is happening is that it's not updating the scoreboard, because when I relog with different health it updates it once when I join, but not any other time. I've tried doing
    Code (Skript):
    1. wipe {_p}'s score from tablist
    but it doesn't even recognize that as a effect.
     
    #1 Lightlyrow, Jan 28, 2017
    Last edited: Jan 28, 2017
  2. ShaneBee

    Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,106
    Likes Received:
    150
    Try This:
    Code (Skript):
    1. function updateHealth(p: player):
    2.     loop all players:
    3.         set tablist score of {_p} to ({_p}'s health*10) for loop-player
    4. on join:
    5.     updateScore(player)
    6. every 1.5 ticks:
    7.     loop all players:
    8.         updateHealth(loop-player)
    9. //OR:
    10.  
    11. on damage of player:
    12.         updateHealth(victim)
    13.         updateHealth(attacker)
     
  3. ShaneBee

    Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,106
    Likes Received:
    150
    That didn't change anything :/
    Still no errors
     
  4. ShaneBee

    Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,106
    Likes Received:
    150
    Is your tablist score showing 0 no matter your code? I seem to have run into that issue myself, the difference is I'm on 1.11.2 with the latest versions of addons and whatnot, what is weird is that a few days ago it was working fine for me then suddenly it stopped working, I'm thinking it might be another addon interfering but I've been a little too lazy to test for that since it can be quite annoying
     
Thread Status:
Not open for further replies.
Loading...