diff options
author | Stefan O'Rear <stefanor@cox.net> | 2009-12-30 03:27:21 -0800 |
---|---|---|
committer | Stefan O'Rear <stefanor@cox.net> | 2009-12-30 03:27:57 -0800 |
commit | 74c535b701b7642b74b45934e78cadd7ab67a0e4 (patch) | |
tree | d80cb308cfc2ccc45a9e7b47f085a0abe24369c0 /crawl-ref/source/show.cc | |
parent | a144abbba078cf5ec99f570f7b81da564577636a (diff) | |
download | crawl-ref-74c535b701b7642b74b45934e78cadd7ab67a0e4.tar.gz crawl-ref-74c535b701b7642b74b45934e78cadd7ab67a0e4.zip |
Ignore obscured items in the UI
I probably missed a few spots.
Diffstat (limited to 'crawl-ref/source/show.cc')
-rw-r--r-- | crawl-ref/source/show.cc | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/crawl-ref/source/show.cc b/crawl-ref/source/show.cc index 103d00b09d..0148d92438 100644 --- a/crawl-ref/source/show.cc +++ b/crawl-ref/source/show.cc @@ -224,8 +224,8 @@ void show_def::_update_item_at(const coord_def &gp, const coord_def &ep) const monsters* m = monster_at(gp); if (m && mons_is_unknown_mimic(m)) eitem = &get_mimic_item(m); - else if (igrd(gp) != NON_ITEM) - eitem = &mitm[igrd(gp)]; + else if (you.visible_igrd(gp) != NON_ITEM) + eitem = &mitm[you.visible_igrd(gp)]; else return; @@ -235,10 +235,6 @@ void show_def::_update_item_at(const coord_def &gp, const coord_def &ep) const dungeon_feature_type feat = grd(gp); - if ((feat == DNGN_DEEP_WATER && you.species != SP_MERFOLK) - || feat == DNGN_LAVA) - return; - if (Options.feature_item_brand && is_critical_feature(feat)) ecol |= COLFLAG_FEATURE_ITEM; else if (Options.trap_item_brand && feat_is_trap(feat)) @@ -251,7 +247,7 @@ void show_def::_update_item_at(const coord_def &gp, const coord_def &ep) ecol = _feat_colour(gp, feat); // monster(mimic)-owned items have link = NON_ITEM+1+midx - if (eitem->link > NON_ITEM && igrd(gp) != NON_ITEM) + if (eitem->link > NON_ITEM && you.visible_igrd(gp) != NON_ITEM) ecol |= COLFLAG_ITEM_HEAP; else if (eitem->link < NON_ITEM && !crawl_state.arena) ecol |= COLFLAG_ITEM_HEAP; @@ -260,7 +256,7 @@ void show_def::_update_item_at(const coord_def &gp, const coord_def &ep) } #ifdef USE_TILE - int idx = igrd(gp); + int idx = you.visible_igrd(gp); if (idx != NON_ITEM) { if (feat_is_stair(feat)) |