mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-01-06 07:22:15 +00:00
Ensures leftover candidates and pending antags are cleared after finalizing
This commit is contained in:
@@ -186,11 +186,16 @@
|
||||
for(var/datum/mind/player in pending_antagonists)
|
||||
pending_antagonists -= player
|
||||
add_antagonist(player,0,0,1)
|
||||
|
||||
reset_antag_selection()
|
||||
|
||||
//Resets all pending_antagonists, clearing their special_role (and assigned_role if ANTAG_OVERRIDE_JOB is set)
|
||||
/datum/antagonist/proc/reset()
|
||||
//Resets the antag selection, clearing all pending_antagonists and their special_role
|
||||
//(and assigned_role if ANTAG_OVERRIDE_JOB is set) as well as clearing the candidate list.
|
||||
//Existing antagonists are left untouched.
|
||||
/datum/antagonist/proc/reset_antag_selection()
|
||||
for(var/datum/mind/player in pending_antagonists)
|
||||
if(flags & ANTAG_OVERRIDE_JOB)
|
||||
player.assigned_role = null
|
||||
player.special_role = null
|
||||
pending_antagonists.Cut()
|
||||
candidates.Cut()
|
||||
|
||||
@@ -305,7 +305,7 @@ var/global/list/additional_antag_types = list()
|
||||
|
||||
/datum/game_mode/proc/fail_setup()
|
||||
for(var/datum/antagonist/antag in antag_templates)
|
||||
antag.reset()
|
||||
antag.reset_antag_selection()
|
||||
|
||||
/datum/game_mode/proc/announce_ert_disabled()
|
||||
if(!ert_disabled)
|
||||
|
||||
@@ -289,7 +289,7 @@
|
||||
|
||||
|
||||
proc/AttemptLateSpawn(rank,var/spawning_at)
|
||||
if (src != usr)
|
||||
if(src != usr)
|
||||
return 0
|
||||
if(!ticker || ticker.current_state != GAME_STATE_PLAYING)
|
||||
usr << "\red The round is either not ready, or has already finished..."
|
||||
|
||||
Reference in New Issue
Block a user