summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/message.cc
diff options
context:
space:
mode:
authorzelgadis <zelgadis@c06c8d41-db1a-0410-9941-cceddc491573>2009-01-20 10:41:45 +0000
committerzelgadis <zelgadis@c06c8d41-db1a-0410-9941-cceddc491573>2009-01-20 10:41:45 +0000
commit9c8871bc3e50d51e3898ff5594b9d4f73f15c55b (patch)
tree1f440752e7877fb9e626fa44c35d82d154939d73 /crawl-ref/source/message.cc
parent68b3b5ac3474ceac470591c2a19e8e15b7d9d2ee (diff)
downloadcrawl-ref-9c8871bc3e50d51e3898ff5594b9d4f73f15c55b.tar.gz
crawl-ref-9c8871bc3e50d51e3898ff5594b9d4f73f15c55b.zip
Make extra-sure that a monster won't be announced to have come into view, only
to immediately move out of view, by introducing the notion of the currently acting monster to crawl_state, and only flushing out the "comes into view" message in mpr() for the currently acting monster. Not sure if it's worth it just for the sake of avoiding doing a "has this monster just now come into view" check in every place that a monster might issue a message, but at least this way we won't miss any places such a check should be placed. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8623 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/message.cc')
-rw-r--r--crawl-ref/source/message.cc5
1 files changed, 2 insertions, 3 deletions
diff --git a/crawl-ref/source/message.cc b/crawl-ref/source/message.cc
index 467b899600..063f6fa59e 100644
--- a/crawl-ref/source/message.cc
+++ b/crawl-ref/source/message.cc
@@ -463,11 +463,10 @@ void mpr(const char *inf, msg_channel_type channel, int param)
// Flush out any "comes into view" monster announcements before the
// monster has a chance to give any other messages.
- if (!_updating_view && you.turn_is_over
- && (you_are_delayed() || crawl_state.is_repeating_cmd()))
+ if (!_updating_view)
{
_updating_view = true;
- update_monsters_in_view();
+ flush_comes_into_view();
_updating_view = false;
}