summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/branch.h
diff options
context:
space:
mode:
authorAdam Borowski <kilobyte@angband.pl>2012-08-26 23:10:12 +0200
committerAdam Borowski <kilobyte@angband.pl>2012-08-27 00:23:29 +0200
commita4cafc8eb2c70a0fbefde91bd49f8c65e4e3b292 (patch)
tree064b2ee3e8e3ff092f97e96d335fe0a1799c9494 /crawl-ref/source/branch.h
parent82ae3fd9ebe156f2adc4ac9ad22e06361607cd4b (diff)
downloadcrawl-ref-a4cafc8eb2c70a0fbefde91bd49f8c65e4e3b292.tar.gz
crawl-ref-a4cafc8eb2c70a0fbefde91bd49f8c65e4e3b292.zip
Convert mon-pick data to a more readable scheme.
Instead of a base level and a rarity, which then use a ridiculously obscure algorithm to accept or reject monsters, the new data includes: * minimal depth the monster can be found on * maximal depth * rarity at the center of the range * distribution type (flat, a linear triangle, something halfway between the two) * the monster's enum The results should be the same, with very minor differences: * distributions within allowed range are approximated by one of three shapes (FLAT, SEMI, PEAK), this shouldn't produce noticeable differences * effective rarity has been shoehorned into a 0..1000 range (out of 0..10201), using div_rand_round(). There's a number of monsters with 35/10201 rarity which ends up as 3 or 4, and strings of monsters of the same rarity end up randomly perturbed. * the once-in-the-life-of-universe chance to generate a monster outside the -5..+5 range is gone, you can now set arbitrary ranges and they're absolute. There's no actual code to use this data yet, merely an emulation of the old functions. It looks like ZotDef applies some complex rules to the monster's depth, it may take some thinking about how to convert it.
Diffstat (limited to 'crawl-ref/source/branch.h')
-rw-r--r--crawl-ref/source/branch.h2
1 files changed, 0 insertions, 2 deletions
diff --git a/crawl-ref/source/branch.h b/crawl-ref/source/branch.h
index 0febc09e5c..04c2e9dbab 100644
--- a/crawl-ref/source/branch.h
+++ b/crawl-ref/source/branch.h
@@ -39,8 +39,6 @@ struct Branch
bool has_uniques;
colour_t floor_colour; // Zot needs special handling.
colour_t rock_colour;
- int (*mons_rarity_function)(monster_type);
- int (*mons_level_function)(monster_type);
int travel_shortcut; // Which key to press for travel.
bool dangerous_bottom_level; // bottom level is more dangerous than normal
int ambient_noise; // affects noise loudness and player stealth