diff options
author | dshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573> | 2007-07-13 13:45:12 +0000 |
---|---|---|
committer | dshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573> | 2007-07-13 13:45:12 +0000 |
commit | 3600271e4eacec0160f88dba0c76a72467e84a07 (patch) | |
tree | d0513455a8e9b825f142037d6d74d21ac8b35f42 | |
parent | 1b7682ecfe6bb7d7d37e73f8769a452fdc8b04d2 (diff) | |
download | crawl-ref-3600271e4eacec0160f88dba0c76a72467e84a07.tar.gz crawl-ref-3600271e4eacec0160f88dba0c76a72467e84a07.zip |
Give kills.lua more leash before CPU throttling kicks in.
&~ to level 1 of a branch now puts you on the branch upstairs.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@1856 c06c8d41-db1a-0410-9941-cceddc491573
-rw-r--r-- | crawl-ref/source/Kills.cc | 4 | ||||
-rw-r--r-- | crawl-ref/source/debug.cc | 8 |
2 files changed, 10 insertions, 2 deletions
diff --git a/crawl-ref/source/Kills.cc b/crawl-ref/source/Kills.cc index 74c3215f35..890d9c3deb 100644 --- a/crawl-ref/source/Kills.cc +++ b/crawl-ref/source/Kills.cc @@ -136,6 +136,7 @@ std::string KillMaster::kill_info() const } #ifdef CLUA_BINDINGS + unwind_var<int> lthrottle(clua.throttle_unit_lines, 500000); // Call the kill dump Lua function with null a, to tell it we're done. if (!clua.callfn("c_kill_list", "ss", NULL, grandt.c_str())) #endif @@ -173,7 +174,8 @@ void KillMaster::add_kill_info(std::string &killtext, lua_pushnil(clua); lua_pushboolean(clua, separator); - + + unwind_var<int> lthrottle(clua.throttle_unit_lines, 500000); if (!clua.callfn("c_kill_list", 3, 0)) #endif { diff --git a/crawl-ref/source/debug.cc b/crawl-ref/source/debug.cc index 22d3f372d1..4d79857f54 100644 --- a/crawl-ref/source/debug.cc +++ b/crawl-ref/source/debug.cc @@ -426,10 +426,16 @@ void level_travel( int delta ) static void wizard_go_to_level(const level_pos &pos) { const int abs_depth = absdungeon_depth(pos.id.branch, pos.id.depth); - const dungeon_feature_type stair_taken = + dungeon_feature_type stair_taken = abs_depth > you.your_level? DNGN_STONE_STAIRS_DOWN_I : DNGN_STONE_STAIRS_UP_I; + if (abs_depth > you.your_level && pos.id.depth == 1 + && pos.id.branch != BRANCH_MAIN_DUNGEON) + { + stair_taken = branches[pos.id.branch].entry_stairs; + } + const int old_level = you.your_level; const branch_type old_where = you.where_are_you; const bool was_a_labyrinth = you.level_type == LEVEL_LABYRINTH; |