Signs

  • 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 community!

    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.

TigerPvPzzz

Active Member
Feb 24, 2017
109
2
0
Hey there, I have a 1v1 script. But i wonder how to get the best 3 player's with most wins on 3 different signs, so they update automaticly. - Sorry for bad english
 
If your best player's names are stored to variables you can do it like this:
code_language.skript:
on rightclick on sign:
    line 1 of the clicked block is "[Top Players]":
        set line 2 to "%{player1}%"
        set line 3 to "%{player2}%"
        set line 4 to "%{player3}%"
 
If your best player's names are stored to variables you can do it like this:
code_language.skript:
on rightclick on sign:
    line 1 of the clicked block is "[Top Players]":
        set line 2 to "%{player1}%"
        set line 3 to "%{player2}%"
        set line 4 to "%{player3}%"
They are not, how can i store them in variables?
 
They are not, how can i store them in variables?
it would be an event in your skript where you can determine who those top players are. Or even an "update" command that will evaluate their statistics and set the right players. Without knowing your code I can't give you the right answer but it could go something like this
code_language.skript:
command /update:
    trigger:
        loop all offline players
    #so let's pretend {points} is their skil points or something
            if {skill.%player%} > 50:
                set {player1} to player%}
 
it would be an event in your skript where you can determine who those top players are. Or even an "update" command that will evaluate their statistics and set the right players. Without knowing your code I can't give you the right answer but it could go something like this
code_language.skript:
command /update:
    trigger:
        loop all offline players
    #so let's pretend {points} is their skil points or something
            if {skill.%player%} > 50:
                set {player1} to player%}
That "> than 50:" Can you do/i do, so it will check if its greater than number 2?
 
That "> than 50:" Can you do/i do, so it will check if its greater than number 2?
Yeah that can be any number you like in that slot. that command is essentially checking if the value of that variable {skill.%player%} is greater than a number.
 
Yeah that can be any number you like in that slot. that command is essentially checking if the value of that variable {skill.%player%} is greater than a number.
So i could do:
Code:
if {skill.%loop-player%} > {Skill.%loop-player%}:
or am i an idiot
 
No I think that would definitely work in the right context.:emoji_slight_smile:
 
Oh check this out, this is a top list example from the randomSK addon
https://pastebin.com/EEYVBRYW

this is the documentation pic
db37fbfc49.png
 
Status
Not open for further replies.