summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/map_knowledge.cc
diff options
context:
space:
mode:
authorPekka Lampila <pekka.lampila@iki.fi>2013-05-07 19:52:42 +0300
committerNeil Moore <neil@s-z.org>2013-05-21 02:39:56 -0400
commit101dc42d3889a9951d348223134f5d34d0db9873 (patch)
treec0634f4af743e1640d341a61e4b15f86c51ddf1d /crawl-ref/source/map_knowledge.cc
parent3f3b1362c79ec4b6a15acbd1f870d296fe588c5a (diff)
downloadcrawl-ref-101dc42d3889a9951d348223134f5d34d0db9873.tar.gz
crawl-ref-101dc42d3889a9951d348223134f5d34d0db9873.zip
Fix rare case of out of LOS item not being drawn
Tiles only. Could also be another foreground feature (cloud) instead of an item. This would happen when an out of LOS monster tile was removed. Rename tile_clear_monster to tile_reset_fg and have it reset the foreground tile, instead of just clearing it. Also make clear_map function work properly on tiles even when clear_mons=false.
Diffstat (limited to 'crawl-ref/source/map_knowledge.cc')
-rw-r--r--crawl-ref/source/map_knowledge.cc5
1 files changed, 2 insertions, 3 deletions
diff --git a/crawl-ref/source/map_knowledge.cc b/crawl-ref/source/map_knowledge.cc
index 85cd0ce77b..6a3486477e 100644
--- a/crawl-ref/source/map_knowledge.cc
+++ b/crawl-ref/source/map_knowledge.cc
@@ -80,12 +80,11 @@ void clear_map(bool clear_items, bool clear_mons)
cell.clear_item();
if (clear_mons && !mons_class_is_stationary(cell.monster()))
- {
cell.clear_monster();
+
#ifdef USE_TILE
- tile_clear_monster(p);
+ tile_reset_fg(p);
#endif
- }
}
}