From 525ed47151b7129d1346518d6f74effc4e6f79ac Mon Sep 17 00:00:00 2001 From: dolorous Date: Thu, 15 May 2008 17:05:22 +0000 Subject: When placed under penance or excommunicated by Zin, remove divine stamina. Also, consolidate the routines for removing Zin's divine robustness, Zin's divine stamina, and TSO's divine shield. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@5059 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/spells1.cc | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'crawl-ref/source/spells1.cc') diff --git a/crawl-ref/source/spells1.cc b/crawl-ref/source/spells1.cc index 08e98a6fd1..312e2a17d6 100644 --- a/crawl-ref/source/spells1.cc +++ b/crawl-ref/source/spells1.cc @@ -789,6 +789,26 @@ void reduce_revitalisation_chain(int amount) } } +void remove_divine_robustness() +{ + mpr("Your divine robustness is withdrawn."); + you.duration[DUR_DIVINE_ROBUSTNESS] = 0; + you.attribute[ATTR_DIVINE_ROBUSTNESS] = 0; + calc_hp(); +} + +void remove_divine_stamina() +{ + mpr("Your divine stamina fades.", MSGCH_DURATION); + modify_stat(STAT_STRENGTH, -you.attribute[ATTR_DIVINE_STAMINA], + true, "Zin's divine stamina running out"); + modify_stat(STAT_INTELLIGENCE, -you.attribute[ATTR_DIVINE_STAMINA], + true, "Zin's divine stamina running out"); + modify_stat(STAT_DEXTERITY, -you.attribute[ATTR_DIVINE_STAMINA], + true, "Zin's divine stamina running out"); + you.attribute[ATTR_DIVINE_STAMINA] = 0; +} + int cast_revitalisation(int pow) { const int step_max_chain = 6; -- cgit v1.2.3-54-g00ecf