Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Moving nightsky with clouds hemisphere

Recommended Posts



for another approach to skyboxes, here's a SkyViewpoint in a hemisphere that has a moving night sky ceiling texture.


I added seven layers of 3d sectors with scrolling floors and transparent cloud textures. The textures themselves are quite big in their dimensions, but not in their file size.


There also is a blue additive light to compliment the colors of the sky texture (which is above the cloud layers).


The code is simple, scrolling speeds can be defined easily:

#include "zcommon.acs"

script "sky" OPEN { // sky
	int skyspeed_x = 2;			// x scrolling speed of sky
	int skyspeed_y = 1;			// y scrolling speed of sky
	int minspeed_x = 1;			// x min scrolling speed of clouds
	int minspeed_y = 1;			// y min scrolling speed of clouds
	int maxspeed_x = 4;			// x max scrolling speed of clouds
	int maxspeed_y = 4;			// y max scrolling speed of clouds
	int cloudspeed_x = Random(minspeed_x, maxspeed_x);
	int cloudspeed_y = Random(minspeed_y, maxspeed_y);
	int scroll_start = 992;		// starting sector (clouds)
	int scroll_end   = 999;		// end sector (sky)
	while (scroll_start <= scroll_end) {
		if (scroll_start < 999) {
			Scroll_Floor(scroll_start, cloudspeed_x, cloudspeed_y, 0);
			cloudspeed_x = Random(minspeed_x, maxspeed_x);
			cloudspeed_y = Random(minspeed_y, maxspeed_y);
			scroll_start += 1;
		} else {
			Scroll_Ceiling(scroll_start, skyspeed_x, skyspeed_y, 0);

In a wide, open area, distant clouds look pretty much 2d.


If anybody got any ideas on how to improve this, don't hesitate^^


UPDATE: I added a second demo map with a bigger hemisphere, but clouds still look pretty 2d when far away.


Things to fiddle around with to customize it a little more:

  • height of cloud textures
  • texture scaling of cloud textures




Screenshots of second demo map


clouds 1.jpg


clouds 2.jpg

Edited by vedan

Share this post

Link to post

Pretty cool!

I did something like this for a Quake remake map for Doom a while back. It didn't use a script though and only two 3D floors with texture scrolling over a normal MAPINFO sky scrolling, so what you made is a lot more technically advanced.

If anything it could use? MOAR CLOUDS! ;)

Share this post

Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now