]> granicus.if.org Git - nethack/commit
floor access
authornethack.rankin <nethack.rankin>
Sat, 4 Jun 2005 05:25:28 +0000 (05:25 +0000)
committernethack.rankin <nethack.rankin>
Sat, 4 Jun 2005 05:25:28 +0000 (05:25 +0000)
commitff16502d670ec59e12c4edb383a654d50d7c9f93
tree6cfda69382e08053f1c73768a5a2d0ac3002dc4d
parentff54d82b00872d9e82e3db74dff655e915a831bc
floor access

     A post-3.4.3 change dealing with reaching into pits resulted in "you
sit on the air" if you used the #sit command after escaping a pit trap.
Change can_reach_floor() so that caller explicitly controls whether being
on the brink of a pit is a condition that prevents reaching the floor.
This also splits a fairly common message about not being able to reach the
floor into a separate routine.

     There is still oddness here:  if you're polymorphed into a flyer,
#sit yields "you sit down" followed by "you fly over a pit" (latter occurs
when escaping trap activation).  A ceiling hider behaves similarly, but
the second message is "you escape a pit" and doesn't sound quite as silly.
Perhaps #sit should pass TOOKPLUNGE to dotrap(), or maybe there's some
better way to handle this?
13 files changed:
include/extern.h
src/apply.c
src/dig.c
src/do.c
src/eat.c
src/engrave.c
src/hack.c
src/invent.c
src/lock.c
src/pickup.c
src/potion.c
src/sit.c
src/trap.c