summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/mgen_data.h
diff options
context:
space:
mode:
authorDarshan Shaligram <dshaligram@users.sourceforge.net>2010-05-02 18:46:19 +0530
committerDarshan Shaligram <dshaligram@users.sourceforge.net>2010-05-02 18:51:13 +0530
commitd306c4aa1d69a02e54fee41a32c2e99cf82947d6 (patch)
tree41487905ce182ec7bc3b0193cea8bfc22c387a0e /crawl-ref/source/mgen_data.h
parent1495326af3d63bf132079af93d13e1575ee11317 (diff)
downloadcrawl-ref-d306c4aa1d69a02e54fee41a32c2e99cf82947d6.tar.gz
crawl-ref-d306c4aa1d69a02e54fee41a32c2e99cf82947d6.zip
Place Shoals monsters on land if possible to reduce empty-Shoals-syndrome from all monsters sleeping in water far from land (rob).
Diffstat (limited to 'crawl-ref/source/mgen_data.h')
-rw-r--r--crawl-ref/source/mgen_data.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/crawl-ref/source/mgen_data.h b/crawl-ref/source/mgen_data.h
index 31aefcbc3b..8fbf726532 100644
--- a/crawl-ref/source/mgen_data.h
+++ b/crawl-ref/source/mgen_data.h
@@ -38,6 +38,14 @@ struct mgen_data
// Where the monster will be created.
coord_def pos;
+ // A grid feature to prefer when finding a place to create monsters.
+ // For instance, using DNGN_FLOOR when placing flying monsters or
+ // merfolk in the Shoals will force them to appear on land.
+ // preferred_grid_feature will be ignored if it is incompatible with
+ // the monster's native habitat (for instance, if trying to place
+ // a big fish with preferred_grid_feature DNGN_FLOOR).
+ dungeon_feature_type preferred_grid_feature;
+
// The monster's foe, i.e. which monster it will want to attack. foe
// may be an index into the monster array (0 - (MAX_MONSTERS-1)), or
// it may be MHITYOU to indicate that the monster wants to attack the
@@ -125,8 +133,9 @@ struct mgen_data
std::string nas = "")
: cls(mt), base_type(base), behaviour(beh), summoner(sner),
- abjuration_duration(abj), summon_type(st), pos(p), foe(mfoe),
- flags(monflags), god(which_god), number(monnumber), colour(moncolour),
+ abjuration_duration(abj), summon_type(st), pos(p),
+ preferred_grid_feature(DNGN_UNSEEN), foe(mfoe), flags(monflags),
+ god(which_god), number(monnumber), colour(moncolour),
power(monpower), proximity(prox), level_type(ltype), map_mask(0),
hd(mhd), hp(mhp), extra_flags(mflags), mname(monname),
non_actor_summoner(nas), props()