diff options
author | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-03-30 20:43:15 +0000 |
---|---|---|
committer | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-03-30 20:43:15 +0000 |
commit | f116902db8e7f917df91a3a1e775cc43cf7dd47a (patch) | |
tree | 8ce9e5477928410e415ac3244babeed341a40f09 /crawl-ref/source/libgui.cc | |
parent | a932874b76f5657f943d879c2a0b36dab2cc3f68 (diff) | |
download | crawl-ref-f116902db8e7f917df91a3a1e775cc43cf7dd47a.tar.gz crawl-ref-f116902db8e7f917df91a3a1e775cc43cf7dd47a.zip |
Fix 1921769: Exclusion squares on the tiles minimap sometimes
not being updated.
Also add yet another minimap colour option for the centre of an
exclusion (defaults to darkblue).
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@3958 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/libgui.cc')
-rw-r--r-- | crawl-ref/source/libgui.cc | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/crawl-ref/source/libgui.cc b/crawl-ref/source/libgui.cc index 7bb0cfa5d4..311a4a22d4 100644 --- a/crawl-ref/source/libgui.cc +++ b/crawl-ref/source/libgui.cc @@ -311,7 +311,7 @@ InvAction inv_action = INV_NUMACTIONS; static void _gui_set_mouse_inv(int idx, InvAction act) { - inv_idx = idx; + inv_idx = idx; inv_action = act; } @@ -377,8 +377,13 @@ void GmapUpdate(int x, int y, int what, bool upd_tile) } } - if (c == Options.tile_floor_col && is_excluded( coord_def(x,y) )) - c = Options.tile_excluded_col; + if (c == Options.tile_floor_col || c == Options.tile_item_col) + { + if (is_exclude_root( coord_def(x,y) )) + c = Options.tile_excl_centre_col; + else if (c == Options.tile_floor_col && is_excluded(coord_def(x,y))) + c = Options.tile_excluded_col; + } } int oldc = gmap_data[x][y]; @@ -430,12 +435,8 @@ void GmapInit(bool upd_tile) gmap_min_y = gmap_max_y = you.y_pos - 1; for (y = 0; y < GYM; y++) - { for (x = 0; x < GXM; x++) - { GmapUpdate(x, y, env.map[x][y].glyph(), upd_tile); - } - } } void GmapDisplay(int linex, int liney) @@ -445,9 +446,7 @@ void GmapDisplay(int linex, int liney) int ox, oy; for (int x = 0; x < GXM*GYM; x++) - { buf2[x] = 0; - } ox = ( gmap_min_x + (GXM - 1 - gmap_max_x) ) / 2; oy = ( gmap_min_y + (GYM - 1 - gmap_max_y) ) / 2; |