summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/religion.cc
diff options
context:
space:
mode:
authordolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2008-04-23 05:13:46 +0000
committerdolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2008-04-23 05:13:46 +0000
commit8b56de83116cdcc9084e703fd3136d9e5e25071f (patch)
treedd0b6bcc6c96f8de213773e2079cf9d242a4d467 /crawl-ref/source/religion.cc
parent683e26edec41c7886bb0498a5b514e2b6a1ac20d (diff)
downloadcrawl-ref-8b56de83116cdcc9084e703fd3136d9e5e25071f.tar.gz
crawl-ref-8b56de83116cdcc9084e703fd3136d9e5e25071f.zip
Reorder TSO blessings a bit.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@4513 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/religion.cc')
-rw-r--r--crawl-ref/source/religion.cc64
1 files changed, 32 insertions, 32 deletions
diff --git a/crawl-ref/source/religion.cc b/crawl-ref/source/religion.cc
index 3800a3845a..34050bcdf1 100644
--- a/crawl-ref/source/religion.cc
+++ b/crawl-ref/source/religion.cc
@@ -881,6 +881,31 @@ static bool _blessing_healing(monsters *mon, bool extra)
return heal_monster(mon, mon->max_hit_points, extra);
}
+static bool _tso_blessing_holy_wpn(monsters *mon)
+{
+ // Pick a monster's weapon.
+ const int weapon = mon->inv[MSLOT_WEAPON];
+
+ if (weapon == NON_ITEM)
+ return false;
+
+ item_def& wpn(mitm[weapon]);
+
+ if (is_artefact(wpn) || get_weapon_brand(wpn) == SPWPN_HOLY_WRATH)
+ return false;
+
+ // And make it holy.
+ set_equip_desc(wpn, ISFLAG_GLOWING);
+ set_item_ego_type(wpn, OBJ_WEAPONS, SPWPN_HOLY_WRATH);
+ wpn.colour = YELLOW;
+
+ // Convert demonic weapons into non-demonic weapons.
+ if (is_demonic(wpn))
+ convert2good(wpn, false);
+
+ return true;
+}
+
static bool _tso_blessing_holy_arm(monsters* mon)
{
if (mons_res_negative_energy(mon) == 3)
@@ -914,31 +939,6 @@ static bool _tso_blessing_holy_arm(monsters* mon)
return true;
}
-static bool _tso_blessing_holy_wpn(monsters *mon)
-{
- // Pick a monster's weapon.
- const int weapon = mon->inv[MSLOT_WEAPON];
-
- if (weapon == NON_ITEM)
- return false;
-
- item_def& wpn(mitm[weapon]);
-
- if (is_artefact(wpn) || get_weapon_brand(wpn) == SPWPN_HOLY_WRATH)
- return false;
-
- // And make it holy.
- set_equip_desc(wpn, ISFLAG_GLOWING);
- set_item_ego_type(wpn, OBJ_WEAPONS, SPWPN_HOLY_WRATH);
- wpn.colour = YELLOW;
-
- // Convert demonic weapons into non-demonic weapons.
- if (is_demonic(wpn))
- convert2good(wpn, false);
-
- return true;
-}
-
static bool _tso_blessing_extend_stay(monsters *mon)
{
if (!mon->has_ench(ENCH_ABJ))
@@ -1127,22 +1127,22 @@ bool bless_follower(monsters* follower,
switch (god)
{
case GOD_SHINING_ONE:
- // Brand a monster's armour with positive energy, if
+ // Brand a monster's weapon with holy wrath, if
// possible.
- if (_tso_blessing_holy_arm(mon))
+ if (_tso_blessing_holy_wpn(mon))
{
- result = "life defence";
+ result = "holy attack power";
goto blessing_done;
}
+ break;
- // Brand a monster's weapon with holy wrath, if
+ // Brand a monster's armour with positive energy, if
// possible.
- if (_tso_blessing_holy_wpn(mon))
+ if (_tso_blessing_holy_arm(mon))
{
- result = "holy attack power";
+ result = "life defence";
goto blessing_done;
}
- break;
case GOD_BEOGH:
// Turn a monster into a priestly monster, if possible.