summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/view.cc
diff options
context:
space:
mode:
authorzelgadis <zelgadis@c06c8d41-db1a-0410-9941-cceddc491573>2009-05-25 07:09:56 +0000
committerzelgadis <zelgadis@c06c8d41-db1a-0410-9941-cceddc491573>2009-05-25 07:09:56 +0000
commit781c1cda9ce49cec2064cbf438e52ef6aaff41a3 (patch)
tree27f2e13f6ddc8307b10efdb99935bc1fcbb2f2ab /crawl-ref/source/view.cc
parent7a3b0b0a92e9e07200a598d743af697c9ea6aae8 (diff)
downloadcrawl-ref-781c1cda9ce49cec2064cbf438e52ef6aaff41a3.tar.gz
crawl-ref-781c1cda9ce49cec2064cbf438e52ef6aaff41a3.zip
Added some new tutorial events (not tested with the tile build):
* Auto-explore hint (200 turns after level map hint). * Explanation of the "Your equipment suddenly weighs less" message. * Explanations of trap and heap branding (non-tile builds only). * A note that monsters that have moved out of LOS haven't just vanished. * Events for gaining an ability from a mutation and gaining one from an item which was just equipped, separate from the event for the first divinely granted ability. * An explanation that shouting monsters have just noticed you, plus that their shout is likely to attract the attention of other monsters. * A "seen portal vault entrance" event, since the entry to the sewers can appear on DL 3 through 6, and there's also a very small chance of a Zigguart entrance apearing as early as DL 3. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@9823 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/view.cc')
-rw-r--r--crawl-ref/source/view.cc11
1 files changed, 8 insertions, 3 deletions
diff --git a/crawl-ref/source/view.cc b/crawl-ref/source/view.cc
index 91077e12df..4cbd7f586e 100644
--- a/crawl-ref/source/view.cc
+++ b/crawl-ref/source/view.cc
@@ -1214,9 +1214,11 @@ void handle_monster_shouts(monsters* monster, bool force)
}
}
- const int noise_level = get_shout_noise_level(s_type);
- if (noise_level > 0)
- noisy(noise_level, monster->pos());
+ const int noise_level = get_shout_noise_level(s_type);
+ const bool heard = noisy(noise_level, monster->pos());
+
+ if (Options.tutorial_left && (heard || you.can_see(monster)))
+ learned_something_new(TUT_MONSTER_SHOUT, monster->pos());
}
#ifdef WIZARD
@@ -1624,6 +1626,9 @@ bool noisy(int loudness, const coord_def& where, const char *msg, bool mermaid)
{
bool ret = false;
+ if (loudness <= 0)
+ return (false);
+
// If the origin is silenced there is no noise.
if (silenced(where))
return (false);