diff options
author | Charles Otto <ottochar@gmail.com> | 2009-11-08 14:50:43 -0500 |
---|---|---|
committer | Charles Otto <ottochar@gmail.com> | 2009-11-08 14:55:42 -0500 |
commit | f5c61bd43ba6fc429cc424c0ea9acfd426c77b2c (patch) | |
tree | d3d45f56771ab74c92718babb359a4556c981696 /crawl-ref/source/fight.cc | |
parent | 9aa4d9bc6f48a9a2b81e7525b4ae142b60b11cbd (diff) | |
download | crawl-ref-f5c61bd43ba6fc429cc424c0ea9acfd426c77b2c.tar.gz crawl-ref-f5c61bd43ba6fc429cc424c0ea9acfd426c77b2c.zip |
Fix a crash when the player is hit by a distortion weapon
Diffstat (limited to 'crawl-ref/source/fight.cc')
-rw-r--r-- | crawl-ref/source/fight.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/crawl-ref/source/fight.cc b/crawl-ref/source/fight.cc index 39439c841d..8aef88b8a3 100644 --- a/crawl-ref/source/fight.cc +++ b/crawl-ref/source/fight.cc @@ -2256,7 +2256,8 @@ bool melee_attack::distortion_affects_defender() //jmf: blink frogs *like* distortion // I think could be amended to let blink frogs "grow" like // jellies do {dlb} - if (mons_genus(defender_as_monster()->type) == MONS_BLINK_FROG) + if (defender->atype() == ACT_MONSTER + && mons_genus(defender_as_monster()->type) == MONS_BLINK_FROG) { if (one_chance_in(5)) { |