Merge branch 'master' into derek-farming
* master: (41 commits) Add more explicit helpless reasons add data.base suggestion for whistle Use existing function to count containers ... Conflicts: src/do.c src/hack.c src/invent.c src/mon.c src/objnam.c
This commit is contained in:
20
src/objnam.c
20
src/objnam.c
@@ -497,6 +497,11 @@ register struct obj *obj;
|
||||
}
|
||||
if (pluralize) Strcpy(buf, makeplural(buf));
|
||||
|
||||
if (obj->otyp == T_SHIRT && program_state.gameover) {
|
||||
char tmpbuf[BUFSZ];
|
||||
Sprintf(eos(buf), " with text \"%s\"", tshirt_text(obj, tmpbuf));
|
||||
}
|
||||
|
||||
if (has_oname(obj) && dknown) {
|
||||
Strcat(buf, " named ");
|
||||
nameit:
|
||||
@@ -659,8 +664,9 @@ register struct obj *obj;
|
||||
*/
|
||||
register char *bp = xname(obj);
|
||||
|
||||
if (iflags.override_ID) known = cknown = bknown = lknown = TRUE;
|
||||
else {
|
||||
if (iflags.override_ID) {
|
||||
known = cknown = bknown = lknown = TRUE;
|
||||
} else {
|
||||
known = obj->known;
|
||||
cknown = obj->cknown;
|
||||
bknown = obj->bknown;
|
||||
@@ -693,7 +699,15 @@ register struct obj *obj;
|
||||
|
||||
/* "empty" goes at the beginning, but item count goes at the end */
|
||||
if (cknown &&
|
||||
(Is_container(obj) || obj->otyp == STATUE) && !Has_contents(obj))
|
||||
/* bag of tricks: include "empty" prefix if it's known to
|
||||
be empty but its precise number of charges isn't known
|
||||
(when that is known, suffix of "(n:0)" will be appended,
|
||||
making the prefix be redundant; note that 'known' flag
|
||||
isn't set when emptiness gets discovered because then
|
||||
charging magic would yield known number of new charges) */
|
||||
(obj->otyp == BAG_OF_TRICKS ? (obj->spe == 0 && !obj->known) :
|
||||
/* not bag of tricks: empty if container which has no contents */
|
||||
(Is_container(obj) || obj->otyp == STATUE) && !Has_contents(obj)))
|
||||
Strcat(prefix, "empty ");
|
||||
|
||||
if (bknown &&
|
||||
|
||||
Reference in New Issue
Block a user