Merge remote-tracking branch 'upstream/master' into removes-cryobags

This commit is contained in:
Fox-McCloud
2017-07-15 06:20:26 -04:00
76 changed files with 263 additions and 245 deletions
+4 -4
View File
@@ -18,7 +18,7 @@
/mob/living/carbon/human/handle_blood()
var/list/blood_data = get_blood_data(get_blood_id())//PROCCEPTION
if(species && species.flags & NO_BLOOD)
if(NO_BLOOD in species.species_traits)
bleed_rate = 0
return
@@ -92,7 +92,7 @@
add_splatter_floor(loc, 1)
/mob/living/carbon/human/bleed(amt)
if(!(species && species.flags & NO_BLOOD))
if(!(NO_BLOOD in species.species_traits))
..()
if(species.exotic_blood)
var/datum/reagent/R = chemical_reagents_list[get_blood_id()]
@@ -194,7 +194,7 @@
/mob/living/carbon/human/get_blood_id()
if(species.exotic_blood)//some races may bleed water..or kethcup..
return species.exotic_blood
else if((species && species.flags & NO_BLOOD) || (NOCLONE in mutations))
else if((NO_BLOOD in species.species_traits) || (NOCLONE in mutations))
return
return "blood"
@@ -262,7 +262,7 @@
B.update_icon()
/mob/living/carbon/human/add_splatter_floor(turf/T, small_drip)
if(!(species && species.flags & NO_BLOOD))
if(!(NO_BLOOD in species.species_traits))
..()
/mob/living/carbon/alien/add_splatter_floor(turf/T, small_drip)
+2 -2
View File
@@ -96,7 +96,7 @@ var/list/organ_cache = list()
return
//Process infections
if((status & ORGAN_ROBOT) || sterile ||(owner && owner.species && (owner.species.flags & IS_PLANT)))
if((status & ORGAN_ROBOT) || sterile ||(owner && (IS_PLANT in owner.species.species_traits)))
germ_level = 0
return
@@ -316,7 +316,7 @@ var/list/organ_cache = list()
processing_objects |= src
var/datum/reagent/blood/organ_blood
if(reagents) organ_blood = reagents.get_reagent_from_id(owner.get_blood_id())
if((!organ_blood || !organ_blood.data["blood_DNA"]) && (owner && !(owner.species.flags & NO_BLOOD)))
if((!organ_blood || !organ_blood.data["blood_DNA"]) && (owner && !(NO_BLOOD in owner.species.species_traits)))
owner.transfer_blood_to(src)
if(owner && vital && is_primary_organ()) // I'd do another check for species or whatever so that you couldn't "kill" an IPC by removing a human head from them, but it doesn't matter since they'll come right back from the dead
+6 -13
View File
@@ -322,13 +322,6 @@
status &= ~ORGAN_BROKEN
perma_injury = 0
/*
if((brute || burn) && children && children.len && (owner.species.flags & REGENERATES_LIMBS))
var/obj/item/organ/external/stump/S = locate() in children
if(S)
// to_chat(world, "Extra healing to go around ([brute+burn]) and [owner] needs a replacement limb.")
*/
//Sync the organ's damage with its wounds
src.update_damages()
owner.updatehealth()
@@ -491,7 +484,7 @@ Note that amputating the affected organ does in fact remove the infection from t
*/
/obj/item/organ/external/proc/update_germs()
if(status & (ORGAN_ROBOT|ORGAN_DESTROYED) || (owner.species && owner.species.flags & IS_PLANT)) //Robotic limbs shouldn't be infected, nor should nonexistant limbs.
if(status & (ORGAN_ROBOT|ORGAN_DESTROYED) || (IS_PLANT in owner.species.species_traits)) //Robotic limbs shouldn't be infected, nor should nonexistant limbs.
germ_level = 0
return
@@ -577,9 +570,9 @@ Note that amputating the affected organ does in fact remove the infection from t
var/bicardose = owner.reagents.get_reagent_amount("styptic_powder")
if(!bicardose) //styptic powder stops internal wounds from growing bigger with time, and also stop bleeding
W.open_wound(0.1 * wound_update_accuracy)
owner.blood_volume -= (0.05 * W.damage * wound_update_accuracy)
owner.blood_volume = max(owner.blood_volume - (0.05 * W.damage * wound_update_accuracy), 0)
owner.blood_volume -= (0.02 * W.damage * wound_update_accuracy)
owner.blood_volume = max(owner.blood_volume - (0.02 * W.damage * wound_update_accuracy), 0)
if(prob(1 * wound_update_accuracy))
owner.custom_pain("You feel a stabbing pain in your [name]!",1)
@@ -634,7 +627,7 @@ Note that amputating the affected organ does in fact remove the infection from t
if(!(status & ORGAN_ROBOT) && W.bleeding())
W.bleed_timer--
if(H && (H.species.flags & NO_BLOOD)) // Bloodless organic races are finicky
if(H && (NO_BLOOD in H.species.species_traits)) // Bloodless organic races are finicky
W.clamped = 1
W.bleed_timer = 0
else
@@ -644,7 +637,7 @@ Note that amputating the affected organ does in fact remove the infection from t
number_wounds += W.amount
if(open && !clamped && (H && !(H.species.flags & NO_BLOOD)))
if(open && !clamped && (H && !(NO_BLOOD in H.species.species_traits)))
status |= ORGAN_BLEEDING
//Bone fractures
@@ -826,7 +819,7 @@ Note that amputating the affected organ does in fact remove the infection from t
"<span class='warning'>You hear a loud cracking sound coming from \the [owner].</span>",\
"<span class='danger'>Something feels like it shattered in your [name]!</span>",\
"You hear a sickening crack.")
if(owner.species && !(owner.species.flags & NO_PAIN))
if(owner.species && !(NO_PAIN in owner.species.species_traits))
owner.emote("scream")
status |= ORGAN_BROKEN
+5 -5
View File
@@ -49,7 +49,7 @@ var/global/list/limb_icon_cache = list()
if(!isnull(dna.GetUIValue(DNA_UI_SKIN_TONE)) && ((species.bodyflags & HAS_SKIN_TONE) || (species.bodyflags & HAS_ICON_SKIN_TONE)))
s_col = null
s_tone = dna.GetUIValue(DNA_UI_SKIN_TONE)
if(species.flags & HAS_SKIN_COLOR)
if(species.bodyflags & HAS_SKIN_COLOR)
s_tone = null
s_col = list(dna.GetUIValue(DNA_UI_SKIN_R), dna.GetUIValue(DNA_UI_SKIN_G), dna.GetUIValue(DNA_UI_SKIN_B))
@@ -115,7 +115,7 @@ var/global/list/limb_icon_cache = list()
mob_icon.Blend(eyes_icon, ICON_OVERLAY)
overlays |= eyes_icon
if(owner.lip_style && (species && (species.flags & HAS_LIPS)))
if(owner.lip_style && (LIPS in species.species_traits))
var/icon/lip_icon = new/icon('icons/mob/human_face.dmi', "lips_[owner.lip_style]_s")
overlays |= lip_icon
mob_icon.Blend(lip_icon, ICON_OVERLAY)
@@ -139,7 +139,7 @@ var/global/list/limb_icon_cache = list()
if(f_style)
var/datum/sprite_accessory/facial_hair_style = facial_hair_styles_list[f_style]
if(facial_hair_style && ((facial_hair_style.species_allowed && (species.name in facial_hair_style.species_allowed)) || (src.species.flags & ALL_RPARTS)))
if(facial_hair_style && ((facial_hair_style.species_allowed && (species.name in facial_hair_style.species_allowed)) || (src.species.bodyflags & ALL_RPARTS)))
var/icon/facial_s = new/icon("icon" = facial_hair_style.icon, "icon_state" = "[facial_hair_style.icon_state]_s")
if(species.name == "Slime People") // I am el worstos
facial_s.Blend(rgb(owner.r_skin, owner.g_skin, owner.b_skin, 160), ICON_AND)
@@ -149,7 +149,7 @@ var/global/list/limb_icon_cache = list()
if(h_style && !(owner.head && (owner.head.flags & BLOCKHEADHAIR)))
var/datum/sprite_accessory/hair_style = hair_styles_list[h_style]
if(hair_style && ((species.name in hair_style.species_allowed) || (src.species.flags & ALL_RPARTS)))
if(hair_style && ((species.name in hair_style.species_allowed) || (src.species.bodyflags & ALL_RPARTS)))
var/icon/hair_s = new/icon("icon" = hair_style.icon, "icon_state" = "[hair_style.icon_state]_s")
if(species.name == "Slime People") // I am el worstos
hair_s.Blend(rgb(owner.r_skin, owner.g_skin, owner.b_skin, 160), ICON_AND)
@@ -192,7 +192,7 @@ var/global/list/limb_icon_cache = list()
/obj/item/organ/external/chest/get_icon_state(skeletal)
var/result = ..()
if(fat && !skeletal && !(status & ORGAN_ROBOT) && (species.flags & CAN_BE_FAT))
if(fat && !skeletal && !(status & ORGAN_ROBOT) && (CAN_BE_FAT in species.species_traits))
result[2] += "_fat"
return result
@@ -211,7 +211,7 @@
/obj/item/organ/internal/heart/cursed/attack(mob/living/carbon/human/H, mob/living/carbon/human/user, obj/target)
if(H == user && istype(H))
if(H.species.flags & NO_BLOOD || H.species.exotic_blood)
if(NO_BLOOD in H.species.species_traits)
to_chat(H, "<span class = 'userdanger'>\The [src] is not compatible with your form!</span>")
return
playsound(user,'sound/effects/singlebeat.ogg', 40, 1)
@@ -224,7 +224,7 @@
if(world.time > (last_pump + pump_delay))
if(ishuman(owner) && owner.client) //While this entire item exists to make people suffer, they can't control disconnects.
var/mob/living/carbon/human/H = owner
if(!(H.species.flags & NO_BLOOD))
if(!(NO_BLOOD in H.species.species_traits))
H.blood_volume = max(H.blood_volume - blood_loss, 0)
to_chat(H, "<span class='userdanger'>You have to keep pumping your blood!</span>")
if(H.client)
@@ -257,7 +257,7 @@
var/mob/living/carbon/human/H = owner
if(istype(H))
if(!(H.species.flags & NO_BLOOD))
if(!(NO_BLOOD in H.species.species_traits))
H.blood_volume = min(H.blood_volume + cursed_heart.blood_loss*0.5, BLOOD_VOLUME_MAXIMUM)
if(owner.client)
owner.client.color = ""
+3 -2
View File
@@ -47,7 +47,8 @@ mob/living/carbon/proc/pain(var/partname, var/amount, var/force, var/burning = 0
mob/living/carbon/human/proc/custom_pain(var/message, var/flash_strength)
if(stat >= 1) return
if(species && species.flags & NO_PAIN) return
if(NO_PAIN in species.species_traits)
return
if(reagents.has_reagent("morphine"))
return
@@ -66,7 +67,7 @@ mob/living/carbon/human/proc/custom_pain(var/message, var/flash_strength)
mob/living/carbon/human/proc/handle_pain()
// not when sleeping
if(species && species.flags & NO_PAIN)
if(NO_PAIN in species.species_traits)
//While synthetics don't feel pain, they will notice their gears gunking up with residue (toxins)
if(isSynthetic())
var/toxDamageMessage = null