Blood Under Clothes (#10983)

This commit is contained in:
Geeves
2021-01-22 02:25:03 -03:00
committed by GitHub
parent a7e65e4ee5
commit d199aea525
7 changed files with 78 additions and 15 deletions
+21 -15
View File
@@ -1,10 +1,11 @@
#define SEC_HUDTYPE "security"
#define MED_HUDTYPE "medical"
/mob/living/carbon/human/proc/get_covered_body_parts()
/mob/living/carbon/human/proc/get_covered_body_parts(var/thick)
var/skipbody = 0
for(var/obj/item/clothing/C in list(wear_suit, head, wear_mask, w_uniform, gloves, shoes))
skipbody |= C.body_parts_covered
if(!thick || (C.item_flags & THICKMATERIAL))
skipbody |= C.body_parts_covered
return skipbody
/mob/living/carbon/human/proc/get_covered_clothes()
@@ -15,6 +16,7 @@
/mob/living/carbon/human/examine(mob/user)
var/skipbody = get_covered_body_parts()
var/skipbody_thick = get_covered_body_parts(TRUE)
var/skipitems = get_covered_clothes()
//exosuits and helmets obscure our view and stuff.
@@ -281,23 +283,26 @@
if(temp.body_part & HEAD)
body_part &= ~HEAD
body_part |= (temp.body_part & FACE) ? HEAD : 0
if(skipbody & body_part)
if(skipbody_thick & body_part)
continue
if(temp.status & ORGAN_ASSISTED)
var/thin_covering = (skipbody & body_part) ? TRUE : FALSE
if((temp.status & ORGAN_ASSISTED) && !thin_covering)
if(!(temp.brute_dam + temp.burn_dam))
//wound_flavor_text["[temp.name]"] = "<span class='warning'>[get_pronoun("He")] [get_pronoun("has")] a robot [temp.name]!</span>\n"
// No need to notify about robotic limbs if they're not damaged, really.
continue
else
wound_flavor_text["[temp.name]"] = "<span class='warning'>[get_pronoun("He")] [get_pronoun("has")] [temp.get_wounds_desc()] on [get_pronoun("his")] [temp.name].</span><br>"
else if(temp.wounds.len > 0 || temp.open)
if(temp.is_stump() && temp.parent_organ && organs_by_name[temp.parent_organ])
var/obj/item/organ/external/parent = organs_by_name[temp.parent_organ]
wound_flavor_text["[temp.name]"] = "<span class='warning'>[get_pronoun("He")] [get_pronoun("has")] [temp.get_wounds_desc()] on [get_pronoun("his")] [parent.name].</span><br>"
else
wound_flavor_text["[temp.name]"] = "<span class='warning'>[get_pronoun("He")] [get_pronoun("has")] [temp.get_wounds_desc()] on [get_pronoun("his")] [temp.name].</span><br>"
else if(length(temp.wounds) || temp.open)
if(!thin_covering)
if(temp.is_stump() && temp.parent_organ && organs_by_name[temp.parent_organ])
var/obj/item/organ/external/parent = organs_by_name[temp.parent_organ]
wound_flavor_text["[temp.name]"] = "<span class='warning'>[get_pronoun("He")] [get_pronoun("has")] [temp.get_wounds_desc()] on [get_pronoun("his")] [parent.name].</span><br>"
else
wound_flavor_text["[temp.name]"] = "<span class='warning'>[get_pronoun("He")] [get_pronoun("has")] [temp.get_wounds_desc()] on [get_pronoun("his")] [temp.name].</span><br>"
if(temp.status & ORGAN_BLEEDING)
is_bleeding["[temp.name]"] = "<span class='danger'>[get_pronoun("His")] [temp.name] is bleeding!</span><br>"
if(thin_covering)
is_bleeding["[temp.body_part_class()]"] = "<span class='danger'>[get_pronoun("He")] [temp.covered_bleed_report(species.blood_type)]</span><br>"
else
is_bleeding["[temp.name]"] = "<span class='danger'>[get_pronoun("His")] [temp.name] is bleeding!</span><br>"
else
wound_flavor_text["[temp.name]"] = ""
if(temp.dislocated == 2)
@@ -309,8 +314,9 @@
//If they have something that covers the limb, and it is not missing, put flavortext. If it is covered but bleeding, add other flavortext.
for(var/limb in wound_flavor_text)
msg += wound_flavor_text[limb]
is_bleeding[limb] = null
if(wound_flavor_text[limb])
msg += wound_flavor_text[limb]
is_bleeding[limb] = null
for(var/limb in is_bleeding)
msg += is_bleeding[limb]
for(var/obj/item/organ/external/organ in src.organs)
@@ -36,6 +36,7 @@
var/eyes_icons = 'icons/mob/human_face/eyes.dmi' // DMI file for eyes, mostly for none 32x32 species.
var/has_floating_eyes // Eyes will overlay over darkness (glow)
var/eyes_icon_blend = ICON_ADD // The icon blending mode to use for eyes.
var/blood_type = "blood"
var/blood_color = "#A10808" // Red.
var/flesh_color = "#FFC896" // Pink.
var/examine_color // The color of the species' name in the examine text. Defaults to flesh_color if unset.
@@ -106,6 +106,7 @@
character_color_presets = list("Default Bark" = "#000000", "Light Bark" = "#141414", "Brown Bark" = "#2b1d0e", "Green Bark" = "#001400")
blood_type = "sap"
blood_color = COLOR_DIONA_BLOOD
flesh_color = "#907E4A"
@@ -75,6 +75,7 @@
appearance_flags = HAS_SKIN_COLOR | HAS_HAIR_COLOR | HAS_UNDERWEAR | HAS_SOCKS
spawn_flags = CAN_JOIN | IS_WHITELISTED | NO_AGE_MINIMUM
blood_type = "oil"
blood_color = COLOR_IPC_BLOOD
flesh_color = "#575757"
reagent_tag = IS_MACHINE