Files
Bubberstation/code/modules/unit_tests/confusion.dm
Jared-Fogle 7df16c595e Confusion will no longer continue to confuse after being cured (#52286)
* Confusion will no longer continue to confuse after being cured

* Grammar comment fix

* Move to status effect

* Remove test per request

* Make confusion a status effect, confusion curing now completely neuters the confusion

* set_confusion changes, get_confusion

* Fix confusion going down twice per tick

* Change strength = to proc

* Move procs to status_procs
2020-08-05 16:36:00 -03:00

17 lines
741 B
Plaintext

// Checks that the confusion symptom correctly gives, and removes, confusion
/datum/unit_test/confusion_symptom/Run()
var/mob/living/carbon/human/H = allocate(/mob/living/carbon/human)
var/datum/disease/advance/confusion/disease = allocate(/datum/disease/advance/confusion)
var/datum/symptom/confusion/confusion = disease.symptoms[1]
disease.processing = TRUE
disease.update_stage(5)
disease.infect(H, make_copy = FALSE)
confusion.Activate(disease)
TEST_ASSERT(H.get_confusion() > 0, "Human is not confused after getting symptom.")
disease.cure()
TEST_ASSERT_EQUAL(H.get_confusion(), 0, "Human is still confused after curing confusion.")
/datum/disease/advance/confusion/New()
symptoms += new /datum/symptom/confusion
Refresh()