diff options
author | haranp <haranp@c06c8d41-db1a-0410-9941-cceddc491573> | 2007-04-13 16:09:50 +0000 |
---|---|---|
committer | haranp <haranp@c06c8d41-db1a-0410-9941-cceddc491573> | 2007-04-13 16:09:50 +0000 |
commit | 6e45e466e647473b51e0053ad1e595be3bc9f7c8 (patch) | |
tree | 4456ea3f603374a47d5c9f91f662dade3c72b653 /crawl-ref/source/cloud.cc | |
parent | 3719e3c8c35ad7bd924373512c25ce7828d62a03 (diff) | |
download | crawl-ref-6e45e466e647473b51e0053ad1e595be3bc9f7c8.tar.gz crawl-ref-6e45e466e647473b51e0053ad1e595be3bc9f7c8.zip |
Steam and smoke now blocks LOS (1697143).
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@1296 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/cloud.cc')
-rw-r--r-- | crawl-ref/source/cloud.cc | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/crawl-ref/source/cloud.cc b/crawl-ref/source/cloud.cc index 43fc2ee1c6..8ecfa7b158 100644 --- a/crawl-ref/source/cloud.cc +++ b/crawl-ref/source/cloud.cc @@ -264,3 +264,12 @@ void place_cloud(int cl_type, int ctarget_x, } } } // end place_cloud(); + +bool is_opaque_cloud(unsigned char cloud_idx) +{ + if ( cloud_idx == EMPTY_CLOUD ) + return false; + const int ctype = env.cloud[cloud_idx].type; + return ( ctype == CLOUD_BLACK_SMOKE || + (ctype >= CLOUD_GREY_SMOKE && ctype <= CLOUD_STEAM) ); +} |