+ /**
+ * set the cloud movement direction
+ * @param dir the cloud movement direction
+ */
+ inline void setDirection(float dir) {
+ // cout << "cloud dir = " << dir << endl;
+ direction = dir;
+ }
+
+ /** get the cloud movement direction */
+ inline float getDirection() { return direction; }
+
+ /**
+ * set the cloud movement speed
+ * @param sp the cloud movement speed
+ */
+ inline void setSpeed(float sp) {
+ // cout << "cloud speed = " << sp << endl;
+ speed = sp;
+ }
+
+ /** get the cloud movement speed */
+ inline float getSpeed() { return speed; }
+
+ /**
+ * set the alpha component of the cloud base color. Normally this
+ * should be 1.0, but you can set it anywhere in the range of 0.0
+ * to 1.0 to fade a cloud layer in or out.
+ * @param alpha cloud alpha value (0.0 to 1.0)
+ */
+ inline void setAlpha( float alpha ) {
+ if ( alpha < 0.0 ) { alpha = 0.0; }
+ if ( alpha > 1.0 ) { alpha = 1.0; }
+ cloud_alpha = alpha;
+ }
+