Unaware; fix #H202 and extend the fix for #H179 (trunk only)
Turn being unconscious (via several reasons, including fainted from hunger) into a pseudo-property named `Unaware' and use it in several places where only being asleep was checked. #H202 was about a stunned character who got the recovery message when it timed out while fainted. This suppresses messages for several difficulties when they begin or end while hero is Unaware. Messages about fatal illness, sliming, or petrification aren't suppressed; they're too important to hide from the player. "You feel ..." messages come out as "You dream that you feel ..." when Unaware; fairly lame but hopefully adequate.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/* SCCS Id: @(#)youprop.h 3.5 1999/07/02 */
|
||||
/* SCCS Id: @(#)youprop.h 3.5 2006/09/01 */
|
||||
/* Copyright (c) 1989 Mike Threepoint */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
|
||||
@@ -359,5 +359,8 @@
|
||||
|
||||
#define Lifesaved u.uprops[LIFESAVED].extrinsic
|
||||
|
||||
/* unconscious() includes u.usleep but not is_fainted(); the multi test is
|
||||
redundant but allows the function calls to be skipped most of the time */
|
||||
#define Unaware (multi < 0 && (unconscious() || is_fainted()))
|
||||
|
||||
#endif /* YOUPROP_H */
|
||||
|
||||
Reference in New Issue
Block a user