diff options
author | haranp <haranp@c06c8d41-db1a-0410-9941-cceddc491573> | 2009-02-19 11:40:35 +0000 |
---|---|---|
committer | haranp <haranp@c06c8d41-db1a-0410-9941-cceddc491573> | 2009-02-19 11:40:35 +0000 |
commit | 65a126fb1af16a29c81777ae6885292124713633 (patch) | |
tree | 649868b50b70813b7cada32ed5c935c7445c148e /crawl-ref/source/monstuff.cc | |
parent | 55cbef395f4acfda30fdcca08b1f9170a5a0b73f (diff) | |
download | crawl-ref-65a126fb1af16a29c81777ae6885292124713633.tar.gz crawl-ref-65a126fb1af16a29c81777ae6885292124713633.zip |
Don't allow monsters to walk into you and continue playing innocent.
Fixes [2021213].
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@9128 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/monstuff.cc')
-rw-r--r-- | crawl-ref/source/monstuff.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/crawl-ref/source/monstuff.cc b/crawl-ref/source/monstuff.cc index 81d2c0cd67..c0fdc05ec8 100644 --- a/crawl-ref/source/monstuff.cc +++ b/crawl-ref/source/monstuff.cc @@ -7322,6 +7322,10 @@ static void _handle_monster_move(monsters *monster) if (!mons_friendly(monster)) { + // If it steps into you, cancel other targets. + monster->foe = MHITYOU; + monster->target = you.pos(); + monster_attack(monster); if (mons_is_batty(monster)) |