fix #Q235 - rubbing against known touchstones

Allow rubbing any object against any touchstone even when the latter
is known so only gems make sense.  Also, propagate an earlier fix which
allowed rubbing gold against known touchstones to the branch (it had been
trunk only).
This commit is contained in:
nethack.rankin
2005-11-29 02:28:52 +00:00
parent 121a49cdcd
commit 6708e01a47
3 changed files with 8 additions and 5 deletions

View File

@@ -156,6 +156,8 @@ avoid inappropriate "the guard calms down" if vault guard's magic corridor
reaches a spot where gold is embedded in the rock
adjust message for gas effect from chest trap if hero resists hallucination
cancelling non-shop objects in a shop's entrance would upset the shopkeeper
identified touchstone can rub on gold like the data.base entry says
restore the capability of rubbing any object against known touchstone
Platform- and/or Interface-Specific Fixes

View File

@@ -20,7 +20,6 @@ two-weapon combat makes two attacks instead of having one attack hit with
apply weapon skill to-hit bonus or penalty to bare-handed attacks
only give monk's "cumbersome armor" message when the armor penalty causes
an attack to miss
identified touchstone can rub on gold like the data.base entry says
dust vortex-induced blindness should kick in immediately when blindfold
is removed or glop is wiped off
prayer/unicorn-horn won't fix blindness while still engulfed in a dust

View File

@@ -871,9 +871,6 @@ register const char *let,*word;
otyp != OIL_LAMP && otyp != MAGIC_LAMP &&
otyp != BRASS_LANTERN) ||
(otmp->oclass == GEM_CLASS && !is_graystone(otmp))))
|| (!strncmp(word, "rub on the stone", 16) &&
*let == GEM_CLASS && /* using known touchstone */
otmp->dknown && objects[otyp].oc_name_known)
|| ((!strcmp(word, "use or apply") ||
!strcmp(word, "untrap with")) &&
/* Picks, axes, pole-weapons, bullwhips */
@@ -904,7 +901,12 @@ register const char *let,*word;
foo--;
/* ugly check for unworn armor that can't be worn */
else if (putting_on(word) && *let == ARMOR_CLASS &&
!canwearobj(otmp, &dummymask, FALSE)) {
!canwearobj(otmp, &dummymask, FALSE)
/* or unsuitable items rubbed on known touchstone */
|| (!strncmp(word, "rub on the stone", 16) &&
*let == GEM_CLASS &&
otmp->dknown && objects[otyp].oc_name_known)
) {
foo--;
allowall = TRUE;
*ap++ = otmp->invlet;