diff options
author | Steve Melenchuk <smelenchuk@gmail.com> | 2014-01-31 11:32:37 -0700 |
---|---|---|
committer | Steve Melenchuk <smelenchuk@gmail.com> | 2014-01-31 11:40:56 -0700 |
commit | 74625fffcfc1c84331257d13f6cf88a443828a53 (patch) | |
tree | 4a9319ffe5b7a71f1ab2548da5d895bacf2ba266 /crawl-ref/source/mon-ench.cc | |
parent | 25c05303298545bc852be44236219cc4defe5d43 (diff) | |
download | crawl-ref-74625fffcfc1c84331257d13f6cf88a443828a53.tar.gz crawl-ref-74625fffcfc1c84331257d13f6cf88a443828a53.zip |
Rework the monster Ozocubu's Armour effect and give back to Fannar.
Primarily, this introduces an M_OZOCUBUS_ARMOUR that pre-generates
tagged monsters with the enchantment already in effect and that does not
time out. The spell still exists, and also gives armour that doesn't
time out; this would be most likely to be used a monster that has
M_OZOCUBUS_ARMOUR.
Since the original implementation was for Fannar, it makes sense that
he's the first to get it back. I haven't touched his current spell set
because he's probably still going to die quickly enough that he won't
waste a turn casting it again.
Diffstat (limited to 'crawl-ref/source/mon-ench.cc')
-rw-r--r-- | crawl-ref/source/mon-ench.cc | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/crawl-ref/source/mon-ench.cc b/crawl-ref/source/mon-ench.cc index acfbf76fa2..54ebf5bb40 100644 --- a/crawl-ref/source/mon-ench.cc +++ b/crawl-ref/source/mon-ench.cc @@ -950,12 +950,12 @@ void monster::remove_enchantment_effect(const mon_enchant &me, bool quiet) } } -bool monster::lose_ench_levels(const mon_enchant &e, int lev) +bool monster::lose_ench_levels(const mon_enchant &e, int lev, bool infinite) { if (!lev) return false; - if (e.duration >= INFINITE_DURATION) + if (e.duration >= INFINITE_DURATION && !infinite) return false; if (e.degree <= lev) { @@ -1050,7 +1050,7 @@ void monster::timeout_enchantments(int levels) case ENCH_MIRROR_DAMAGE: case ENCH_STONESKIN: case ENCH_LIQUEFYING: case ENCH_SILVER_CORONA: case ENCH_DAZED: case ENCH_FAKE_ABJURATION: case ENCH_ROUSED: case ENCH_BREATH_WEAPON: case ENCH_DEATHS_DOOR: - case ENCH_OZOCUBUS_ARMOUR: case ENCH_WRETCHED: case ENCH_SCREAMED: + case ENCH_WRETCHED: case ENCH_SCREAMED: case ENCH_BLIND: case ENCH_WORD_OF_RECALL: case ENCH_INJURY_BOND: case ENCH_FLAYED: case ENCH_BARBS: case ENCH_BUILDING_CHARGE: case ENCH_AGILE: case ENCH_FROZEN: case ENCH_EPHEMERAL_INFUSION: @@ -1256,7 +1256,6 @@ void monster::apply_enchantment(const mon_enchant &me) case ENCH_DUMB: case ENCH_MAD: case ENCH_BREATH_WEAPON: - case ENCH_OZOCUBUS_ARMOUR: case ENCH_WRETCHED: case ENCH_SCREAMED: case ENCH_WEAK: @@ -2311,7 +2310,6 @@ int mon_enchant::calc_duration(const monster* mons, case ENCH_INVIS: case ENCH_FEAR_INSPIRING: case ENCH_STONESKIN: - case ENCH_OZOCUBUS_ARMOUR: case ENCH_AGILE: case ENCH_BLACK_MARK: cturn = 1000 / _mod_speed(25, mons->speed); |