diff --git a/code/game/atoms.dm b/code/game/atoms.dm index 56e4c70e202d..c6a1fe82a6c0 100644 --- a/code/game/atoms.dm +++ b/code/game/atoms.dm @@ -17,6 +17,8 @@ var/list/blood_DNA var/blood_color + /// Wont gloves/hands spend blood spill points to make this bloody + var/easy_to_spill_blood = FALSE var/pass_flags = 0 /// The higher the germ level, the more germ on the atom. var/germ_level = GERM_LEVEL_AMBIENT @@ -896,6 +898,7 @@ GLOBAL_LIST_EMPTY(blood_splatter_icons) return FALSE /obj/add_blood(list/blood_dna, b_color) + blood_color = b_color return transfer_blood_dna(blood_dna) /obj/item/add_blood(list/blood_dna, b_color) diff --git a/code/game/objects/items.dm b/code/game/objects/items.dm index 782186d3652a..5c81736b7561 100644 --- a/code/game/objects/items.dm +++ b/code/game/objects/items.dm @@ -27,6 +27,7 @@ GLOBAL_DATUM_INIT(welding_sparks, /mutable_appearance, mutable_appearance('icons can_be_hit = FALSE suicidal_hands = TRUE + easy_to_spill_blood = TRUE /// Sound played when you hit something with the item var/hitsound diff --git a/code/modules/clothing/clothing.dm b/code/modules/clothing/clothing.dm index f2d658cf6f2b..f8f4a6f346b2 100644 --- a/code/modules/clothing/clothing.dm +++ b/code/modules/clothing/clothing.dm @@ -268,7 +268,8 @@ var/safe_from_poison = FALSE strip_delay = 20 put_on_delay = 40 - var/transfer_blood = FALSE + ///Amount of times touching something with these gloves will spill blood on it + var/transfer_blood = 0 sprite_sheets = list( "Vox" = 'icons/mob/clothing/species/vox/gloves.dmi', diff --git a/code/modules/clothing/gloves/colored_gloves.dm b/code/modules/clothing/gloves/colored_gloves.dm index 59c567846ed2..40f263be7e01 100644 --- a/code/modules/clothing/gloves/colored_gloves.dm +++ b/code/modules/clothing/gloves/colored_gloves.dm @@ -232,4 +232,3 @@ icon_state = "furglovesico" item_state = "furgloves" transfer_prints = TRUE - transfer_blood = TRUE diff --git a/code/modules/detective_work/detective_work.dm b/code/modules/detective_work/detective_work.dm index 0ea5bcefb2dd..ea9596dafa4b 100644 --- a/code/modules/detective_work/detective_work.dm +++ b/code/modules/detective_work/detective_work.dm @@ -3,12 +3,29 @@ /atom/proc/add_fibers(mob/living/carbon/human/M) if(M.gloves && isclothing(M.gloves)) var/obj/item/clothing/gloves/G = M.gloves - if(G.transfer_blood > 1) //bloodied gloves transfer blood to touched objects - if(add_blood(G.blood_DNA, G.blood_color)) //only reduces the bloodiness of our gloves if the item wasn't already bloody - G.transfer_blood-- - else if(M.bloody_hands > 1) - if(add_blood(M.blood_DNA, M.hand_blood_color)) + if(easy_to_spill_blood && G.blood_DNA) + add_blood(G.blood_DNA, G.blood_color) + else if(G.transfer_blood > 1 && add_blood(G.blood_DNA, G.blood_color)) + G.transfer_blood-- + + if(blood_DNA) + var/old_transfer_blood = G.transfer_blood + G.add_blood(blood_DNA, blood_color) + G.transfer_blood = old_transfer_blood + M.update_inv_gloves() + + else + if(easy_to_spill_blood && M.blood_DNA) + add_blood(M.blood_DNA, M.hand_blood_color) + else if(M.bloody_hands > 1 && add_blood(M.blood_DNA, M.hand_blood_color)) M.bloody_hands-- + + if(blood_DNA) + var/old_bloody_hands = M.bloody_hands + M.add_blood(blood_DNA, blood_color) + M.bloody_hands = old_bloody_hands + M.update_inv_gloves() + if(!suit_fibers) suit_fibers = list() var/fibertext var/item_multiplier = isitem(src)?1.2:1 diff --git a/code/modules/mob/living/carbon/human/human_defense.dm b/code/modules/mob/living/carbon/human/human_defense.dm index b0f6e7835849..ada1db48e5b0 100644 --- a/code/modules/mob/living/carbon/human/human_defense.dm +++ b/code/modules/mob/living/carbon/human/human_defense.dm @@ -617,13 +617,10 @@ emp_act return TRUE /mob/living/carbon/human/proc/bloody_hands(mob/living/source, amount = 2) - if(gloves) gloves.add_mob_blood(source) - gloves:transfer_blood = amount else add_mob_blood(source) - bloody_hands = amount update_inv_gloves() //updates on-mob overlays for bloody hands and/or bloody gloves /mob/living/carbon/human/proc/bloody_body(mob/living/source) @@ -658,6 +655,10 @@ emp_act var/mob/living/carbon/human/H = user dna.species.spec_attack_hand(H, src) + if(bleed_rate && ishuman(user)) + var/mob/living/carbon/human/attacker = user + attacker.bloody_hands(src) + /mob/living/carbon/human/attack_larva(mob/living/carbon/alien/larva/L) if(..()) //successful larva bite. var/damage = rand(1, 3)