[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
+5 -5
View File
@@ -536,9 +536,9 @@ GLOBAL_VAR_INIT(rpg_loot_items, FALSE)
M.adjust_blurriness(15)
if(M.stat != DEAD)
to_chat(M, "<span class='danger'>Your eyes start to bleed profusely!</span>")
if(!(M.disabilities & (NEARSIGHT | BLIND)))
if(M.become_nearsighted())
to_chat(M, "<span class='danger'>You become nearsighted!</span>")
if(!(M.has_disability(BLIND) || M.has_disability(NEARSIGHT)))
to_chat(M, "<span class='danger'>You become nearsighted!</span>")
M.become_nearsighted(EYE_DAMAGE)
if(prob(50))
if(M.stat != DEAD)
if(M.drop_all_held_items())
@@ -547,8 +547,8 @@ GLOBAL_VAR_INIT(rpg_loot_items, FALSE)
M.Unconscious(20)
M.Knockdown(40)
if (prob(eyes.eye_damage - 10 + 1))
if(M.become_blind())
to_chat(M, "<span class='danger'>You go blind!</span>")
M.become_blind(EYE_DAMAGE)
to_chat(M, "<span class='danger'>You go blind!</span>")
/obj/item/clean_blood()
. = ..()