diff options
author | Charles Otto <ottochar@gmail.com> | 2009-10-06 22:27:07 -0400 |
---|---|---|
committer | Charles Otto <ottochar@gmail.com> | 2009-10-06 22:31:25 -0400 |
commit | c2c25b5eaa191b0d26aee47359949093367154b9 (patch) | |
tree | 6ac6a73ff6053f17fce2e66e8e441978c2729d36 /crawl-ref/source/directn.cc | |
parent | 0e2154d50e2de944bb1495b6ad4a62112ee97f03 (diff) | |
download | crawl-ref-c2c25b5eaa191b0d26aee47359949093367154b9.tar.gz crawl-ref-c2c25b5eaa191b0d26aee47359949093367154b9.zip |
Implement FR 2872334 'don't auto-target neutrals' by replacing most uses of TARG_ENEMY with TARG_HOSTILE.
Diffstat (limited to 'crawl-ref/source/directn.cc')
-rw-r--r-- | crawl-ref/source/directn.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/crawl-ref/source/directn.cc b/crawl-ref/source/directn.cc index 56258157f2..ed71bbebb1 100644 --- a/crawl-ref/source/directn.cc +++ b/crawl-ref/source/directn.cc @@ -419,7 +419,9 @@ static void _direction_again(dist& moves, targetting_type restricts, moves.target = you.pos(); // Discard 'Y' player gave to yesno() - if (mode == TARG_ENEMY) + // Changed this, was that necessary? -cao + //if (mode == TARG_ENEMY) + if (mode == TARG_ENEMY || mode == TARG_HOSTILE) getchm(); } else @@ -932,7 +934,8 @@ bool _dist_ok(const dist& moves, int range, targ_mode_type mode, return (false); } - if (!may_target_self && mode == TARG_ENEMY) + if (!may_target_self && (mode == TARG_ENEMY + || mode == TARG_HOSTILE)) { if (Options.allow_self_target == CONFIRM_CANCEL) { |