From 6335f326f52b8a63d3d16f00a8506eb2d8cac00b Mon Sep 17 00:00:00 2001 From: jack-fractal Date: Sat, 11 Jul 2015 18:05:35 -0400 Subject: [PATCH 1/2] Bugfix for Examine Issue on Paint Cartridges Examining paint cartridges should work properly now. --- code/modules/organs/synth_skin.dm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/code/modules/organs/synth_skin.dm b/code/modules/organs/synth_skin.dm index 27a55411..2a04bc2d 100644 --- a/code/modules/organs/synth_skin.dm +++ b/code/modules/organs/synth_skin.dm @@ -294,8 +294,9 @@ proc/create_tinted_icon(icon_name, icon_state_name, target_colour) return " It looks like there are [current_charges] charges left." -/obj/item/weapon/synth_skin_cartridge/examine(mob/user) - user << src.desc + get_charges_string() +/obj/item/weapon/synth_skin_cartridge/examine() + set src in usr + usr << src.desc + get_charges_string() /obj/item/weapon/synth_skin_cartridge/attack_self(mob/user) From 30406044bb247f18b3ef2038782fb1134dd80313 Mon Sep 17 00:00:00 2001 From: jack-fractal Date: Sun, 19 Jul 2015 14:06:43 -0400 Subject: [PATCH 2/2] More Bugfixes * adds a delay to the spray-can (https://github.com/Aurorastation/Aurora/issues/663) * fixes the issue with damaged shells having their metallic bodies tinted by their body colour * fixes the issue with tails not updating properly (https://github.com/Aurorastation/Aurora/issues/666) * spray-cans will no longer remove your hair, provided that you're not changing apparent species --- code/__HELPERS/unsorted.dm | 9 +++++++++ code/modules/organs/synth_skin.dm | 10 +++++----- 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/code/__HELPERS/unsorted.dm b/code/__HELPERS/unsorted.dm index b1a391cb..e674fc1a 100644 --- a/code/__HELPERS/unsorted.dm +++ b/code/__HELPERS/unsorted.dm @@ -734,6 +734,15 @@ proc/anim(turf/location as turf,target as mob|obj,a_icon,a_icon_state as text,fl return 0 return 1 + +// this works like do_after but needs the target to stay still as well +/proc/do_after_to_target(var/mob/user as mob, target, delay as num, var/numticks = 5, var/needhand = 1) + var/target_original_turf = get_turf(target) + if (do_after(user,delay,numticks,needhand)) + if (get_turf(target)==target_original_turf) + return TRUE + return FALSE + //Takes: Anything that could possibly have variables and a varname to check. //Returns: 1 if found, 0 if not. diff --git a/code/modules/organs/synth_skin.dm b/code/modules/organs/synth_skin.dm index 2a04bc2d..a52d45db 100644 --- a/code/modules/organs/synth_skin.dm +++ b/code/modules/organs/synth_skin.dm @@ -29,7 +29,8 @@ datum/synthetic_limb_cover/New( var/datum/organ/external/datum_target=null,var/i datum/synthetic_limb_cover/proc/get_icon() // default mechanical limbs return robo versions var/icon/temp = new /icon((coverage ? main_icon : damage_icon), "[limb_datum.icon_name][limb_datum.get_gender_string()]") // only add a gender if it's necessary var/icon/result = icon(temp) - result.Blend(colour, ICON_ADD) + if (coverage) + result.Blend(colour, ICON_ADD) return result @@ -213,7 +214,8 @@ proc/create_tinted_icon(icon_name, icon_state_name, target_colour) if (target in list("mouth","eyes")) // we don't paint these individually target="head" if (allowed_to_paint(human_target,user,target)) - paint_organ(human_target, user, human_target.get_organ(target)) + if (do_after_to_target(user,human_target,20)) + paint_organ(human_target, user, human_target.get_organ(target)) /obj/item/weapon/synth_skin_spray/proc/paint_organ(mob/M, mob/user, datum/organ/external/datum_target) @@ -229,13 +231,11 @@ proc/create_tinted_icon(icon_name, icon_state_name, target_colour) human_target.r_facial = hair_colour_as_list[1] human_target.g_facial = hair_colour_as_list[2] human_target.b_facial = hair_colour_as_list[3] - human_target.h_style=random_hair_style(human_target.gender,human_target.species) human_target.update_hair() - - if (istype(datum_target,/datum/organ/external/groin)) // this is a bit reductive, but whatever var/gender_string = input(user,"What sex do you want this shell to appear as?") in list("Male","Female") human_target.gender = (gender_string=="Male") ? MALE : FEMALE + human_target.update_tail_showing(FALSE) human_target.update_body(TRUE) cartridge.current_charges-- user.visible_message("[user] has covered [M]'s [datum_target.display_name] with [cartridge.covering_description].")