diff --git a/code/game/gamemodes/objective.dm b/code/game/gamemodes/objective.dm index e2ecd53358ef..a12e8e885425 100644 --- a/code/game/gamemodes/objective.dm +++ b/code/game/gamemodes/objective.dm @@ -49,6 +49,7 @@ GLOBAL_LIST_INIT(potential_theft_objectives, (subtypesof(/datum/theft_objective) owner = null target = null team = null + holder = null return ..() /datum/objective/proc/check_completion() diff --git a/code/game/gamemodes/objective_holder.dm b/code/game/gamemodes/objective_holder.dm index 9d33db630dc8..2b65e1eb7b47 100644 --- a/code/game/gamemodes/objective_holder.dm +++ b/code/game/gamemodes/objective_holder.dm @@ -20,6 +20,9 @@ /datum/objective_holder/Destroy(force, ...) clear() + objective_owner = null + QDEL_NULL(on_add_callback) + QDEL_NULL(on_remove_callback) return ..() /** diff --git a/code/modules/antagonists/traitor/datum_mindslave.dm b/code/modules/antagonists/traitor/datum_mindslave.dm index 9b219dd57959..e511df1ad0bd 100644 --- a/code/modules/antagonists/traitor/datum_mindslave.dm +++ b/code/modules/antagonists/traitor/datum_mindslave.dm @@ -27,8 +27,11 @@ if(owner.som) owner.som.serv -= owner owner.som.leave_serv_hud(owner) - // Remove the reference but turn this into a string so it can still be used in /datum/antagonist/mindslave/farewell(). - master = "[master.current.real_name]" + // Remove the master reference but turn this into a string so it can still be used in /datum/antagonist/mindslave/farewell(). + if(master.current) + master = "[master.current.real_name]" + else + master = "[master]" return ..() /datum/antagonist/mindslave/on_gain()