diff options
author | Robert Vollmert <rvollmert@gmx.net> | 2009-10-17 08:59:19 +0200 |
---|---|---|
committer | Robert Vollmert <rvollmert@gmx.net> | 2009-10-17 09:09:43 +0200 |
commit | 91480fa09bfd0c7e937cdf0b29360c9e10413f62 (patch) | |
tree | 8de9cb01752af154a93f3060e8163f08cefb1a0c /crawl-ref/source/misc.cc | |
parent | dcc94e4df24a1111124d87532aaa263f55edf58d (diff) | |
download | crawl-ref-91480fa09bfd0c7e937cdf0b29360c9e10413f62.tar.gz crawl-ref-91480fa09bfd0c7e937cdf0b29360c9e10413f62.zip |
More renaming and reorganization of feature checks.
There were a couple of functions is_something(dgn_feature_type feat)
defined in travel.cc that were otherwise independent of travel. For
consistency, move these to terrain.cc and rename to feat_is_something.
One might also consider renaming the various feat_is_whatever functions
to just is_whatever.
Diffstat (limited to 'crawl-ref/source/misc.cc')
-rw-r--r-- | crawl-ref/source/misc.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/crawl-ref/source/misc.cc b/crawl-ref/source/misc.cc index fc9cefbf0b..a43ce79974 100644 --- a/crawl-ref/source/misc.cc +++ b/crawl-ref/source/misc.cc @@ -1313,7 +1313,7 @@ static void climb_message(dungeon_feature_type stair, bool going_up, (player_is_airborne() ? "float" : "slide")); } } - else if (is_gate(stair)) + else if (feat_is_gate(stair)) { mprf("You %s %s through the gate.", you.flight_mode() == FL_FLY ? "fly" : @@ -1776,7 +1776,7 @@ void up_stairs(dungeon_feature_type force_stair, } if (you.burden_state == BS_OVERLOADED && !feat_is_escape_hatch(stair_find) - && !is_gate(stair_find)) + && !feat_is_gate(stair_find)) { mpr("You are carrying too much to climb upwards."); you.turn_is_over = true; @@ -1858,9 +1858,9 @@ void up_stairs(dungeon_feature_type force_stair, const dungeon_feature_type stair_taken = stair_find; - if (you.flight_mode() == FL_LEVITATE && !is_gate(stair_find)) + if (you.flight_mode() == FL_LEVITATE && !feat_is_gate(stair_find)) mpr("You float upwards... And bob straight up to the ceiling!"); - else if (you.flight_mode() == FL_FLY && !is_gate(stair_find)) + else if (you.flight_mode() == FL_FLY && !feat_is_gate(stair_find)) mpr("You fly upwards."); else climb_message(stair_find, true, old_level_type); @@ -2090,7 +2090,7 @@ void down_stairs( int old_level, dungeon_feature_type force_stair, } if (!force_stair && you.flight_mode() == FL_LEVITATE - && !is_gate(stair_find)) + && !feat_is_gate(stair_find)) { mpr("You're floating high up above the floor!"); return; |