From 632cb9ffb0d3684839a50428e1630fd106eba507 Mon Sep 17 00:00:00 2001 From: cohrs Date: Fri, 9 Aug 2002 04:06:38 +0000 Subject: [PATCH] R1037 - digging secret doors in town I saw no secret doors in any of the towns, but in 340 (fixed in 341), guards would patrol the entire level, so they might complain about secret doors elsewhere. Fix the check for future use. Also, I noticed trees, eg on minetn-6, weren't checked at all. Now they are. --- doc/fixes34.1 | 2 ++ src/dig.c | 8 +++++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/doc/fixes34.1 b/doc/fixes34.1 index 0aec85a9d..78dce26d1 100644 --- a/doc/fixes34.1 +++ b/doc/fixes34.1 @@ -193,6 +193,8 @@ fix wishing for "looking glass" and " glass" Archeologists suffer same alignment penalty for statue destruction by stone_to_flesh as they do by other means of statue destruction being unable to see a vault guard doesn't prevent him from arriving +in town, secret doors should be called "wall", not "fountain" +in town, watch should not allow trees to be cut down Platform- and/or Interface-Specific Fixes diff --git a/src/dig.c b/src/dig.c index 381e7dbfc..85e18fcd1 100644 --- a/src/dig.c +++ b/src/dig.c @@ -993,7 +993,7 @@ struct obj *obj; } /* - * Town Watchmen frown on damage to the town walls or fountains. + * Town Watchmen frown on damage to the town walls, trees or fountains. * It's OK to dig holes in the ground, however. * If mtmp is assumed to be a watchman, a watchman is found if mtmp == 0 * zap == TRUE if wand/spell of digging, FALSE otherwise (chewing) @@ -1008,7 +1008,7 @@ watch_dig(mtmp, x, y, zap) if (in_town(x, y) && (closed_door(x, y) || lev->typ == SDOOR || - IS_WALL(lev->typ) || IS_FOUNTAIN(lev->typ))) { + IS_WALL(lev->typ) || IS_FOUNTAIN(lev->typ) || IS_TREE(lev->typ))) { if (!mtmp) { for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) { if (DEADMONSTER(mtmp)) continue; @@ -1028,7 +1028,9 @@ watch_dig(mtmp, x, y, zap) char *str; if (IS_DOOR(lev->typ)) str = "door"; - else if (IS_WALL(lev->typ)) + else if (IS_TREE(lev->typ)) + str = "tree"; + else if (IS_ROCK(lev->typ)) str = "wall"; else str = "fountain";