summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/xom.h
diff options
context:
space:
mode:
authorJohanna Ploog <j-p-e-g@users.sourceforge.net>2009-12-18 23:30:57 +0100
committerJohanna Ploog <j-p-e-g@users.sourceforge.net>2009-12-18 23:52:19 +0100
commitb2f09ceeac848937906311367ed2072255f93464 (patch)
treef7779713e22f428a2dfb56823e73bf9535d6bbc6 /crawl-ref/source/xom.h
parentad2ab460048119f15ece7a885098426c2b5e7b33 (diff)
downloadcrawl-ref-b2f09ceeac848937906311367ed2072255f93464.tar.gz
crawl-ref-b2f09ceeac848937906311367ed2072255f93464.zip
Sometimes suppress good Xom events at 0 tension, bad acts at tension > 0.
Note that a good act is not changed to a bad one, or vice versa. Rather, Xom simply doesn't act after all, so that overall, bad acts become more likely when the player is just walking around, without actually making the game nastier. This should make the tension effect actually noticeable in-game. Hopefully, this will also reduce the number of item gifts while simply walking around.
Diffstat (limited to 'crawl-ref/source/xom.h')
-rw-r--r--crawl-ref/source/xom.h36
1 files changed, 19 insertions, 17 deletions
diff --git a/crawl-ref/source/xom.h b/crawl-ref/source/xom.h
index 50f670e15a..df8f6fa285 100644
--- a/crawl-ref/source/xom.h
+++ b/crawl-ref/source/xom.h
@@ -23,47 +23,49 @@ enum xom_event_type
XOM_DID_NOTHING = 0,
// good acts
+ XOM_GOOD_NOTHING, // good act suppressed
XOM_GOOD_POTION,
XOM_GOOD_SPELL_TENSION,
XOM_GOOD_SPELL_CALM,
- XOM_GOOD_MAPPING,
- XOM_GOOD_CONFUSION, // 5
+ XOM_GOOD_MAPPING, // 5
+ XOM_GOOD_CONFUSION,
XOM_GOOD_SINGLE_ALLY,
XOM_GOOD_ANIMATE_MON_WPN,
XOM_GOOD_ANNOYANCE_GIFT,
- XOM_GOOD_RANDOM_ITEM,
- XOM_GOOD_ACQUIREMENT, // 10
+ XOM_GOOD_RANDOM_ITEM, // 10
+ XOM_GOOD_ACQUIREMENT,
XOM_GOOD_ALLIES,
XOM_GOOD_POLYMORPH,
XOM_GOOD_SWAP_MONSTERS,
- XOM_GOOD_TELEPORT,
- XOM_GOOD_VITRIFY, // 15
+ XOM_GOOD_TELEPORT, // 15
+ XOM_GOOD_VITRIFY,
XOM_GOOD_MUTATION,
XOM_GOOD_MAJOR_ALLY,
XOM_GOOD_LIGHTNING,
XOM_GOOD_SCENERY,
- XOM_LAST_GOOD_ACT = XOM_GOOD_SCENERY, // 19
+ XOM_LAST_GOOD_ACT = XOM_GOOD_SCENERY, // 20
// bad acts
- XOM_BAD_MISCAST_PSEUDO, // 20
+ XOM_BAD_NOTHING, // bad act suppressed
+ XOM_BAD_MISCAST_PSEUDO,
XOM_BAD_MISCAST_MINOR,
XOM_BAD_MISCAST_MAJOR,
- XOM_BAD_MISCAST_NASTY,
+ XOM_BAD_MISCAST_NASTY, // 25
XOM_BAD_STATLOSS,
- XOM_BAD_TELEPORT, // 25
+ XOM_BAD_TELEPORT,
XOM_BAD_SWAP_WEAPONS,
XOM_BAD_CHAOS_UPGRADE,
- XOM_BAD_MUTATION,
+ XOM_BAD_MUTATION, // 30
XOM_BAD_POLYMORPH,
- XOM_BAD_STAIRS, // 30
+ XOM_BAD_STAIRS,
XOM_BAD_CONFUSION,
XOM_BAD_DRAINING,
- XOM_BAD_TORMENT,
+ XOM_BAD_TORMENT, // 35
XOM_BAD_ANIMATE_WPN,
- XOM_BAD_SUMMON_DEMONS, // 35
+ XOM_BAD_SUMMON_DEMONS,
XOM_BAD_PSEUDO_BANISHMENT,
XOM_BAD_BANISHMENT,
- XOM_LAST_BAD_ACT = XOM_BAD_BANISHMENT, // 37
+ XOM_LAST_BAD_ACT = XOM_BAD_BANISHMENT, // 39
XOM_PLAYER_DEAD = 100, // player already dead (shouldn't happen)
NUM_XOM_EVENTS
@@ -79,9 +81,9 @@ bool xom_is_nice(int tension = -1);
int xom_acts(bool niceness, int sever, int tension = -1, bool debug = false);
const char *describe_xom_favour(bool upper = false);
-inline void xom_acts(int sever, int tension = -1)
+inline int xom_acts(int sever, int tension = -1)
{
- xom_acts(xom_is_nice(tension), sever, tension);
+ return xom_acts(xom_is_nice(tension), sever, tension);
}
void xom_check_lost_item(const item_def& item);