Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
3 registered members (TipmyPip, AndrewAMD, NewbieZorro), 16,055 guests, and 7 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Wieder mal eine Frage #224103
08/28/08 14:51
08/28/08 14:51
Joined: May 2004
Posts: 152
Germany / Dresden
Thomas Offline OP
Member
Thomas  Offline OP
Member

Joined: May 2004
Posts: 152
Germany / Dresden
Weiss jemand wie man solche Nebel bzw. Wolken realiesieren kann???


http://www.youtube.com/watch?v=P-09i4tM8ts

Gruss Thomas

Re: Wieder mal eine Frage [Re: Thomas] #224382
08/29/08 20:30
08/29/08 20:30
Joined: Feb 2007
Posts: 353
A
amy Offline
Senior Member
amy  Offline
Senior Member
A

Joined: Feb 2007
Posts: 353
The nebula in the video looks really good. I don“t know how exactly they do it. Probably there also are shaders involved but I think with something like that and a good cloud sprite you can achieve quite good results too:

Code:
VECTOR temp;
var box_size = 2000;

void cloud()
{
	set(my, TRANSLUCENT);
	my.roll = 0.001;
	vec_scale(my.scale_x, random(3)+0.5);

	VECTOR velocity;
	vec_set(velocity, vector(random(2)-1, random(2)-1, random(2)-1));
	
	while(1)
	{
		vec_add(my.x, vector(velocity.x * time_step, velocity.y * time_step, velocity.z * time_step));
		
		// move with camera
		my.x = cycle(my.x, camera.x - box_size, camera.x + box_size);
		my.y = cycle(my.y, camera.y - box_size, camera.y + box_size);
		my.z = cycle(my.z, camera.z - box_size, camera.z + box_size);
		
		// smooth alpha fade
		vec_set(temp, my.x);
		vec_sub(temp, camera.x);
		vec_rotateback(temp, camera.pan);
		
		my.alpha = 100;
		if(temp.x < 100 + camera.clip_near)
		{
			my.alpha = maxv(0, temp.x - camera.clip_near);
		}
		else if(temp.x > box_size - 1000)
		{
			my.alpha = 100 - (temp.x - 1000) / 10;
		}
		
		wait(1);
	}	
}

void main()
{
	video_mode = 9;
	level_load("");

	var i;
	for(i=0; i<1000; i++)
		ent_create("cloud.tga",
			vector(random(box_size*2)-box_size, random(box_size*2)-box_size, random(box_size*2)-box_size), cloud);	
}



Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1