I don't look in to Java edition commands too much so I am unaware if they have this already, but would you mind seting up a vote scoreboard type? A player starts setting this up with the typical command:
/scoreboard objectives add <filename> vote <displayname>
Then they add variables that each store a different score under the vote objective:
/scoreboard objectives vote add <filename> <new variable name>
Then the vote command could store multiple variables under one file that can be set, reset, added to, or subtracted from just like a normal scoreboard dummy (adding an option to target all variables in the vote file would be nice for resetting the variable scores after they've been compared):
/scoreboard objectives votevariable <add / subtract / set / reset> <filename> <variablename> <amount>
And when all the votes are in, players can test the value of each variable stored in the vote file to determine which variable is the highest (ties are broken by choosing one of the tied variables at random to be the winner):
/scoreboard objectives testvote <filename>
This would really save time, tickingarea space, and lag for any minigames that let players vote for game modes, maps, match winners, etc.
Please sign in to leave a comment.
0 Comments