From 95e3a2b2668b187b92aab7bc05d565b29eb64d98 Mon Sep 17 00:00:00 2001 From: Poojawa Date: Thu, 26 Apr 2018 07:14:42 -0500 Subject: [PATCH 1/4] Fixes shitcode --- .../carbon/human/species_types/jellypeople.dm | 38 +++++++++++++++---- 1 file changed, 30 insertions(+), 8 deletions(-) diff --git a/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm b/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm index a13b4ae852..7464d344b3 100644 --- a/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm +++ b/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm @@ -94,23 +94,45 @@ organ.forceMove(get_turf(H)) qdel(organ) H.update_body() + else if (select_alteration == "Ears") + var/list/snowflake_ears_list = list("Normal" = null) + for(var/path in GLOB.mam_ears_list) + var/datum/sprite_accessory/mam_ears/instance = GLOB.mam_ears_list[path] + if(istype(instance, /datum/sprite_accessory)) + var/datum/sprite_accessory/S = instance + if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(H.client.ckey))) + snowflake_ears_list[S.name] = path var/new_ears - new_ears = input(owner, "Choose your character's ears:", "Ear Alteration") as null|anything in GLOB.mam_ears_list + new_ears = input(H, "Choose your character's ears:", "Ears Alteration") as null|anything in snowflake_ears_list if(new_ears) H.dna.features["mam_ears"] = new_ears H.update_body() + else if (select_alteration == "Tail") - var/new_tail - new_tail = input(owner, "Choose your character's tail:", "Tail Alteration") as null|anything in GLOB.mam_tails_list - if(new_tail) - H.dna.features["mam_tail"] = new_tail - if(new_tail != "None") - H.dna.features["taur"] = "None" + var/list/snowflake_ears_list = list("Normal" = null) + for(var/path in GLOB.mam_ears_list) + var/datum/sprite_accessory/mam_ears/instance = GLOB.mam_ears_list[path] + if(istype(instance, /datum/sprite_accessory)) + var/datum/sprite_accessory/S = instance + if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(H.client.ckey))) + snowflake_ears_list[S.name] = path + var/new_ears + new_ears = input(H, "Choose your character's ears:", "Tail Alteration") as null|anything in snowflake_ears_list + if(new_ears) + H.dna.features["mam_ears"] = new_ears H.update_body() + else if (select_alteration == "Taur body") + var/list/snowflake_taur_list = list("Normal" = null) + for(var/path in GLOB.taur_list) + var/datum/sprite_accessory/taur/instance = GLOB.taur_list[path] + if(istype(instance, /datum/sprite_accessory)) + var/datum/sprite_accessory/S = instance + if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(H.client.ckey))) + snowflake_taur_list[S.name] = path var/new_taur - new_taur = input(owner, "Choose your character's tauric body:", "Taur Body Alteration") as null|anything in GLOB.taur_list + new_taur = input(H, "Choose your character's tauric body:", "Tauric Alteration") as null|anything in snowflake_taur_list if(new_taur) H.dna.features["taur"] = new_taur if(new_taur != "None") From f29859ddbd09905ef66918b7470a5ab98d3aef9b Mon Sep 17 00:00:00 2001 From: Poojawa Date: Thu, 26 Apr 2018 07:27:09 -0500 Subject: [PATCH 2/4] fixes my shitcode --- .../carbon/human/species_types/jellypeople.dm | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm b/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm index 7464d344b3..3165decbb8 100644 --- a/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm +++ b/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm @@ -104,23 +104,23 @@ if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(H.client.ckey))) snowflake_ears_list[S.name] = path var/new_ears - new_ears = input(H, "Choose your character's ears:", "Ears Alteration") as null|anything in snowflake_ears_list + new_ears = input(owner, "Choose your character's ears:", "Ear Alteration") as null|anything in snowflake_ears_list if(new_ears) H.dna.features["mam_ears"] = new_ears H.update_body() else if (select_alteration == "Tail") - var/list/snowflake_ears_list = list("Normal" = null) - for(var/path in GLOB.mam_ears_list) - var/datum/sprite_accessory/mam_ears/instance = GLOB.mam_ears_list[path] + var/list/snowflake_tails_list = list("Normal" = null) + for(var/path in GLOB.mam_tails_list) + var/datum/sprite_accessory/mam_tails/instance = GLOB.mam_tails_list[path] if(istype(instance, /datum/sprite_accessory)) var/datum/sprite_accessory/S = instance if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(H.client.ckey))) - snowflake_ears_list[S.name] = path - var/new_ears - new_ears = input(H, "Choose your character's ears:", "Tail Alteration") as null|anything in snowflake_ears_list - if(new_ears) - H.dna.features["mam_ears"] = new_ears + snowflake_tails_list[S.name] = path + var/new_tail + new_ears = input(owner, "Choose your character's Tail(s):", "Tail Alteration") as null|anything in snowflake_tails_list + if(new_tail) + H.dna.features["mam_tails"] = new_tail H.update_body() else if (select_alteration == "Taur body") @@ -132,7 +132,7 @@ if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(H.client.ckey))) snowflake_taur_list[S.name] = path var/new_taur - new_taur = input(H, "Choose your character's tauric body:", "Tauric Alteration") as null|anything in snowflake_taur_list + new_taur = input(owner, "Choose your character's tauric body:", "Tauric Alteration") as null|anything in snowflake_taur_list if(new_taur) H.dna.features["taur"] = new_taur if(new_taur != "None") @@ -140,4 +140,4 @@ H.dna.features["xenotail"] = "None" H.update_body() else - return \ No newline at end of file + return From 110878de1833f59f886774e31facabdc5c4b7b78 Mon Sep 17 00:00:00 2001 From: Poojawa Date: Thu, 26 Apr 2018 07:27:47 -0500 Subject: [PATCH 3/4] Update jellypeople.dm --- .../mob/living/carbon/human/species_types/jellypeople.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm b/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm index 3165decbb8..c6b7d47617 100644 --- a/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm +++ b/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm @@ -118,7 +118,7 @@ if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(H.client.ckey))) snowflake_tails_list[S.name] = path var/new_tail - new_ears = input(owner, "Choose your character's Tail(s):", "Tail Alteration") as null|anything in snowflake_tails_list + new_tail = input(owner, "Choose your character's Tail(s):", "Tail Alteration") as null|anything in snowflake_tails_list if(new_tail) H.dna.features["mam_tails"] = new_tail H.update_body() From 918e4c50ebd8aa4fc4be4de9d342337e877fd247 Mon Sep 17 00:00:00 2001 From: Poojawa Date: Thu, 26 Apr 2018 07:37:49 -0500 Subject: [PATCH 4/4] ensures tails reset taur mode --- .../mob/living/carbon/human/species_types/jellypeople.dm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm b/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm index c6b7d47617..6137129407 100644 --- a/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm +++ b/modular_citadel/code/modules/mob/living/carbon/human/species_types/jellypeople.dm @@ -121,6 +121,8 @@ new_tail = input(owner, "Choose your character's Tail(s):", "Tail Alteration") as null|anything in snowflake_tails_list if(new_tail) H.dna.features["mam_tails"] = new_tail + if(new_tail != "None") + H.dna.features["taur"] = "None" H.update_body() else if (select_alteration == "Taur body")