From 6e304ee422e24338bde6ca84c420702d7d719993 Mon Sep 17 00:00:00 2001 From: dshaligram Date: Wed, 19 Nov 2008 18:02:31 +0000 Subject: Separate CHANCE and WEIGHT. CHANCE is a probability, WEIGHT is a raw number used as a generation weight (i.e. WEIGHT is what the old CHANCE used to be). git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@7501 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/mapdef.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'crawl-ref/source/mapdef.h') diff --git a/crawl-ref/source/mapdef.h b/crawl-ref/source/mapdef.h index 83098d2b5a..ca9da9c113 100644 --- a/crawl-ref/source/mapdef.h +++ b/crawl-ref/source/mapdef.h @@ -618,7 +618,10 @@ public: depth_ranges depths; map_section_type orient; + + int chance_priority; int chance; + int weight; std::vector welcome_messages; @@ -711,6 +714,7 @@ public: bool has_tag(const std::string &tag) const; bool has_tag_prefix(const std::string &tag) const; bool has_tag_suffix(const std::string &suffix) const; + std::vector get_tags() const; std::vector get_shuffle_strings() const; std::vector get_subst_strings() const; @@ -753,6 +757,8 @@ private: const std::string &s, bool fixed)); }; +const int CHANCE_ROLL = 10000; + std::string escape_string(std::string in, const std::string &toesc, const std::string &escapewith); -- cgit v1.2.3-54-g00ecf