Prefixed all disability defines with DISABILITY_ to fix a name collision

This commit is contained in:
Jordan Brown
2017-12-24 11:45:45 -05:00
committed by CitadelStationBot
parent 2378235f51
commit 164db7ae9b
83 changed files with 957 additions and 9 deletions
@@ -48,7 +48,11 @@
add_fingerprint(user)
if(istype(M) && on && user.zone_selected in list("eyes", "mouth"))
<<<<<<< HEAD
if((user.disabilities & (CLUMSY | DUMB)) && prob(50)) //too dumb to use flashlight properly
=======
if((user.has_disability(DISABILITY_CLUMSY) || user.has_disability(DISABILITY_DUMB)) && prob(50)) //too dumb to use flashlight properly
>>>>>>> bc20a75... Merge pull request #33783 from Cruix/fix_blind
return ..() //just hit them in the head
if(!user.IsAdvancedToolUser())
@@ -82,7 +86,11 @@
else
user.visible_message("<span class='warning'>[user] directs [src] to [M]'s eyes.</span>", \
"<span class='danger'>You direct [src] to [M]'s eyes.</span>")
<<<<<<< HEAD
if(M.stat == DEAD || (M.disabilities & BLIND) || !M.flash_act(visual = 1)) //mob is dead or fully blind
=======
if(M.stat == DEAD || (M.has_disability(DISABILITY_BLIND)) || !M.flash_act(visual = 1)) //mob is dead or fully blind
>>>>>>> bc20a75... Merge pull request #33783 from Cruix/fix_blind
to_chat(user, "<span class='warning'>[M]'s pupils don't react to the light!</span>")
else if(M.dna && M.dna.check_mutation(XRAY)) //mob has X-RAY vision
to_chat(user, "<span class='danger'>[M]'s pupils give an eerie glow!</span>")
@@ -85,7 +85,11 @@ GAS ANALYZER
/obj/item/device/healthanalyzer/attack(mob/living/M, mob/living/carbon/human/user)
// Clumsiness/brain damage check
<<<<<<< HEAD
if ((user.disabilities & (CLUMSY | DUMB)) && prob(50))
=======
if ((user.has_disability(DISABILITY_CLUMSY) || user.has_disability(DISABILITY_DUMB)) && prob(50))
>>>>>>> bc20a75... Merge pull request #33783 from Cruix/fix_blind
to_chat(user, "<span class='notice'>You stupidly try to analyze the floor's vitals!</span>")
user.visible_message("<span class='warning'>[user] has analyzed the floor's vitals!</span>")
to_chat(user, "<span class='info'>Analyzing results for The floor:\n\tOverall status: <b>Healthy</b>")
@@ -181,9 +185,18 @@ GAS ANALYZER
to_chat(user, "\t<span class='info'><b>==EAR STATUS==</b></span>")
if(istype(ears))
var/healthy = TRUE
<<<<<<< HEAD
if(C.disabilities & DEAF)
healthy = FALSE
to_chat(user, "\t<span class='alert'>Subject is genetically deaf.</span>")
=======
if(C.has_disability(DISABILITY_DEAF, GENETIC_MUTATION))
healthy = FALSE
to_chat(user, "\t<span class='alert'>Subject is genetically deaf.</span>")
else if(C.has_disability(DISABILITY_DEAF))
healthy = FALSE
to_chat(user, "\t<span class='alert'>Subject is deaf.</span>")
>>>>>>> bc20a75... Merge pull request #33783 from Cruix/fix_blind
else
if(ears.ear_damage)
to_chat(user, "\t<span class='alert'>Subject has [ears.ear_damage > UNHEALING_EAR_DAMAGE? "permanent ": "temporary "]hearing damage.</span>")
@@ -199,10 +212,17 @@ GAS ANALYZER
to_chat(user, "\t<span class='info'><b>==EYE STATUS==</b></span>")
if(istype(eyes))
var/healthy = TRUE
<<<<<<< HEAD
if(C.disabilities & BLIND)
to_chat(user, "\t<span class='alert'>Subject is blind.</span>")
healthy = FALSE
if(C.disabilities & NEARSIGHT)
=======
if(C.has_disability(DISABILITY_BLIND))
to_chat(user, "\t<span class='alert'>Subject is blind.</span>")
healthy = FALSE
if(C.has_disability(DISABILITY_NEARSIGHT))
>>>>>>> bc20a75... Merge pull request #33783 from Cruix/fix_blind
to_chat(user, "\t<span class='alert'>Subject is nearsighted.</span>")
healthy = FALSE
if(eyes.eye_damage > 30)