U761 - Sitting as a hider and other related is_hider behavior

While looking at the behavior of sitting hiders, I noticed other related
odd behavior.
- player hiding while poly'd as a hider that hangs on the ceiling now drops to
  the floor before sitting (similar to the behavior of movement commands).
- trappers, as per data.base, don't hang on the ceiling.  Changed the
  mattacku case dealing with hiders to not treat trappers as ceiling hiders.
- updated can_reach_floor to also exclude ceiling hiders.  This covers a
  bunch of cases, such as pickup, look-here-while-blind, and so on.  Another
  alternative would have been to automatically unhide for all such cases.
trunk only, it's a minor bug IMO and we appear to be close to a release.
This commit is contained in:
cohrs
2003-11-27 07:03:56 +00:00
parent cfa72fcee1
commit 70e25fa154
4 changed files with 21 additions and 9 deletions

View File

@@ -138,7 +138,9 @@ can_reach_floor()
!(u.usteed && P_SKILL(P_RIDING) < P_BASIC) &&
#endif
(!Levitation ||
Is_airlevel(&u.uz) || Is_waterlevel(&u.uz)));
Is_airlevel(&u.uz) || Is_waterlevel(&u.uz)) &&
(!u.uundetected || !is_hider(youmonst.data) ||
u.umonnum == PM_TRAPPER));
}
const char *