diff options
author | Jesse Luehrs <doy@tozt.net> | 2014-08-15 14:39:21 -0400 |
---|---|---|
committer | Jesse Luehrs <doy@tozt.net> | 2014-08-15 14:39:21 -0400 |
commit | 0d61daab317636fdbfa7b6100f41aa3d67bfe514 (patch) | |
tree | 0b1dce206ac2a3eeb100cdf5f5c1c2d9823a2a2e /crawl-ref/source/terrain.cc | |
parent | fa0fb9524926a6770a1b1ef5351a450e00862015 (diff) | |
download | crawl-ref-0d61daab317636fdbfa7b6100f41aa3d67bfe514.tar.gz crawl-ref-0d61daab317636fdbfa7b6100f41aa3d67bfe514.zip |
remove clouds if solid features are shifted onto them (8549)
Diffstat (limited to 'crawl-ref/source/terrain.cc')
-rw-r--r-- | crawl-ref/source/terrain.cc | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/crawl-ref/source/terrain.cc b/crawl-ref/source/terrain.cc index a3e6fbf0da..014a368a8b 100644 --- a/crawl-ref/source/terrain.cc +++ b/crawl-ref/source/terrain.cc @@ -863,7 +863,14 @@ void dgn_move_entities_at(coord_def src, coord_def dst, if (move_items) move_item_stack_to_grid(src, dst); - move_cloud_to(src, dst); + if (cell_is_solid(dst)) + { + int cl = env.cgrid(dst); + if (cl != EMPTY_CLOUD) + delete_cloud(cl); + } + else + move_cloud_to(src, dst); // Move terrain colours and properties. env.pgrid(dst) = env.pgrid(src); |