From 91a94e46af7da827eab226d38c20e7730f4e2009 Mon Sep 17 00:00:00 2001 From: skoglol <33292112+kriskog@users.noreply.github.com> Date: Sun, 22 Dec 2019 21:29:25 +0100 Subject: [PATCH] Mindread now reads the correct true name (#48301) * Mindread now reads the correct true name * Fixes dna.real_name --- code/datums/dna.dm | 2 +- code/datums/mutations/antenna.dm | 5 ++--- code/game/machinery/cloning.dm | 8 ++++---- 3 files changed, 7 insertions(+), 8 deletions(-) diff --git a/code/datums/dna.dm b/code/datums/dna.dm index 9c6954ce46f..6095e70fa14 100644 --- a/code/datums/dna.dm +++ b/code/datums/dna.dm @@ -338,7 +338,7 @@ set_species(newrace, icon_update=0) if(newreal_name) - real_name = newreal_name + dna.real_name = newreal_name dna.generate_unique_enzymes() if(newblood_type) diff --git a/code/datums/mutations/antenna.dm b/code/datums/mutations/antenna.dm index a99d8e0f36d..d16e9b9cbb0 100644 --- a/code/datums/mutations/antenna.dm +++ b/code/datums/mutations/antenna.dm @@ -92,9 +92,8 @@ if(iscarbon(M)) var/mob/living/carbon/human/H = M to_chat(user, "You find that their intent is to [H.a_intent]...") - var/datum/dna/the_dna = H.has_dna() - if(the_dna) - to_chat(user, "You uncover that [H.p_their()] true identity is [the_dna.real_name].") + if(H.mind) + to_chat(user, "You uncover that [H.p_their()] true identity is [H.mind.name].") else to_chat(user, "You can't find a mind to read inside of [M]!") diff --git a/code/game/machinery/cloning.dm b/code/game/machinery/cloning.dm index 0069f03294a..e07efc18200 100644 --- a/code/game/machinery/cloning.dm +++ b/code/game/machinery/cloning.dm @@ -185,6 +185,10 @@ var/mob/living/carbon/human/H = new /mob/living/carbon/human(src) + if(!clonename) //to prevent null names + clonename = "clone ([rand(1,999)])" + H.real_name = clonename + H.hardset_dna(ui, mutation_index, H.real_name, blood_type, mrace, features) if(!HAS_TRAIT(H, TRAIT_RADIMMUNE))//dont apply mutations if the species is Mutation proof. @@ -201,10 +205,6 @@ H.silent = 20 //Prevents an extreme edge case where clones could speak if they said something at exactly the right moment. occupant = H - if(!clonename) //to prevent null names - clonename = "clone ([rand(1,999)])" - H.real_name = clonename - icon_state = "pod_1" //Get the clone body ready maim_clone(H)