summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/acr.cc
diff options
context:
space:
mode:
authorj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2009-03-19 09:46:26 +0000
committerj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2009-03-19 09:46:26 +0000
commit05a9956798b9ccc82b5ed32412d99f53c60b3b4d (patch)
tree615f50bf4b85428ecd3b84c0950fc62a07be70e6 /crawl-ref/source/acr.cc
parent361d79f1078a756eb41ddf14294cc017c38676a8 (diff)
downloadcrawl-ref-05a9956798b9ccc82b5ed32412d99f53c60b3b4d.tar.gz
crawl-ref-05a9956798b9ccc82b5ed32412d99f53c60b3b4d.zip
* Change Roxanne's spells to include Blink Other (instead of Sandblast)
as spell to fall back on if all others are out of range. (Fixes 2686559.) * Fix 2690141: Tiles inventory leaking cursedness of items. * Fix 2687108: inappropriate message flushing during repeat command. * Fix opening/closing doors not updating exclusion los. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@9516 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/acr.cc')
-rw-r--r--crawl-ref/source/acr.cc20
1 files changed, 19 insertions, 1 deletions
diff --git a/crawl-ref/source/acr.cc b/crawl-ref/source/acr.cc
index 06cde2fdfe..e5ee5f59da 100644
--- a/crawl-ref/source/acr.cc
+++ b/crawl-ref/source/acr.cc
@@ -3069,6 +3069,7 @@ static void _open_door(coord_def move, bool check_confused)
}
bool seen_secret = false;
+ std::vector<coord_def> excludes;
for (std::set<coord_def>::iterator i = all_door.begin();
i != all_door.end(); ++i)
{
@@ -3093,6 +3094,14 @@ static void _open_door(coord_def move, bool check_confused)
}
}
grd(dc) = DNGN_OPEN_DOOR;
+ if (is_excluded(dc))
+ excludes.push_back(dc);
+ }
+ if (!excludes.empty())
+ {
+ mark_all_excludes_non_updated();
+ for (unsigned int i = 0; i < excludes.size(); ++i)
+ update_exclusion_los(excludes[i]);
}
you.turn_is_over = true;
}
@@ -3234,6 +3243,7 @@ static void _close_door(coord_def move)
mprf( "You %s the %s%s.", verb, adj, noun );
}
+ std::vector<coord_def> excludes;
for (std::set<coord_def>::const_iterator i = all_door.begin();
i != all_door.end(); ++i)
{
@@ -3249,6 +3259,14 @@ static void _close_door(coord_def move)
env.tile_bk_bg(dc) = TILE_DNGN_CLOSED_DOOR;
#endif
}
+ if (is_excluded(dc))
+ excludes.push_back(dc);
+ }
+ if (!excludes.empty())
+ {
+ mark_all_excludes_non_updated();
+ for (unsigned int i = 0; i < excludes.size(); ++i)
+ update_exclusion_los(excludes[i]);
}
you.turn_is_over = true;
}
@@ -3728,7 +3746,7 @@ static int _get_num_and_char_keyfun(int &ch)
static int _get_num_and_char(const char* prompt, char* buf, int buf_len)
{
if (prompt != NULL)
- mpr(prompt);
+ mpr(prompt, MSGCH_PROMPT);
line_reader reader(buf, buf_len);