[MIRROR] Adds SHOULD_NOT_SLEEP to Destroy. Why didn't we do this before. [MDB IGNORE] (#8714)

* Adds SHOULD_NOT_SLEEP to Destroy. Why didn't we do this before. (#61943)

* Adds SHOULD_NOT_SLEEP to Destroy. Why didn't we do this before.

Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
This commit is contained in:
SkyratBot
2021-10-09 15:11:52 +02:00
committed by GitHub
parent d3f9b7720e
commit 95ab2d2efb
11 changed files with 54 additions and 32 deletions
+2 -1
View File
@@ -134,7 +134,8 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new)
if(C.current_ticket)
var/datum/admin_help/T = C.current_ticket
T.AddInteraction("Client disconnected.")
SSblackbox.LogAhelp(T, "Disconnected", "Client disconnected", C.ckey)
//Gotta async this cause clients only logout on destroy, and sleeping in destroy is disgusting
INVOKE_ASYNC(SSblackbox, /datum/controller/subsystem/blackbox/proc/LogAhelp, T, "Disconnected", "Client disconnected", C.ckey)
T.initiator = null
//Get a ticket given a ckey
+1 -1
View File
@@ -113,7 +113,7 @@ GLOBAL_DATUM(current_anonymous_theme, /datum/anonymous_theme)
continue
var/old_name = player.real_name //before restoration
if(issilicon(player))
player.apply_pref_name("[isAI(player) ? /datum/preference/name/ai : /datum/preference/name/cyborg]", player.client)
INVOKE_ASYNC(player, /mob/proc/apply_pref_name, "[isAI(player) ? /datum/preference/name/ai : /datum/preference/name/cyborg]", player.client)
else
player.client.prefs.apply_prefs_to(player) // This is not sound logic, as the prefs may have changed since then.
player.fully_replace_character_name(old_name, player.real_name) //this changes IDs and PDAs and whatnot