Now "sort" can by evaluated by "sort=random" "sort=nearest" "sort=furthest" "sort=arbitrary". Why not sort by a scoreboard objective? If we can let the entities execute some command by the order of the score, it must be much more convenient!
I think we may need an argument like this: @e[sort=highest{score1}] or @a[sort=lowest{deaths}] where score1 and deaths are names of objectives. Using this method, we can also give a rank of entities chosen according to an objective:
scoreboard players set @a rank 0
execute as @a[sort=lowest{score}] store result score @s rank if entity @a[scores={rank=0}]
Please sign in to leave a comment.
1 Comments