diff options
author | Raphael Langella <raphael.langella@gmail.com> | 2013-11-30 00:12:02 +0100 |
---|---|---|
committer | Raphael Langella <raphael.langella@gmail.com> | 2013-11-30 00:41:16 +0100 |
commit | 8471a022e76bae39918ba6eaa1fbbab5c7ceb64f (patch) | |
tree | 8baf38a5af7637040801a09604cb7519040cf209 /crawl-ref/source/message.cc | |
parent | cf2260f169a7bf134e63f2d08526739656ca7716 (diff) | |
download | crawl-ref-8471a022e76bae39918ba6eaa1fbbab5c7ceb64f.tar.gz crawl-ref-8471a022e76bae39918ba6eaa1fbbab5c7ceb64f.zip |
Delay more prompt until level has finished loading.
Getting a more prompt during level load results in a screen only partially
updated and looking really bugged. It's especially bad since it happened
during loading tutorial levels which is the very first thing many new player
see. It also happened when entering a level with an announce portal. If there
are more cases, I didn't test them.
Diffstat (limited to 'crawl-ref/source/message.cc')
-rw-r--r-- | crawl-ref/source/message.cc | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/crawl-ref/source/message.cc b/crawl-ref/source/message.cc index eefe7ec747..6b743793db 100644 --- a/crawl-ref/source/message.cc +++ b/crawl-ref/source/message.cc @@ -566,6 +566,12 @@ public: */ void more(bool full, bool user=false) { + if (crawl_state.loading_level) + { + crawl_state.delayed_more = true; + return; + } + if (_pre_more()) return; @@ -1545,6 +1551,15 @@ void more(bool user_forced) mesclr(); } +void pop_delayed_more() +{ + if (!crawl_state.delayed_more) + return; + ASSERT(!crawl_state.loading_level); + crawl_state.delayed_more = false; + more(); +} + static bool is_channel_dumpworthy(msg_channel_type channel) { return channel != MSGCH_EQUIPMENT |