]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commit
Allow displaying the winning map/gametype on the voting hud 1488/head
authorotta8634 <k9wolf@pm.me>
Wed, 12 Mar 2025 08:05:43 +0000 (16:05 +0800)
committerotta8634 <k9wolf@pm.me>
Sun, 6 Apr 2025 17:05:10 +0000 (01:05 +0800)
commitda84390ce501626311bbb37000b429d6e254c3e7
tree3f42869852622715daf5c7452b63944e153c20f2
parent58ed3f3a01257203f601a60ba1e28e2b75830586
Allow displaying the winning map/gametype on the voting hud

Also renamed g_maplist_votable_nodetail to g_maplist_votable_detail, and added sv_vote_gametype_detail.
When 1, the hud displays the "(2 votes)" text in light blue for all maps in the tied winning place, provided they've received at least one vote.
When 2, the hud displays only which map will win the tie break (randomly chosen by the server) in light blue.
This can help prevent annoying situations where for example 4 players vote for different maps and 1 player votes for a map that the 4 players all don't like, previously there'd be a 20% chance it'd be selected despite the 4 players all disliking it -- now the players will know if it'll be picked or not, if this cvar is set to 2.
This does however remove most of the randomness from the voting, so this is disabled by default (cvars both 1).
Also cleaned up associated code.
qcsrc/client/mapvoting.qc
qcsrc/server/mapvoting.qc
qcsrc/server/mapvoting.qh
xonotic-server.cfg