From: Raphaël L. <ga...@us...> - 2010-11-30 22:27:00
|
via f3203d5f93b624829d13d11e8f511f9efa3e0f5e (commit) via eb6f652a6c7be36f85a759060db05dc00a267db8 (commit) via 4badd00a9a7e8322617c649b9679ba9219c71133 (commit) from e869e6b8e29d03c77e00fc09ce382bf0da52700b (commit) ----------------------------------------------------------------------- commit f3203d5f93b624829d13d11e8f511f9efa3e0f5e Author: Arxale <ga...@gm...> Date: Fri Nov 26 18:07:33 2010 +0300 Fix various 'found foo' bugs commit eb6f652a6c7be36f85a759060db05dc00a267db8 Author: Arxale <ga...@gm...> Date: Fri Nov 26 18:25:27 2010 +0300 Fix message order for 'found foo' commit 4badd00a9a7e8322617c649b9679ba9219c71133 Author: Raphael Langella <rap...@gm...> Date: Tue Nov 30 23:20:44 2010 +0100 Removes an obsolete parameter in the exercise function It's not needed anymore now that reskilling doesn't use exercise. ----------------------------------------------------------------------- Summary of changes: crawl-ref/source/main.cc | 3 +++ crawl-ref/source/player.cc | 4 ++-- crawl-ref/source/skills.cc | 5 ++--- crawl-ref/source/skills.h | 2 +- crawl-ref/source/stairs.cc | 10 ++++++++++ 5 files changed, 18 insertions(+), 6 deletions(-) diff --git a/crawl-ref/source/main.cc b/crawl-ref/source/main.cc index d517826..033c887 100644 --- a/crawl-ref/source/main.cc +++ b/crawl-ref/source/main.cc @@ -365,6 +365,9 @@ static void _launch_game() viewwindow(); #endif + if (!game_start) + env.map_shadow = env.map_knowledge; + if (game_start && you.char_class == JOB_WANDERER) _wanderer_startup_message(); diff --git a/crawl-ref/source/player.cc b/crawl-ref/source/player.cc index 999293d..04cdc5f 100644 --- a/crawl-ref/source/player.cc +++ b/crawl-ref/source/player.cc @@ -382,11 +382,11 @@ void move_player_to_grid(const coord_def& p, bool stepped, bool allow_shift) you.moveto(p); viewwindow(); - moveto_location_effects(old_grid, stepped, allow_shift, old_pos); - // Checking new squares for interesting features. if (!you.running) check_for_interesting_features(); + + moveto_location_effects(old_grid, stepped, allow_shift, old_pos); } bool is_feat_dangerous(dungeon_feature_type grid) diff --git a/crawl-ref/source/skills.cc b/crawl-ref/source/skills.cc index 30a1e3a..eb0a3cb 100644 --- a/crawl-ref/source/skills.cc +++ b/crawl-ref/source/skills.cc @@ -249,7 +249,7 @@ void check_skill_level_change(skill_type sk, bool do_level_up) } // returns total number of skill points gained -int exercise(skill_type exsk, int deg, bool change_level) +int exercise(skill_type exsk, int deg) { int ret = 0; @@ -281,8 +281,7 @@ int exercise(skill_type exsk, int deg, bool change_level) } #endif - if (change_level) - check_skill_level_change(exsk); + check_skill_level_change(exsk); return (ret); } diff --git a/crawl-ref/source/skills.h b/crawl-ref/source/skills.h index 51b7b3b..c429f35 100644 --- a/crawl-ref/source/skills.h +++ b/crawl-ref/source/skills.h @@ -16,6 +16,6 @@ void check_skill_level_change(skill_type sk, bool do_level_up = true); void change_skill_level(skill_type exsk, int num_level); void change_skill_points(skill_type sk, int points, bool do_level_up); -int exercise(skill_type exsk, int deg, bool change_level = true); +int exercise(skill_type exsk, int deg); #endif diff --git a/crawl-ref/source/stairs.cc b/crawl-ref/source/stairs.cc index 52e4e94..ed8627b 100644 --- a/crawl-ref/source/stairs.cc +++ b/crawl-ref/source/stairs.cc @@ -746,7 +746,16 @@ void up_stairs(dungeon_feature_type force_stair, _update_travel_cache(collect_travel_data, old_level, stair_pos); + env.map_shadow = env.map_knowledge; + // Preventing obvious finding of stairs at your position. + env.map_shadow(you.pos()).flags |= MAP_SEEN_FLAG; + viewwindow(); + + // Checking new squares for interesting features. + if (!you.running) + check_for_interesting_features(); + seen_monsters_react(); // Left Zot without enough runes to get back in (because they were @@ -1324,6 +1333,7 @@ void down_stairs(dungeon_feature_type force_stair, if (!force_dest) _update_travel_cache(collect_travel_data, old_level, stair_pos); + env.map_shadow = env.map_knowledge; // Preventing obvious finding of stairs at your position. env.map_shadow(you.pos()).flags |= MAP_SEEN_FLAG; -- Dungeon Crawl Stone Soup |