[Ready Again]Refactors disabilities into lists, allowing for independent disability sources

This commit is contained in:
XDTM
2017-12-18 22:20:07 +01:00
committed by CitadelStationBot
parent 3df26e3be6
commit 3af0aa2489
81 changed files with 711 additions and 221 deletions
+1 -1
View File
@@ -217,7 +217,7 @@
C = owner
no_update = 0
if(C.disabilities & HUSK)
if(C.has_disability(HUSK))
species_id = "husk" //overrides species_id
dmg_overlay_type = "" //no damage overlay shown when husked
should_draw_gender = FALSE
+1 -1
View File
@@ -61,7 +61,7 @@
C = owner
real_name = C.real_name
if(C.disabilities & HUSK)
if(C.has_disability(HUSK))
real_name = "Unknown"
hair_style = "Bald"
facial_hair_style = "Shaved"
+2 -2
View File
@@ -23,9 +23,9 @@
/datum/surgery_step/fix_eyes/success(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, datum/surgery/surgery)
user.visible_message("[user] successfully fixes [target]'s eyes!", "<span class='notice'>You succeed in fixing [target]'s eyes.</span>")
target.cure_blind()
target.cure_blind(list(EYE_DAMAGE))
target.set_blindness(0)
target.cure_nearsighted()
target.cure_nearsighted(list(EYE_DAMAGE))
target.blur_eyes(35) //this will fix itself slowly.
target.set_eye_damage(0)
return TRUE
+1 -1
View File
@@ -4,7 +4,7 @@
possible_locs = list("chest")
/datum/surgery/lipoplasty/can_start(mob/user, mob/living/carbon/target)
if(target.disabilities & FAT)
if(target.has_disability(FAT))
return 1
return 0
+2 -2
View File
@@ -25,7 +25,7 @@
return
var/mob/living/carbon/C = owner
// genetic deafness prevents the body from using the ears, even if healthy
if(C.disabilities & DEAF)
if(C.has_disability(DEAF))
deaf = max(deaf, 1)
else
if(C.ears && (C.ears.flags_2 & HEALS_EARS_2))
@@ -42,7 +42,7 @@
var/mob/living/carbon/C = owner
if(iscarbon(owner) && C.disabilities & DEAF)
if(iscarbon(owner) && C.has_disability(DEAF))
deaf = 1
/obj/item/organ/ears/proc/adjustEarDamage(ddmg, ddeaf)