diff options
Diffstat (limited to 'crawl-ref/source/mon-util.cc')
-rw-r--r-- | crawl-ref/source/mon-util.cc | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/crawl-ref/source/mon-util.cc b/crawl-ref/source/mon-util.cc index 5aa8142652..a2400b89b1 100644 --- a/crawl-ref/source/mon-util.cc +++ b/crawl-ref/source/mon-util.cc @@ -316,6 +316,7 @@ bool mons_class_is_stationary(int type) || type == MONS_PLANT || type == MONS_FUNGUS || type == MONS_CURSE_SKULL + || mons_is_statue(type) || mons_is_mimic(type)); } @@ -337,6 +338,11 @@ bool invalid_monster_class(int mclass) || mon_entry[mclass] == MONS_PROGRAM_BUG); } +bool mons_is_statue(int mc) +{ + return (mc == MONS_ORANGE_STATUE || mc == MONS_SILVER_STATUE); +} + bool mons_is_mimic( int mc ) { return (mons_species( mc ) == MONS_GOLD_MIMIC); @@ -891,6 +897,11 @@ int exper_value( const struct monsters *monster ) if (mons_class_flag(mclass, M_NO_EXP_GAIN)) return (0); + // no experience for destroying furniture, even if the furniture started + // the fight. + if (mons_is_statue(mclass)) + return (0); + // These undead take damage to maxhp, so we use only HD. -- bwr if (mclass == MONS_ZOMBIE_SMALL || mclass == MONS_ZOMBIE_LARGE @@ -1623,6 +1634,7 @@ bool mons_looks_stabbable(const monsters *m) return (!mons_class_flag(m->type, M_NO_EXP_GAIN) && m->type != MONS_OKLOB_PLANT && !mons_is_mimic(m->type) + && !mons_is_statue(m->type) && !mons_friendly(m) && mons_is_sleeping(m)); } @@ -1632,6 +1644,7 @@ bool mons_looks_distracted(const monsters *m) return (!mons_class_flag(m->type, M_NO_EXP_GAIN) && m->type != MONS_OKLOB_PLANT && !mons_is_mimic(m->type) + && !mons_is_statue(m->type) && !mons_friendly(m) && ((m->foe != MHITYOU && !mons_is_batty(m)) || mons_is_confused(m) |