From 74c535b701b7642b74b45934e78cadd7ab67a0e4 Mon Sep 17 00:00:00 2001 From: Stefan O'Rear Date: Wed, 30 Dec 2009 03:27:21 -0800 Subject: Ignore obscured items in the UI I probably missed a few spots. --- crawl-ref/source/player.cc | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'crawl-ref/source/player.cc') diff --git a/crawl-ref/source/player.cc b/crawl-ref/source/player.cc index e490908d1b..564bf18de1 100644 --- a/crawl-ref/source/player.cc +++ b/crawl-ref/source/player.cc @@ -5549,6 +5549,17 @@ bool player::can_swim() const return (species == SP_MERFOLK && merfolk_change_is_safe(true)); } +int player::visible_igrd(const coord_def &where) const +{ + if (grd(where) == DNGN_LAVA + || (grd(where) == DNGN_DEEP_WATER && species != SP_MERFOLK)) + { + return (NON_ITEM); + } + + return igrd(where); +} + bool player::swimming() const { return in_water() && can_swim(); -- cgit v1.2.3-54-g00ecf