Revert "12/21 modernizations from TG live"
This commit is contained in:
@@ -58,20 +58,15 @@ var/datum/subsystem/vote/SSvote
|
||||
greatest_votes = votes
|
||||
//default-vote for everyone who didn't vote
|
||||
if(!config.vote_no_default && choices.len)
|
||||
var/list/non_voters = directory.Copy()
|
||||
non_voters -= voted
|
||||
for (var/non_voter_ckey in non_voters)
|
||||
var/client/C = non_voters[non_voter_ckey]
|
||||
if (!C || C.is_afk())
|
||||
non_voters -= non_voter_ckey
|
||||
if(non_voters.len > 0)
|
||||
var/non_voters = (clients.len - total_votes)
|
||||
if(non_voters > 0)
|
||||
if(mode == "restart")
|
||||
choices["Continue Playing"] += non_voters.len
|
||||
choices["Continue Playing"] += non_voters
|
||||
if(choices["Continue Playing"] >= greatest_votes)
|
||||
greatest_votes = choices["Continue Playing"]
|
||||
else if(mode == "gamemode")
|
||||
if(master_mode in choices)
|
||||
choices[master_mode] += non_voters.len
|
||||
choices[master_mode] += non_voters
|
||||
if(choices[master_mode] >= greatest_votes)
|
||||
greatest_votes = choices[master_mode]
|
||||
//get all options with that many votes and return them in a list
|
||||
@@ -126,6 +121,13 @@ var/datum/subsystem/vote/SSvote
|
||||
restart = 1
|
||||
else
|
||||
master_mode = .
|
||||
if("roundtype")
|
||||
if(ticker && ticker.mode)
|
||||
message_admins("A vote has tried to change the gamemode, but the game has already started. Aborting.")
|
||||
else if(master_mode != .)
|
||||
world.save_mode(.)
|
||||
master_mode = .
|
||||
world << "<span class='adminnotice'><b>The mode is now: [master_mode]</b></span>"
|
||||
if(restart)
|
||||
var/active_admins = 0
|
||||
for(var/client/C in admins)
|
||||
@@ -174,6 +176,9 @@ var/datum/subsystem/vote/SSvote
|
||||
choices.Add("Restart Round","Continue Playing")
|
||||
if("gamemode")
|
||||
choices.Add(config.votable_modes)
|
||||
if("roundtype")
|
||||
choices.Add("secret")
|
||||
choices.Add("extended")
|
||||
if("custom")
|
||||
question = stripped_input(usr,"What is the vote for?")
|
||||
if(!question)
|
||||
|
||||
Reference in New Issue
Block a user