fix engraving with miscellaneous items

Reported directly to devteam:  when selecting an item to engrave
with, "getobj refactor"'s stylus_ok() classified none-of-the-above
objects as not viable instead of allowing arbitrary things to
engrave in the dust or give specific can't-use-that messages like
for food.  Make the suggested fix:  change default result when
checking an inventory item for applicability from GETOBJ_EXCLUDE
to GETOBJ_DOWNPLAY.

Engrave feedback rather than getobj selection:  splash of venom
isn't necessarily wizard mode-only so don't reject attempting to
engrave with it as using an illegal object.  And remove the extra
question mark from its "poison pen" message.
This commit is contained in:
PatR
2021-08-05 12:32:30 -07:00
parent fdf0bfd8a4
commit 91ee7f28ee
2 changed files with 8 additions and 6 deletions

View File

@@ -442,7 +442,7 @@ stylus_ok(struct obj *obj)
&& (obj->otyp == TOWEL || obj->otyp == MAGIC_MARKER))
return GETOBJ_SUGGEST;
return GETOBJ_EXCLUDE;
return GETOBJ_DOWNPLAY;
}
/* can hero engrave at all (at their location)? */
@@ -879,11 +879,12 @@ doengrave(void)
break;
case VENOM_CLASS:
if (wizard) {
pline("Writing a poison pen letter??");
break;
}
/*FALLTHRU*/
/* this used to be ``if (wizard)'' and fall through to ILLOBJ_CLASS
for normal play, but splash of venom isn't "illegal" because it
could occur in normal play via wizard mode bones */
pline("Writing a poison pen letter?");
break;
case ILLOBJ_CLASS:
impossible("You're engraving with an illegal object!");
break;