diff options
author | Robert Vollmert <rvollmert@gmx.net> | 2009-10-22 18:14:00 +0200 |
---|---|---|
committer | Robert Vollmert <rvollmert@gmx.net> | 2009-10-22 22:37:07 +0200 |
commit | 78f7b9d8e5921ef3e1f64d01c802436a654c177a (patch) | |
tree | 3d58adf6061925cc6f729a819f4a2c64bccb34d9 /crawl-ref/source/mon-util.cc | |
parent | ed4a22bce4db2328e945840901176b49d4b573e7 (diff) | |
download | crawl-ref-78f7b9d8e5921ef3e1f64d01c802436a654c177a.tar.gz crawl-ref-78f7b9d8e5921ef3e1f64d01c802436a654c177a.zip |
Move player_see_invis into player class.
Diffstat (limited to 'crawl-ref/source/mon-util.cc')
-rw-r--r-- | crawl-ref/source/mon-util.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/crawl-ref/source/mon-util.cc b/crawl-ref/source/mon-util.cc index 4ed5d9b690..8829e968cb 100644 --- a/crawl-ref/source/mon-util.cc +++ b/crawl-ref/source/mon-util.cc @@ -3134,7 +3134,7 @@ bool ms_waste_of_time( const monsters *mon, spell_type monspell ) case SPELL_INVISIBILITY: if (mon->has_ench(ENCH_INVIS) - || mons_friendly(mon) && !player_see_invis(false)) + || mons_friendly(mon) && !you.can_see_invisible(false)) { ret = true; } @@ -7034,7 +7034,7 @@ void monsters::remove_enchantment_effect(const mon_enchant &me, bool quiet) // Invisible monsters stay invisible. if (mons_class_flag(type, M_INVIS)) add_ench(mon_enchant(ENCH_INVIS)); - else if (mons_near(this) && !player_see_invis() + else if (mons_near(this) && !you.can_see_invisible() && !has_ench(ENCH_SUBMERGED)) { if (!quiet) @@ -8412,7 +8412,7 @@ bool monsters::should_drink_potion(potion_type ptype) const // We're being nice: friendlies won't go invisible if the player // won't be able to see them. return (!has_ench(ENCH_INVIS) - && (player_see_invis(false) || !mons_friendly(this))); + && (you.can_see_invisible(false) || !mons_friendly(this))); default: break; } |