Merge pull request #14780 from farie82/virus-cure-fix

Makes advanced viruses not runtime when they are cured
This commit is contained in:
AffectedArc07
2020-10-29 13:55:25 +00:00
committed by GitHub
2 changed files with 6 additions and 2 deletions
+3 -1
View File
@@ -75,7 +75,7 @@ GLOBAL_LIST_INIT(diseases, subtypesof(/datum/disease))
var/cure = has_cure()
if(carrier && !cure)
return
return TRUE
stage = min(stage, max_stages)
@@ -89,6 +89,8 @@ GLOBAL_LIST_INIT(diseases, subtypesof(/datum/disease))
if(disease_flags & CURABLE)
if(cure && prob(cure_chance))
cure()
return FALSE
return TRUE
/datum/disease/proc/has_cure()
+3 -1
View File
@@ -69,7 +69,8 @@ GLOBAL_LIST_INIT(advance_cures, list(
// Randomly pick a symptom to activate.
/datum/disease/advance/stage_act()
..()
if(!..())
return FALSE
if(symptoms && symptoms.len)
if(!processing)
@@ -81,6 +82,7 @@ GLOBAL_LIST_INIT(advance_cures, list(
S.Activate(src)
else
CRASH("We do not have any symptoms during stage_act()!")
return TRUE
// Compares type then ID.
/datum/disease/advance/IsSame(datum/disease/advance/D)