summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/terrain.cc
diff options
context:
space:
mode:
Diffstat (limited to 'crawl-ref/source/terrain.cc')
-rw-r--r--crawl-ref/source/terrain.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/crawl-ref/source/terrain.cc b/crawl-ref/source/terrain.cc
index 67a2fa84b6..ae538be8fb 100644
--- a/crawl-ref/source/terrain.cc
+++ b/crawl-ref/source/terrain.cc
@@ -181,10 +181,11 @@ bool grid_is_permarock(dungeon_feature_type grid)
return (grid == DNGN_PERMAROCK_WALL || grid == DNGN_CLEAR_PERMAROCK_WALL);
}
-bool grid_is_trap(dungeon_feature_type grid)
+bool grid_is_trap(dungeon_feature_type grid, bool undiscovered_too)
{
return (grid == DNGN_TRAP_MECHANICAL || grid == DNGN_TRAP_MAGICAL
- || grid == DNGN_TRAP_NATURAL);
+ || grid == DNGN_TRAP_NATURAL
+ || (undiscovered_too && grid == DNGN_UNDISCOVERED_TRAP));
}
bool grid_is_water(dungeon_feature_type grid)