diff --git a/doc/fixes34.4 b/doc/fixes34.4 index 9757dd17f..47e8a23eb 100644 --- a/doc/fixes34.4 +++ b/doc/fixes34.4 @@ -336,6 +336,7 @@ when shopkeeper "gratefully inherits possessions" of hero who dies in shop doorway without owing the shop, move those items inside shop for bones dying in a shop while wielding two weapons could cause "Setworn: mask" warning make score file processing more bullet proof to avoid potential security issue +towel equipped in weapon, alternate weapon, or quiver slot can be applied Platform- and/or Interface-Specific Fixes diff --git a/src/apply.c b/src/apply.c index 3bb57f08c..58c36bc45 100644 --- a/src/apply.c +++ b/src/apply.c @@ -92,7 +92,7 @@ use_towel(obj) if(!freehand()) { You("have no free %s!", body_part(HAND)); return 0; - } else if (obj->owornmask) { + } else if (obj == ublindf) { You("cannot use it while you're wearing it!"); return 0; } else if (obj->cursed) { @@ -112,8 +112,11 @@ use_towel(obj) (old ? "has more" : "now has")); make_blinded(Blinded + (long)u.ucreamed - old, TRUE); } else { - const char *what = (ublindf->otyp == LENSES) ? - "lenses" : "blindfold"; + const char *what; + + what = (ublindf->otyp == LENSES) ? "lenses" : + (obj->otyp == ublindf->otyp) ? "other towel" : + "blindfold"; if (ublindf->cursed) { You("push your %s %s.", what, rn2(2) ? "cock-eyed" : "crooked");