summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/effects.cc
diff options
context:
space:
mode:
Diffstat (limited to 'crawl-ref/source/effects.cc')
-rw-r--r--crawl-ref/source/effects.cc20
1 files changed, 20 insertions, 0 deletions
diff --git a/crawl-ref/source/effects.cc b/crawl-ref/source/effects.cc
index 722161f8e5..d70a41fc14 100644
--- a/crawl-ref/source/effects.cc
+++ b/crawl-ref/source/effects.cc
@@ -1982,6 +1982,26 @@ bool forget_inventory(bool quiet)
return (items_forgotten > 0);
}
+void vitrify_area(int radius)
+{
+ const int radius2 = radius * radius;
+ for ( int x = X_BOUND_1; x <= X_BOUND_2; ++x )
+ {
+ for ( int y = Y_BOUND_1; y <= Y_BOUND_2; ++y )
+ {
+ if ( distance(x,y,you.x_pos,you.y_pos) < radius2 )
+ {
+ if ( grd[x][y] == DNGN_ROCK_WALL )
+ grd[x][y] = DNGN_CLEAR_ROCK_WALL;
+ else if ( grd[x][y] == DNGN_STONE_WALL )
+ grd[x][y] = DNGN_CLEAR_STONE_WALL;
+ else if ( grd[x][y] == DNGN_PERMAROCK_WALL )
+ grd[x][y] = DNGN_CLEAR_PERMAROCK_WALL;
+ }
+ }
+ }
+}
+
///////////////////////////////////////////////////////////////////////
static void hell_effects()