summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/player.cc
diff options
context:
space:
mode:
authorj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2008-05-25 17:39:04 +0000
committerj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2008-05-25 17:39:04 +0000
commitf5526da8ba8130dd9f03e7e97406537d95866268 (patch)
tree7c98b03f098b2eec5fa797ae4d836e655f3f1b42 /crawl-ref/source/player.cc
parent63e4083df060b3cdd0ce18d04949dd7831cc10d4 (diff)
downloadcrawl-ref-f5526da8ba8130dd9f03e7e97406537d95866268.tar.gz
crawl-ref-f5526da8ba8130dd9f03e7e97406537d95866268.zip
Force fleeing monsters to "turn to fight" before breathing at you.
(Fixes 1967981: TSO punishes fighting back against "helpless" fleeing monsters.) git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@5236 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/player.cc')
-rw-r--r--crawl-ref/source/player.cc36
1 files changed, 18 insertions, 18 deletions
diff --git a/crawl-ref/source/player.cc b/crawl-ref/source/player.cc
index ee24dc3615..21f45ae029 100644
--- a/crawl-ref/source/player.cc
+++ b/crawl-ref/source/player.cc
@@ -4003,7 +4003,7 @@ void display_char_status()
(ustealth < 220) ? "very " :
(ustealth < 300) ? "extremely " :
(ustealth < 400) ? "extraordinarily " :
- (ustealth < 520) ? "incredibly "
+ (ustealth < 520) ? "incredibly "
: "uncannily ");
#if DEBUG_DIAGNOSTICS
@@ -5776,8 +5776,8 @@ int player::damage_type(int)
{
return (get_vorpal_type(inv[wpn]));
}
- else if (equip[EQ_GLOVES] == -1 &&
- attribute[ATTR_TRANSFORMATION] == TRAN_BLADE_HANDS)
+ else if (equip[EQ_GLOVES] == -1
+ && attribute[ATTR_TRANSFORMATION] == TRAN_BLADE_HANDS)
{
return (DVORP_SLICING);
}
@@ -6619,16 +6619,16 @@ void PlaceInfo::make_global()
void PlaceInfo::assert_validity() const
{
// Check that level_type and branch match up
- ASSERT(is_global() ||
- (level_type == LEVEL_DUNGEON && branch >= BRANCH_MAIN_DUNGEON &&
- branch < NUM_BRANCHES) ||
- (level_type > LEVEL_DUNGEON && level_type < NUM_LEVEL_AREA_TYPES &&
- branch == -1));
+ ASSERT(is_global()
+ || level_type == LEVEL_DUNGEON && branch >= BRANCH_MAIN_DUNGEON
+ && branch < NUM_BRANCHES
+ || level_type > LEVEL_DUNGEON && level_type < NUM_LEVEL_AREA_TYPES
+ && branch == -1);
// Can't have visited a place without seeing any of its levels, and
// visa versa
- ASSERT((num_visits == 0 && levels_seen == 0) ||
- (num_visits > 0 && levels_seen > 0));
+ ASSERT(num_visits == 0 && levels_seen == 0
+ || num_visits > 0 && levels_seen > 0);
if (level_type == LEVEL_LABYRINTH || level_type == LEVEL_ABYSS)
ASSERT(num_visits == levels_seen);
@@ -6637,12 +6637,12 @@ void PlaceInfo::assert_validity() const
else if (level_type == LEVEL_DUNGEON && branches[branch].depth > 0)
ASSERT(levels_seen <= (unsigned long) branches[branch].depth);
- ASSERT(turns_total == (turns_explore + turns_travel + turns_interlevel +
- turns_resting + turns_other));
+ ASSERT(turns_total == (turns_explore + turns_travel + turns_interlevel
+ + turns_resting + turns_other));
- ASSERT(elapsed_total == (elapsed_explore + elapsed_travel +
- elapsed_interlevel + elapsed_resting +
- elapsed_other));
+ ASSERT(elapsed_total == (elapsed_explore + elapsed_travel
+ + elapsed_interlevel + elapsed_resting
+ + elapsed_other));
}
const std::string PlaceInfo::short_name() const
@@ -6759,9 +6759,9 @@ PlaceInfo& player::get_place_info(level_area_type level_type2) const
PlaceInfo& player::get_place_info(branch_type branch,
level_area_type level_type2) const
{
- ASSERT((level_type2 == LEVEL_DUNGEON && branch >= BRANCH_MAIN_DUNGEON &&
- branch < NUM_BRANCHES) ||
- (level_type2 > LEVEL_DUNGEON && level_type < NUM_LEVEL_AREA_TYPES));
+ ASSERT(level_type2 == LEVEL_DUNGEON && branch >= BRANCH_MAIN_DUNGEON
+ && branch < NUM_BRANCHES
+ || level_type2 > LEVEL_DUNGEON && level_type < NUM_LEVEL_AREA_TYPES);
if (level_type2 == LEVEL_DUNGEON)
return (PlaceInfo&) branch_info[branch];