diff options
author | haranp <haranp@c06c8d41-db1a-0410-9941-cceddc491573> | 2009-01-30 15:13:02 +0000 |
---|---|---|
committer | haranp <haranp@c06c8d41-db1a-0410-9941-cceddc491573> | 2009-01-30 15:13:02 +0000 |
commit | 464e945f78e101802a8784636afa07a45c3b38b9 (patch) | |
tree | 1b3504874a911d034b2029a7d9e656bb709da5c4 /crawl-ref/source | |
parent | f984dabc74b0a6370e91147b6709b3ca6e591448 (diff) | |
download | crawl-ref-464e945f78e101802a8784636afa07a45c3b38b9.tar.gz crawl-ref-464e945f78e101802a8784636afa07a45c3b38b9.zip |
Fix [2478469]: teleport should stop stair use delays.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8854 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source')
-rw-r--r-- | crawl-ref/source/delay.cc | 7 | ||||
-rw-r--r-- | crawl-ref/source/initfile.cc | 9 |
2 files changed, 9 insertions, 7 deletions
diff --git a/crawl-ref/source/delay.cc b/crawl-ref/source/delay.cc index 5f0d9f7e13..543f81492d 100644 --- a/crawl-ref/source/delay.cc +++ b/crawl-ref/source/delay.cc @@ -507,7 +507,7 @@ void stop_delay( bool stop_stair_travel ) if (stop_stair_travel) { #ifdef DEBUG_DIAGNOSTICS - mpr("Stop ascending/descending stairs."); + mpr("Stop ascending/descending stairs.", MSGCH_DIAGNOSTICS); #endif _pop_delay(); } @@ -1924,7 +1924,8 @@ bool interrupt_activity( activity_interrupt_type ai, return (false); was_monst = _monster_warning(ai, at, item.type) || was_monst; - stop_delay(); + // Teleport stops stair delays. + stop_delay(ai == AI_TELEPORT); if (was_monst) handle_interrupted_swap(false, true); @@ -1950,7 +1951,7 @@ bool interrupt_activity( activity_interrupt_type ai, _monster_warning(ai, at, you.delay_queue[j].type) || was_monst; - stop_delay(); + stop_delay(ai == AI_TELEPORT); if (was_monst) handle_interrupted_swap(false, true); return (true); diff --git a/crawl-ref/source/initfile.cc b/crawl-ref/source/initfile.cc index f036bacb06..35ff9d6c22 100644 --- a/crawl-ref/source/initfile.cc +++ b/crawl-ref/source/initfile.cc @@ -539,10 +539,11 @@ void game_options::set_default_activity_interrupts() "interrupt_run = interrupt_travel, message", "interrupt_rest = interrupt_run, full_hp, full_mp", - // Stair ascents/descents cannot be interrupted, attempts to interrupt - // the delay will just trash all queued delays, including travel. - "interrupt_ascending_stairs =", - "interrupt_descending_stairs =", + // Stair ascents/descents cannot be interrupted except by + // teleportation. Attempts to interrupt the delay will just + // trash all queued delays, including travel. + "interrupt_ascending_stairs = teleport", + "interrupt_descending_stairs = teleport", "interrupt_recite = teleport", "interrupt_uninterruptible =", "interrupt_weapon_swap =", |