summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/cloud.cc
diff options
context:
space:
mode:
authorj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2008-06-26 10:39:39 +0000
committerj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2008-06-26 10:39:39 +0000
commit61cae4a761c2f72cda44ae269c7007b37a0c14a7 (patch)
treefec8ec71ca7ca6eebd9d48881bc5ee3fe27d04c1 /crawl-ref/source/cloud.cc
parentd4acdf4a6a4b73607d58714a66efd372674adb56 (diff)
downloadcrawl-ref-61cae4a761c2f72cda44ae269c7007b37a0c14a7.tar.gz
crawl-ref-61cae4a761c2f72cda44ae269c7007b37a0c14a7.zip
Misc. minor cleanups. (Yes, a huge amount of them but still...)
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@6146 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/cloud.cc')
-rw-r--r--crawl-ref/source/cloud.cc20
1 files changed, 11 insertions, 9 deletions
diff --git a/crawl-ref/source/cloud.cc b/crawl-ref/source/cloud.cc
index 324b4c76e8..daaa238c0e 100644
--- a/crawl-ref/source/cloud.cc
+++ b/crawl-ref/source/cloud.cc
@@ -298,17 +298,19 @@ void place_cloud(cloud_type cl_type, int ctarget_x,
bool is_opaque_cloud(unsigned char cloud_idx)
{
- if ( cloud_idx == EMPTY_CLOUD )
- return false;
+ 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) );
+ return (ctype == CLOUD_BLACK_SMOKE
+ || ctype >= CLOUD_GREY_SMOKE && ctype <= CLOUD_STEAM);
}
cloud_type cloud_type_at(const coord_def &c)
{
const int cloudno = env.cgrid(c);
- return (cloudno == EMPTY_CLOUD? CLOUD_NONE : env.cloud[cloudno].type);
+ return (cloudno == EMPTY_CLOUD ? CLOUD_NONE
+ : env.cloud[cloudno].type);
}
cloud_type random_smoke_type()
@@ -675,16 +677,16 @@ void place_fog_machine(fog_machine_data data, int x, int y)
bool valid_fog_machine_data(fog_machine_data data)
{
if (data.fm_type < FM_GEYSER || data.fm_type >= NUM_FOG_MACHINE_TYPES)
- return false;
+ return (false);
if (data.cl_type <= CLOUD_NONE || (data.cl_type >= CLOUD_RANDOM
&& data.cl_type != CLOUD_DEBUGGING))
- return false;
+ return (false);
if (data.size < 1 || data.power < 1)
- return false;
+ return (false);
- return true;
+ return (true);
}
int num_fogs_for_place(int level_number, const level_id &place)