From 9eb95ff4bc37fbbfdf291ed2e5635b81f6d087c8 Mon Sep 17 00:00:00 2001 From: SatinIsle <98125273+SatinIsle@users.noreply.github.com> Date: Mon, 14 Jul 2025 22:58:26 +0100 Subject: [PATCH] Transformation fixes (#17953) * Transformation fixes Fixes #17943 Fixes #17942 Removed copying of bloodtype from vanity TF procs, as if the user actually has blood it will cause organ failure. Added secondary ears to copy form ability. * Makes hanner not get outed by medical scanners * Preserves bloodtype for resleeving but fixes it for TF --- code/game/machinery/adv_med.dm | 2 +- code/modules/client/preferences.dm | 5 +++-- code/modules/mob/living/carbon/human/human_helpers_vr.dm | 8 ++++++-- .../mob/living/carbon/human/species/species_shapeshift.dm | 4 ++-- .../human/species/station/protean/protean_powers.dm | 4 ++-- code/modules/resleeving/infocore_records.dm | 2 +- code/modules/tgui/modules/appearance_changer.dm | 2 +- 7 files changed, 16 insertions(+), 11 deletions(-) diff --git a/code/game/machinery/adv_med.dm b/code/game/machinery/adv_med.dm index b97e9fcfc6..25502358dd 100644 --- a/code/game/machinery/adv_med.dm +++ b/code/game/machinery/adv_med.dm @@ -186,7 +186,7 @@ occupantData["name"] = H.name occupantData["species"] = H.species.name if(H.custom_species) - if( H.species.name == SPECIES_CUSTOM ) + if( H.species.name == SPECIES_CUSTOM || H.species.name == SPECIES_HANNER ) // Fully custom species occupantData["species"] = "[H.custom_species]" else diff --git a/code/modules/client/preferences.dm b/code/modules/client/preferences.dm index 700da1d510..b04b0d816f 100644 --- a/code/modules/client/preferences.dm +++ b/code/modules/client/preferences.dm @@ -407,7 +407,7 @@ var/list/preferences_datums = list() attempt_vr(user.client?.prefs_vr,"load_vore","") ShowChoices(user) -/datum/preferences/proc/vanity_copy_to(var/mob/living/carbon/human/character, var/copy_name, var/copy_flavour = TRUE, var/copy_ooc_notes = FALSE, var/convert_to_prosthetics = FALSE) +/datum/preferences/proc/vanity_copy_to(var/mob/living/carbon/human/character, var/copy_name, var/copy_flavour = TRUE, var/copy_ooc_notes = FALSE, var/convert_to_prosthetics = FALSE, var/apply_bloodtype = TRUE) //snowflake copy_to, does not copy anything but the vanity things //does not check if the name is the same, do that in any proc that calls this proc /* @@ -453,7 +453,8 @@ var/list/preferences_datums = list() character.grad_style= grad_style character.f_style = f_style character.grad_style= grad_style - character.dna.b_type= b_type + if(apply_bloodtype) + character.dna.b_type= b_type //This actually just straight up kills whoever uses it if the blood types aren't compatible in TF character.synth_color = synth_color var/datum/preference/color/synth_color_color = GLOB.preference_entries[/datum/preference/color/human/synth_color] diff --git a/code/modules/mob/living/carbon/human/human_helpers_vr.dm b/code/modules/mob/living/carbon/human/human_helpers_vr.dm index 7294263e46..d4aff1b320 100644 --- a/code/modules/mob/living/carbon/human/human_helpers_vr.dm +++ b/code/modules/mob/living/carbon/human/human_helpers_vr.dm @@ -119,7 +119,7 @@ var/static/icon/ingame_hud_med_vr = icon('icons/mob/hud_med_vr.dmi') //does not really need to happen, that kinda thing will only happen when putting another person's limb onto your own body return sorted -/mob/living/carbon/human/proc/transform_into_other_human(var/mob/living/carbon/human/character, var/copy_name, var/copy_flavour = TRUE, var/convert_to_prosthetics = FALSE) +/mob/living/carbon/human/proc/transform_into_other_human(var/mob/living/carbon/human/character, var/copy_name, var/copy_flavour = TRUE, var/convert_to_prosthetics = FALSE, var/apply_bloodtype = TRUE) /* name, nickname, flavour, OOC notes gender, sex @@ -161,7 +161,8 @@ var/static/icon/ingame_hud_med_vr = icon('icons/mob/hud_med_vr.dmi') grad_style = character.grad_style f_style = character.f_style grad_style = character.grad_style - dna?.b_type = character.dna ? character.dna.b_type : DEFAULT_BLOOD_TYPE + if(apply_bloodtype) + dna?.b_type = character.dna ? character.dna.b_type : DEFAULT_BLOOD_TYPE //This actually just straight up kills whoever uses it if the blood types aren't compatible on TF synth_color = character.synth_color r_synth = character.r_synth g_synth = character.g_synth @@ -180,6 +181,9 @@ var/static/icon/ingame_hud_med_vr = icon('icons/mob/hud_med_vr.dmi') g_ears3 = character.g_ears3 a_ears = character.a_ears + ear_secondary_style = character.ear_secondary_style + ear_secondary_colors = character.ear_secondary_colors + tail_style = character.tail_style r_tail = character.r_tail b_tail = character.b_tail diff --git a/code/modules/mob/living/carbon/human/species/species_shapeshift.dm b/code/modules/mob/living/carbon/human/species/species_shapeshift.dm index b4bd4743df..c159951592 100644 --- a/code/modules/mob/living/carbon/human/species/species_shapeshift.dm +++ b/code/modules/mob/living/carbon/human/species/species_shapeshift.dm @@ -593,7 +593,7 @@ var/list/wrapped_species_by_ref = list() character.visible_message(span_notify("[character] rapidly contorts and shifts!"), span_danger("You begin to reform.")) if(do_after(character, 40,exclusive = TASK_ALL_EXCLUSIVE)) if(character.client.prefs) //Make sure we didn't d/c - character.client.prefs.vanity_copy_to(src, FALSE, flavour, oocnotes, FALSE) + character.client.prefs.vanity_copy_to(src, FALSE, flavour, oocnotes, FALSE, FALSE) character.visible_message(span_notify("[character] adopts a new form!"), span_danger("You have reformed.")) /mob/living/carbon/human/proc/shapeshifter_copy_body() @@ -658,5 +658,5 @@ var/list/wrapped_species_by_ref = list() to_chat(character, span_warning("You lost your grip on [victim]!")) return if(character.client) //Make sure we didn't d/c - transform_into_other_human(victim, FALSE, flavour, FALSE) + transform_into_other_human(victim, FALSE, flavour, FALSE, FALSE) character.visible_message(span_notify("[character] adopts the form of [victim]!"), span_danger("You have reassembled into [victim].")) diff --git a/code/modules/mob/living/carbon/human/species/station/protean/protean_powers.dm b/code/modules/mob/living/carbon/human/species/station/protean/protean_powers.dm index 0ca4cbf0fd..961ae2b89c 100644 --- a/code/modules/mob/living/carbon/human/species/station/protean/protean_powers.dm +++ b/code/modules/mob/living/carbon/human/species/station/protean/protean_powers.dm @@ -132,7 +132,7 @@ if(do_after(protie, 40,exclusive = TASK_ALL_EXCLUSIVE)) if(protie.client.prefs) //Make sure we didn't d/c var/obj/item/rig/protean/Rig = species?:OurRig - protie.client.prefs.vanity_copy_to(src, FALSE, flavour, oocnotes, TRUE) + protie.client.prefs.vanity_copy_to(src, FALSE, flavour, oocnotes, TRUE, FALSE) species?:OurRig = Rig //Get a reference to our Rig and put it back after reassembling protie.visible_message(span_notify("[protie] adopts a new form!"), span_danger("You have reassembled.")) @@ -201,7 +201,7 @@ return if(protie.client) //Make sure we didn't d/c var/obj/item/rig/protean/Rig = species?:OurRig - transform_into_other_human(victim, FALSE, flavour, TRUE) + transform_into_other_human(victim, FALSE, flavour, TRUE, FALSE) species?:OurRig = Rig //Get a reference to our Rig and put it back after reassembling protie.visible_message(span_notify("[protie] adopts the form of [victim]!"), span_danger("You have reassembled into [victim].")) diff --git a/code/modules/resleeving/infocore_records.dm b/code/modules/resleeving/infocore_records.dm index 12faf38004..4911fba914 100644 --- a/code/modules/resleeving/infocore_records.dm +++ b/code/modules/resleeving/infocore_records.dm @@ -407,7 +407,7 @@ // Update record from vanity copy of slot if needed if(from_save_slot) - H.client.prefs.vanity_copy_to(H,FALSE,TRUE,TRUE,FALSE) + H.client.prefs.vanity_copy_to(H,FALSE,TRUE,TRUE,FALSE,TRUE) for(var/category in H.all_underwear) // No undies H.hide_underwear[category] = TRUE H.update_underwear() diff --git a/code/modules/tgui/modules/appearance_changer.dm b/code/modules/tgui/modules/appearance_changer.dm index 29a0f02637..81a0e32737 100644 --- a/code/modules/tgui/modules/appearance_changer.dm +++ b/code/modules/tgui/modules/appearance_changer.dm @@ -579,7 +579,7 @@ if(can_change(owner, APPEARANCE_ALL_COSMETIC)) if(tgui_alert(owner, "Are you certain you wish to load the currently selected savefile?", "Load Savefile", list("No","Yes")) == "Yes") if(owner && owner.client) //sanity - owner.client.prefs.vanity_copy_to(owner, FALSE, TRUE, FALSE, FALSE) + owner.client.prefs.vanity_copy_to(owner, FALSE, TRUE, FALSE, FALSE, FALSE) return TRUE return TRUE else