diff options
author | DracoOmega <draco_omega@live.com> | 2014-02-25 05:17:25 -0330 |
---|---|---|
committer | DracoOmega <draco_omega@live.com> | 2014-02-25 05:22:14 -0330 |
commit | 34e5dbe409485d8f0a69f5d486c04bb055013fa6 (patch) | |
tree | 228b4dc07bd0e59b2802f0df4a71866085ebaab3 /crawl-ref/source/mon-behv.cc | |
parent | b859c480c2e92fa42d481166c99477d15f9e48b9 (diff) | |
download | crawl-ref-34e5dbe409485d8f0a69f5d486c04bb055013fa6.tar.gz crawl-ref-34e5dbe409485d8f0a69f5d486c04bb055013fa6.zip |
Remove some (hopefully) useless behavior code
This block of code didn't actually seem to do what it claims it does
(since it doesn't set new foe properly and ends up getting reset before
the monster can even take a single action with the new values), and
it seems likely it would be bad if it actually did (allied monsters
randomly wandering off from the player for no reason?).
Behavioral code is convoluted enough as it is, without more bits of
it being maintained when they don't even do anything. (I hope.)
Diffstat (limited to 'crawl-ref/source/mon-behv.cc')
-rw-r--r-- | crawl-ref/source/mon-behv.cc | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/crawl-ref/source/mon-behv.cc b/crawl-ref/source/mon-behv.cc index fda0306657..8910ef0c1f 100644 --- a/crawl-ref/source/mon-behv.cc +++ b/crawl-ref/source/mon-behv.cc @@ -848,16 +848,7 @@ void handle_behaviour(monster* mon) // (or wasn't even attempted) and we need to set our target // the traditional way. - // Sometimes, your friends will wander a bit. - if (isFriendly && !mons_is_avatar(mon->type) - && one_chance_in(8)) - { - set_random_target(mon); - mon->foe = MHITNOT; - new_beh = BEH_WANDER; - } - else - mon->target = PLAYER_POS; + mon->target = PLAYER_POS; } else { |