]> granicus.if.org Git - nethack/commit
fix #H11 - forcing lock with mattock
authornethack.rankin <nethack.rankin>
Tue, 3 Jan 2006 05:28:13 +0000 (05:28 +0000)
committernethack.rankin <nethack.rankin>
Tue, 3 Jan 2006 05:28:13 +0000 (05:28 +0000)
commit3d97eafe18ba78f9f9842f0b220ce0800bf0ab55
tree032c99816287dc91f682bb4516a2a5b287cbdd0d
parentfe5d79c85943314831f6a0a931aece8401462194
fix #H11 - forcing lock with mattock

     From a bug report:  dwarvish mattock was
subject to breaking when attempting to force a lock, because it is treated
as a bladed weapon.  So is pick-axe; they're both defined as blunt (WHACK
attack mode), but the definition of is_blade() erroneously includes them
since P_PICK_AXE falls between P_DAGGER and P_SABER.  That skill should be
renumbered, but I haven't investigated what else might happen when that's
done so this fix uses a special case instead.

     I noticed that there was an unnecessary old check for rubber hose;
it's excluded along with whip by the skill > P_LANCE test.  When fixing
that up, I realized that the obscure feature of forcing via statue was
broken; it always failed the skill < P_DAGGER test.  Also, I took away the
exception for aklys; even though designed as a throwing weapon, it is used
as a club.  I wasn't sure about the exception for flail; it is perfectly
capable of bashing things but the code apparently excludes it for use as
a prying implement.  Switching its check to P_FLAIL catches grappling hook
along with it.
doc/fixes34.4
src/lock.c