From 6bdaccfb8c194bfa0bb0b6769babc3710d570b45 Mon Sep 17 00:00:00 2001 From: Robert Vollmert Date: Sun, 8 Nov 2009 16:29:24 +0100 Subject: Move see_cell_no_trans into player. Also collect actor/player LOS code in actor-los.cc. --- crawl-ref/source/misc.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'crawl-ref/source/misc.cc') diff --git a/crawl-ref/source/misc.cc b/crawl-ref/source/misc.cc index 39271c1592..f209c8153f 100644 --- a/crawl-ref/source/misc.cc +++ b/crawl-ref/source/misc.cc @@ -1256,7 +1256,7 @@ void search_around(bool only_adjacent) for (radius_iterator ri(you.pos(), max_dist); ri; ++ri ) { // Must have LOS, with no translucent walls in the way. - if (see_cell_no_trans(*ri)) + if (you.see_cell_no_trans(*ri)) { // Maybe we want distance() instead of feat_distance()? int dist = grid_distance(*ri, you.pos()); @@ -2776,12 +2776,12 @@ bool mons_is_safe(const monsters *mon, bool want_move, // Only seen through glass walls or within water? // Assuming that there are no water-only/lava-only // monsters capable of throwing or zapping wands. - || (!see_cell_no_trans(mon->pos()) + || (!you.see_cell_no_trans(mon->pos()) || mons_class_habitat(mon->type) == HT_WATER || mons_class_habitat(mon->type) == HT_LAVA) && !_mons_has_path_to_player(mon) && !mons_has_los_attack(mon) - && (!see_cell_no_trans(mon->pos()) + && (!you.see_cell_no_trans(mon->pos()) || !mons_has_ranged_ability(mon))); #ifdef CLUA_BINDINGS -- cgit v1.2.3-54-g00ecf