From 0c229026108e080afa9774f5a77f28c29987e3e0 Mon Sep 17 00:00:00 2001 From: Matthew Cline Date: Sun, 25 Oct 2009 18:47:28 -0700 Subject: FR 2839615: comment on # of altars/shops sensed FR: Magic mapping now comments on the number of altars and shops/portals sensed. Also, take a note when a notable feature is first seen. --- crawl-ref/source/overmap.cc | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'crawl-ref/source/overmap.cc') diff --git a/crawl-ref/source/overmap.cc b/crawl-ref/source/overmap.cc index 4c66e7cdde..2a2ae64f63 100644 --- a/crawl-ref/source/overmap.cc +++ b/crawl-ref/source/overmap.cc @@ -186,6 +186,19 @@ bool overmap_knows_portal(dungeon_feature_type portal) return (false); } +int overmap_knows_num_portals(dungeon_feature_type portal) +{ + int num = 0; + for ( portal_map_type::const_iterator pl_iter = portals_present.begin(); + pl_iter != portals_present.end(); ++pl_iter ) + { + if (portal_to_feature(pl_iter->second) == portal) + num++; + } + + return (num); +} + static std::string _portals_description_string() { std::string disp; -- cgit v1.2.3-54-g00ecf