Changelings now update their flavor text upon transforming. Updates DNA to include flavor text. (#26094)

* Fixes https://github.com/ParadiseSS13/Paradise/issues/3352

* bleugh
This commit is contained in:
Spaghetti-bit
2024-07-03 03:55:13 +00:00
committed by GitHub
parent 1a3a77d42c
commit 3e46e525da
8 changed files with 32 additions and 15 deletions
@@ -1004,16 +1004,16 @@
dna.real_name = name
return name
/mob/living/carbon/human/proc/change_dna(datum/dna/new_dna, include_species_change = FALSE, keep_flavor_text = FALSE)
/mob/living/carbon/human/proc/change_dna(datum/dna/new_dna, include_species_change = FALSE)
if(include_species_change)
set_species(new_dna.species.type, retain_damage = TRUE, transformation = TRUE, keep_missing_bodyparts = TRUE)
dna = new_dna.Clone()
if(include_species_change) //We have to call this after new_dna.Clone() so that species actions don't get overwritten
dna.species.on_species_gain(src)
real_name = new_dna.real_name
if(dna.flavor_text)
flavor_text = dna.flavor_text
domutcheck(src, MUTCHK_FORCED) //Ensures species that get powers by the species proc handle_dna keep them
if(!keep_flavor_text)
flavor_text = ""
dna.UpdateSE()
dna.UpdateUI()
sync_organ_dna(TRUE)