diff options
author | ennewalker <ennewalker@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-06-29 04:06:06 +0000 |
---|---|---|
committer | ennewalker <ennewalker@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-06-29 04:06:06 +0000 |
commit | e7a6987931173ad13d9be69bbd7c089fb982972d (patch) | |
tree | 930e15587977d34be45bed329646830ff33ab0b4 /crawl-ref/source/player.cc | |
parent | 32195d605113f0035a4b4aa79e19a66345b49a6d (diff) | |
download | crawl-ref-e7a6987931173ad13d9be69bbd7c089fb982972d.tar.gz crawl-ref-e7a6987931173ad13d9be69bbd7c089fb982972d.zip |
[2005471] Fixing bug where discovered trap was not being shown until a turn later.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@6202 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/player.cc')
-rw-r--r-- | crawl-ref/source/player.cc | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/crawl-ref/source/player.cc b/crawl-ref/source/player.cc index 64a89331bf..746b2f6948 100644 --- a/crawl-ref/source/player.cc +++ b/crawl-ref/source/player.cc @@ -158,6 +158,12 @@ bool move_player_to_grid( int x, int y, bool stepped, bool allow_shift, if (random2( skill ) > 6) { + id = trap_at_xy( x, y ); + if (id != -1) + grd[x][y] = trap_category( env.trap[id].type ); + + viewwindow(true, false); + mprf( MSGCH_WARN, "Wait a moment, %s! Do you really want to step there?", you.your_name ); @@ -169,10 +175,6 @@ bool move_player_to_grid( int x, int y, bool stepped, bool allow_shift, you.turn_is_over = false; - id = trap_at_xy( x, y ); - if (id != -1) - grd[x][y] = trap_category( env.trap[id].type ); - return (false); } } |