diff options
author | Nicholas Feinberg <pleasingfung@gmail.com> | 2014-07-16 18:07:36 -0700 |
---|---|---|
committer | Nicholas Feinberg <pleasingfung@gmail.com> | 2014-07-16 20:24:25 -0700 |
commit | eb334f11d02463060a5572249632f95cc60568dd (patch) | |
tree | 60ae262e7cce216289c9fa452c019a83729b5b63 /crawl-ref/source/player.cc | |
parent | f74bb73639c84ddaac5cee442cb169e6cc6eb89c (diff) | |
download | crawl-ref-eb334f11d02463060a5572249632f95cc60568dd.tar.gz crawl-ref-eb334f11d02463060a5572249632f95cc60568dd.zip |
Document a function
Diffstat (limited to 'crawl-ref/source/player.cc')
-rw-r--r-- | crawl-ref/source/player.cc | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/crawl-ref/source/player.cc b/crawl-ref/source/player.cc index 281c385157..0ce1c5009a 100644 --- a/crawl-ref/source/player.cc +++ b/crawl-ref/source/player.cc @@ -544,6 +544,18 @@ void move_player_to_grid(const coord_def& p, bool stepped) moveto_location_effects(old_grid, stepped, old_pos); } + +/** + * Check if the given terrain feature is safe for the player to move into. + * (Or, at least, not instantly lethal.) + * + * @param grid The type of terrain feature under consideration. + * @param permanently Whether to disregard temporary effects (non-permanent + * flight, forms, etc) + * @param ignore_flight Whether to ignore all forms of flight (including + * permanent flight) + * @return Whether the terrain is safe. + */ bool is_feat_dangerous(dungeon_feature_type grid, bool permanently, bool ignore_flight) { |