Partially fixed the double definition of BROKEN, renamed organ definitions

This commit is contained in:
Albert Iordache
2012-07-13 23:42:05 +03:00
parent dd6c41ade1
commit b94b57e04c
33 changed files with 227 additions and 227 deletions

View File

@@ -192,29 +192,29 @@
// Gloves
var/datum/organ/external/lo = organs["l_hand"]
var/datum/organ/external/ro = organs["r_hand"]
if (!(lo.status & DESTROYED && ro.status & DESTROYED))
if (!(lo.status & ORGAN_DESTROYED && ro.status & ORGAN_DESTROYED))
if (gloves)
var/t1 = gloves.item_state
if (!t1)
t1 = gloves.icon_state
var/icon/gloves_icon = new /icon("icon" = 'hands.dmi', "icon_state" = text("[][]", t1, (!( lying ) ? null : "2")))
if(lo.status & DESTROYED)
if(lo.status & ORGAN_DESTROYED)
gloves_icon.Blend(new /icon('limb_mask.dmi', "right_[lying?"l":"s"]"), ICON_MULTIPLY)
else if(ro.status & DESTROYED)
else if(ro.status & ORGAN_DESTROYED)
gloves_icon.Blend(new /icon('limb_mask.dmi', "left_[lying?"l":"s"]"), ICON_MULTIPLY)
overlays += image(gloves_icon, "layer" = MOB_LAYER)
if (gloves.blood_DNA)
var/icon/stain_icon = icon('blood.dmi', "bloodyhands[!lying ? "" : "2"]")
if(lo.status & DESTROYED)
if(lo.status & ORGAN_DESTROYED)
stain_icon.Blend(new /icon('limb_mask.dmi', "right_[lying?"l":"s"]"), ICON_MULTIPLY)
else if(ro.status & DESTROYED)
else if(ro.status & ORGAN_DESTROYED)
stain_icon.Blend(new /icon('limb_mask.dmi', "left_[lying?"l":"s"]"), ICON_MULTIPLY)
overlays += image("icon" = stain_icon, "layer" = MOB_LAYER)
else if (blood_DNA)
var/icon/stain_icon = icon('blood.dmi', "bloodyhands[!lying ? "" : "2"]")
if(lo.status & DESTROYED)
if(lo.status & ORGAN_DESTROYED)
stain_icon.Blend(new /icon('limb_mask.dmi', "right_[lying?"l":"s"]"), ICON_MULTIPLY)
else if(ro.status & DESTROYED)
else if(ro.status & ORGAN_DESTROYED)
stain_icon.Blend(new /icon('limb_mask.dmi', "left_[lying?"l":"s"]"), ICON_MULTIPLY)
overlays += image("icon" = stain_icon, "layer" = MOB_LAYER)
// Glasses
@@ -231,19 +231,19 @@
// Shoes
lo = organs["l_foot"]
ro = organs["r_foot"]
if (!(lo.status & DESTROYED && ro.status & DESTROYED) && shoes)
if (!(lo.status & ORGAN_DESTROYED && ro.status & ORGAN_DESTROYED) && shoes)
var/t1 = shoes.icon_state
var/icon/shoes_icon = new /icon("icon" = 'feet.dmi', "icon_state" = text("[][]", t1, (!( lying ) ? null : "2")))
if(lo.status & DESTROYED && !lying)
if(lo.status & ORGAN_DESTROYED && !lying)
shoes_icon.Blend(new /icon('limb_mask.dmi', "right[lying?"_l":""]"), ICON_MULTIPLY)
else if(ro.status & DESTROYED && !lying)
else if(ro.status & ORGAN_DESTROYED && !lying)
shoes_icon.Blend(new /icon('limb_mask.dmi', "left[lying?"_l":""]"), ICON_MULTIPLY)
overlays += image(shoes_icon, "layer" = MOB_LAYER)
if (shoes.blood_DNA)
var/icon/stain_icon = icon('blood.dmi', "shoesblood[!lying ? "" : "2"]")
if(lo.status & DESTROYED)
if(lo.status & ORGAN_DESTROYED)
stain_icon.Blend(new /icon('limb_mask.dmi', "right_[lying?"l":"s"]"), ICON_MULTIPLY)
else if(ro.status & DESTROYED)
else if(ro.status & ORGAN_DESTROYED)
stain_icon.Blend(new /icon('limb_mask.dmi', "left_[lying?"l":"s"]"), ICON_MULTIPLY)
overlays += image("icon" = stain_icon, "layer" = MOB_LAYER) // Radio
/* if (w_radio)
@@ -355,7 +355,7 @@
head.screen_loc = ui_head
else
var/datum/organ/external/head = organs["head"]
if(!(head.status & DESTROYED))
if(!(head.status & ORGAN_DESTROYED))
//if not wearing anything on the head, show the ears
overlays += image("icon" = icon('tajaran.dmi', "ears_[gender==FEMALE ? "f" : "m"]_[lying ? "l" : "s"]"), "layer" = MOB_LAYER)
@@ -482,7 +482,7 @@
lying_icon.Blend(new /icon('tajaran.dmi', "chest_[g]_l"), ICON_OVERLAY)
var/datum/organ/external/head = organs["head"]
if(!(head.status & DESTROYED))
if(!(head.status & ORGAN_DESTROYED))
stand_icon.Blend(new /icon('tajaran.dmi', "head_[g]_s"), ICON_OVERLAY)
lying_icon.Blend(new /icon('tajaran.dmi', "head_[g]_l"), ICON_OVERLAY)
@@ -491,12 +491,12 @@
if(!istype(part, /datum/organ/external/groin) \
&& !istype(part, /datum/organ/external/chest) \
&& !istype(part, /datum/organ/external/head) \
&& !(part.status & DESTROYED))
&& !(part.status & ORGAN_DESTROYED))
var/icon/temp = new /icon('tajaran.dmi', "[part.icon_name]_s")
if(part.status & ROBOT) temp.MapColors(rgb(77,77,77), rgb(150,150,150), rgb(28,28,28), rgb(0,0,0))
if(part.status & ORGAN_ROBOT) temp.MapColors(rgb(77,77,77), rgb(150,150,150), rgb(28,28,28), rgb(0,0,0))
stand_icon.Blend(temp, ICON_OVERLAY)
temp = new /icon('tajaran.dmi', "[part.icon_name]_l")
if(part.status & ROBOT) temp.MapColors(rgb(77,77,77), rgb(150,150,150), rgb(28,28,28), rgb(0,0,0))
if(part.status & ORGAN_ROBOT) temp.MapColors(rgb(77,77,77), rgb(150,150,150), rgb(28,28,28), rgb(0,0,0))
lying_icon.Blend(temp , ICON_OVERLAY)
stand_icon.Blend(new /icon('tajaran.dmi', "groin_[g]_s"), ICON_OVERLAY)
@@ -511,7 +511,7 @@
if(!istype(part, /datum/organ/external/groin) \
&& !istype(part, /datum/organ/external/chest) \
&& !istype(part, /datum/organ/external/head) \
&& (part.status & DESTROYED))
&& (part.status & ORGAN_DESTROYED))
husk_s.Blend(new /icon('dam_mask.dmi', "[part.icon_name]"), ICON_SUBTRACT)
husk_l.Blend(new /icon('dam_mask.dmi', "[part.icon_name]2"), ICON_SUBTRACT)
@@ -539,7 +539,7 @@
if(organs)
var/datum/organ/external/head = organs["head"]
if(head)
if(head.status & DESTROYED)
if(head.status & ORGAN_DESTROYED)
del(face_standing)
del(face_lying)
return

View File

@@ -455,12 +455,12 @@ proc/airborne_can_reach(turf/source, turf/target)
var/name = pick(mob.organs)
var/datum/organ/external/organ = mob.organs[name]
if(!(organ.status & BROKEN) && !(organ.status & ROBOT))
if(!(organ.status & ORGAN_BROKEN) && !(organ.status & ORGAN_ROBOT))
mob.adjustBruteLoss(10)
mob.visible_message("\red You hear a loud cracking sound coming from [mob.name].","\red <b>Something feels like it shattered in your [organ.display_name]!</b>","You hear a sickening crack.")
mob.emote("scream")
organ.status |= BROKEN
organ.broken_description = pick("broken","fracture","hairline fracture") //Randomise in future. Edit: Randomized. --SkyMarshal
organ.status |= ORGAN_BROKEN
organ.broken_description = pick("broken","fracture","hairline fracture")
organ.perma_injury = 10