summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/dungeon.cc
diff options
context:
space:
mode:
authorj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2009-07-11 23:18:30 +0000
committerj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2009-07-11 23:18:30 +0000
commit144d923598efdf70d12d19437b2a59dee0015c01 (patch)
tree896505eebfbe235c63a051e54b1ddca2a6263e52 /crawl-ref/source/dungeon.cc
parentcc99e42dae0091ba2ad43dde3db0660e083bb793 (diff)
downloadcrawl-ref-144d923598efdf70d12d19437b2a59dee0015c01.tar.gz
crawl-ref-144d923598efdf70d12d19437b2a59dee0015c01.zip
Detected secret doors are now treated as a distinct new door type, so
that stupid monsters will continue to ignore them as long as they've never been opened. Shifts wall and door types of existing save files. Also apply patch by one the "nobodies" to make bloody tiles show up again. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@10167 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/dungeon.cc')
-rw-r--r--crawl-ref/source/dungeon.cc11
1 files changed, 6 insertions, 5 deletions
diff --git a/crawl-ref/source/dungeon.cc b/crawl-ref/source/dungeon.cc
index 1c4a49e9a4..5403924f7d 100644
--- a/crawl-ref/source/dungeon.cc
+++ b/crawl-ref/source/dungeon.cc
@@ -1719,7 +1719,7 @@ static void _check_doors()
for (int x = 1; x < GXM-1; x++)
for (int y = 1; y < GYM-1; y++)
{
- if (grd[x][y] != DNGN_CLOSED_DOOR)
+ if (!grid_is_closed_door(grd[x][y]))
continue;
int solid_count = 0;
@@ -1736,7 +1736,8 @@ static void _check_doors()
if (grid_is_solid( grd[x][y + 1] ))
solid_count++;
- grd[x][y] = ((solid_count < 2) ? DNGN_FLOOR : DNGN_CLOSED_DOOR);
+ grd[x][y] = (solid_count < 2 ? DNGN_FLOOR
+ : DNGN_CLOSED_DOOR);
}
}
@@ -3136,8 +3137,8 @@ static void _make_trail(int xs, int xr, int ys, int yr, int corrlength,
static int _good_door_spot(int x, int y)
{
- if ((!grid_is_solid(grd[x][y]) && grd[x][y] < DNGN_ENTER_PANDEMONIUM)
- || grd[x][y] == DNGN_CLOSED_DOOR)
+ if (!grid_is_solid(grd[x][y]) && grd[x][y] < DNGN_ENTER_PANDEMONIUM
+ || grid_is_closed_door(grd[x][y]))
{
return 1;
}
@@ -3931,7 +3932,7 @@ static void _dig_vault_loose( vault_placement &place,
static bool _grid_needs_exit(int x, int y)
{
return (!grid_is_solid(x, y)
- || grd[x][y] == DNGN_CLOSED_DOOR
+ || grid_is_closed_door(grd[x][y])
|| grd[x][y] == DNGN_SECRET_DOOR);
}