From 6ce5131f6be6ace73ddf2a9eb66099131d370cf6 Mon Sep 17 00:00:00 2001 From: j-p-e-g Date: Wed, 29 Jul 2009 13:25:10 +0000 Subject: Don't change dungeon flavour for tiles out of sight. (Fixes 2828717.) git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@10461 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/tilepick.cc | 16 ++++++++-------- crawl-ref/source/util/docs/release.txt | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/crawl-ref/source/tilepick.cc b/crawl-ref/source/tilepick.cc index 916dacc00a..7e5afc1dcc 100644 --- a/crawl-ref/source/tilepick.cc +++ b/crawl-ref/source/tilepick.cc @@ -2710,7 +2710,8 @@ int tileidx_zap(int colour) static inline void _finalize_tile(unsigned int *tile, unsigned char wall_flv, unsigned char floor_flv, - unsigned char special_flv) + unsigned char special_flv, + coord_def gc) { int orig = (*tile) & TILE_FLAG_MASK; int flag = (*tile) & (~TILE_FLAG_MASK); @@ -2732,14 +2733,12 @@ static inline void _finalize_tile(unsigned int *tile, (*tile) = wall_flv; else if (orig == TILE_DNGN_CLOSED_DOOR || orig == TILE_DNGN_OPEN_DOOR) (*tile) = orig + std::min((int)special_flv, 3); - else if (orig >= TILE_DNGN_LAVA && orig < TILE_BLOOD) - { - // Tiles may change from turn to turn. - (*tile) = orig + random2(tile_dngn_count(orig)); - } else if (orig < TILE_DNGN_MAX) { - // Tile flavour is fixed. + // Some tiles may change from turn to turn, but only if in view. + if (orig >= TILE_DNGN_LAVA && orig < TILE_BLOOD && see_grid(gc)) + env.tile_flv(gc).special = random2(256); + (*tile) = orig + (special_flv % tile_dngn_count(orig)); } @@ -4489,7 +4488,8 @@ void tile_finish_dngn(unsigned int *tileb, int cx, int cy) special_flv = env.tile_flv(gc).special; } - _finalize_tile(&tileb[count+1], wall_flv, floor_flv, special_flv); + _finalize_tile(&tileb[count+1], wall_flv, floor_flv, special_flv, + gc); if (is_excluded(gc)) { diff --git a/crawl-ref/source/util/docs/release.txt b/crawl-ref/source/util/docs/release.txt index 40ccbe65ec..f9c3c753cc 100644 --- a/crawl-ref/source/util/docs/release.txt +++ b/crawl-ref/source/util/docs/release.txt @@ -33,7 +33,7 @@ for those the list begins with step 2. concentrate on the important ones (crashes and gamebreakers), but you might also want to handle the trivial ones for extra polishing. If you add any last minute feature or bug fixes doublecheck everything, - so you don't accidentally introduce new bug, and wait at least another + so you don't accidentally introduce new bugs, and wait at least another day for potential bug reports to roll in. Reread the entire documentation to make sure it's up to date. -- cgit v1.2.3-54-g00ecf