i checked the forum, i think my best option is this code
but i can't decipher it exactly.
what data is kept in {kills::*}?
i'm making a simple game, every time a player wins he gains one point, and he appears on a leaderboard, or at least this is what i want to do.
what do i add to {kills::*}? another variable named {%player%.win} that stores the number of wins?
i didn't think it would be that hard, could someone give me a hand figuring this out?
Code:
command /ranking:
trigger:
loop {Kills::*}:
add 1 to {_size}
if {_low.to.high.list::%loop-value%} is not set:
set {_low.to.high.list::%loop-value%} to loop-index
else:
set {_n} to 0
loop {_size} times:
set {_n} to {_n}+1
{_low.to.high.list::%loop-value-1%.%{_n}%} is not set
set {_low.to.high.list::%loop-value-1%.%{_n}%} to loop-index
stop loop
wait 1 tick
set {_n} to size of {_low.to.high.list::*}
loop {_low.to.high.list::*}:
set {_high.to.low.list::%{_n}%} to loop-value
set {_n} to {_n}-1
wait 1 tick
set {_i} to 0
#THIS IS THE MESSAGE WITH TOP KILLS
send "&7&m-----------&8< &6Top10 &8>&7&m-----------"
loop {_high.to.low.list::*}:
add 1 to {_topnumber}
set {_player} to "%loop-value%" parsed as offlineplayer
send "&7%{_topnumber}% - &c%{_player}% &8» &7%{Kills::%loop-value%}% Kills"
add 1 to {_i}
if {_topnumber} > 10: #this is top 10 you can change it
stop
send "&7&m------------------------------"
but i can't decipher it exactly.
what data is kept in {kills::*}?
i'm making a simple game, every time a player wins he gains one point, and he appears on a leaderboard, or at least this is what i want to do.
what do i add to {kills::*}? another variable named {%player%.win} that stores the number of wins?
i didn't think it would be that hard, could someone give me a hand figuring this out?