summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/describe.cc
diff options
context:
space:
mode:
authordolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2009-09-17 21:04:04 +0000
committerdolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2009-09-17 21:04:04 +0000
commitd636d3368b6441379025477373212cd203fe16bf (patch)
treee21710f2ca920d456247f29ecfe7a49bbe10e160 /crawl-ref/source/describe.cc
parent04a7ba1ee47556dcdf4d7ce56ebb7596f66cebfb (diff)
downloadcrawl-ref-d636d3368b6441379025477373212cd203fe16bf.tar.gz
crawl-ref-d636d3368b6441379025477373212cd203fe16bf.zip
Simplify further.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@10700 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/describe.cc')
-rw-r--r--crawl-ref/source/describe.cc12
1 files changed, 6 insertions, 6 deletions
diff --git a/crawl-ref/source/describe.cc b/crawl-ref/source/describe.cc
index 9fc5de9beb..c738b23d72 100644
--- a/crawl-ref/source/describe.cc
+++ b/crawl-ref/source/describe.cc
@@ -2586,11 +2586,11 @@ static std::string _monster_stat_description(const monsters& mon)
{
std::ostringstream result;
- // Don't leak or duplicate resistance information for demons/ghosts.
+ // Don't leak or duplicate resistance information for ghost demon
+ // monsters.
const mon_resist_def resist =
- (mon.type == MONS_PANDEMONIUM_DEMON
- || mon.type == MONS_PLAYER_GHOST ? get_mons_class_resists(mon.type)
- : get_mons_resists(&mon));
+ mons_is_ghost_demon(mon.type) ? get_mons_class_resists(mon.type)
+ : get_mons_resists(&mon);
const mon_resist_flags resists[] = {
MR_RES_ELEC, MR_RES_POISON, MR_RES_FIRE,
@@ -2676,8 +2676,8 @@ static std::string _monster_stat_description(const monsters& mon)
if (mons_immune_magic(&mon))
result << pronoun << " is immune to magical enchantments.$";
- // These differ from ghost to ghost, so would be spoily.
- if (mon.type != MONS_PANDEMONIUM_DEMON && mon.type != MONS_PLAYER_GHOST)
+ // These differ between ghost demon monsters, so would be spoily.
+ if (!mons_is_ghost_demon(mon.type))
{
// Seeing/sensing invisible.
if (mons_class_flag(mon.type, M_SEE_INVIS))