Fixes a rare bug where you can spawn as IPC cling (#17133)

This commit is contained in:
AffectedArc07
2021-11-18 12:18:39 +01:00
committed by GitHub
parent c3877bba40
commit 3a77df7518
2 changed files with 5 additions and 2 deletions
-2
View File
@@ -287,8 +287,6 @@ SUBSYSTEM_DEF(jobs)
for(var/mob/new_player/player in GLOB.player_list)
if(player.ready && player.has_valid_preferences() && player.mind && !player.mind.assigned_role)
unassigned += player
if(player.client.prefs.toggles2 & PREFTOGGLE_2_RANDOMSLOT)
player.client.prefs.load_random_character_slot(player.client)
Debug("DO, Len: [unassigned.len]")
if(unassigned.len == 0)
+5
View File
@@ -180,6 +180,11 @@ SUBSYSTEM_DEF(ticker)
Master.SetRunLevel(RUNLEVEL_LOBBY)
return FALSE
// Randomise characters now. This avoids rare cases where a human is set as a changeling then they randomise to an IPC
for(var/mob/new_player/player in GLOB.player_list)
if(player.client.prefs.toggles2 & PREFTOGGLE_2_RANDOMSLOT)
player.client.prefs.load_random_character_slot(player.client)
//Configure mode and assign player to special mode stuff
mode.pre_pre_setup()
var/can_continue