Milo-Question: Nebulas

Starshatter: The Gathering Storm extends the classic space sim by combining fighter and starship combat in a single dynamic campaign game.
Post Reply
TexMurphy
Posts: 137
Joined: Fri Jun 11, 2004 7:16 pm

Milo-Question: Nebulas

Post by TexMurphy »

Hi milo.

I was reading your description of how you make the nebulas. Ive got a few questions on this topic.
It's a variety of techniques. I usually start by laying down a base of several different Cloud filters in different colors on different layers. A useful texture to create in Photoshop is a pseudo-Perlin-turbulence. Start with a canvas 2048 pixels square. Create a black-white cloud texture on it. Shrink the canvas to 1024 pixels, and create a second cloud texture on a new layer. Repeat for 512 and 256 pixel squares. Order the layers so that the first one (that was originally 2048 pixels) is on the top and the last one is on the bottom. Set the opacities for all the layers to something like 12%, 25%, 50%, and 100% from top to bottom.

Then I manually paint in highlights on on other layers using the airbrush. To get a 3D effect, it is helpful to paint in both light and dark colors for each feature on different layers, as if you were seeing a 3D pillar of cloud lit on one side and shadowed on another. I also add very fine grained trails of "dust" using a dark color and just dotting them in with a fine airbrush. Set that layer's blend to "multiply".

The most important part of the effect is to create a separate layer that is used as an alpha-channel by the game engine. The edges of this layer must be completely black so that you don't see polygon seams at the edges of the texture. I usually hand-paint this layer with the airbrush as well. Sometimes I add some variance to the alpha by using a stippled brush pattern in the airbrush. Just a little gray stippling helps to add some texture to the body of the texture. This layer gets saved out as a separate greyscale PCX file that the game engine will recognize as containing alpha values for the main texture.

I paint the nebulae on a 512x256 pixel canvas, and then squash the image to 256 square to make a texture out of it.

The geometry of the nebula model is like a movie screen: twice as wide as it is high, and wrapped around the 3D origin point so that all the polygon normals are oriented toward the viewer. Because of the way magic works, I actually stretch the texture over the geometry while it is still flat, and then bend the framework around the center point. You have to be careful to keep all the quad polys flat while you do this or you will see unsightly texture shearing when the polys get near the edge of the viewport in the game.

1. What is the reason to you rescaling the canvas between rendering each layer?

2. The alpha layer. Im kind of confused here. Ok you create a top layer with black edges and airbrush the edges so that you get a smoother transition. Thats fine. But Then you say ". This layer gets saved out as a separate greyscale PCX file that the game engine will recognize as containing alpha values for the main texture". I dont get this at all. PCX format does not support layers and needs the image to be flattend. So how does this layer get saved out???? Do you save it manually as a separate file and in that case what do you name it ??

3. The 3d model for the nebula what kind of shape do you use? You say that you bend a flat geometry that you bend. Do you just create a square polygon for this or what? Then finally how do you bend it? Just by splitting it up and moving the vertexes? How much do you bend it?

Reason Im puzzled here is because Ive been playin with this and find it hard to get a good nebula. The texture is ok but for the nebula Ive been using a sphere shape that I invert the faces on. This works but doesnt give me a result that Im too happy with as it really does feel like Im flyin inside a fish bowl.

Actually would you mind attaching a sample MAG file?

Thanks for reading.
Tex
Pheagey
Posts: 290
Joined: Thu Apr 01, 2004 8:16 am
Location: Tampa, USA
Contact:

RE: Milo-Question: Nebulas

Post by Pheagey »

I'd like playable nebua area's...
blaa.
Deathifier
Posts: 274
Joined: Mon Jun 17, 2002 1:09 pm
Location: Sydney, Australia
Contact:

RE: Milo-Question: Nebulas

Post by Deathifier »

ORIGINAL: TexMurphy

Hi milo.

I was reading your description of how you make the nebulas. Ive got a few questions on this topic.

(...)

2. The alpha layer. Im kind of confused here. Ok you create a top layer with black edges and airbrush the edges so that you get a smoother transition. Thats fine. But Then you say ". This layer gets saved out as a separate greyscale PCX file that the game engine will recognize as containing alpha values for the main texture". I dont get this at all. PCX format does not support layers and needs the image to be flattend. So how does this layer get saved out???? Do you save it manually as a separate file and in that case what do you name it ??

The PCX image represents just the one layer, which is the layer storing the alphas as greyscale.

See "This layer gets saved out as a separate greyscale PCX file" in the quote.

So no problems with multiple layers in PCX, since there's just the one layer, a grey blob :)

- Deathifier
John DiCamillo
Posts: 360
Joined: Sat Feb 28, 2004 7:02 am
Contact:

RE: Milo-Question: Nebulas

Post by John DiCamillo »

The game engine uses a file naming convention to compose complex bitmaps from separate image files.

NAME.PCX - base texture (may be 256 color or 32-bit color)
NAME+.PCX - if base texture is 256 color, this is the same image in 32-bit color
NAME@.PCX - alpha layer for texture

The model is a pair of curved screens. It's hard to describe, I'll send you a sample later.
TexMurphy
Posts: 137
Joined: Fri Jun 11, 2004 7:16 pm

RE: Milo-Question: Nebulas

Post by TexMurphy »

Thanks milo.

I would really apriciate it.

Also another question. How do I create .dat files for the mod?

Thanks agian.
Tex
User avatar
TheDeadlyShoe
Posts: 549
Joined: Tue Apr 06, 2004 3:06 pm

RE: Milo-Question: Nebulas

Post by TheDeadlyShoe »

There should be a utility to create DATs on the Starshatter site.
@TheDeadlyShoe> Unless, say, you could make black holes at will.
@Razeam> I can do that but I don't want to.
Mehrunes
Posts: 257
Joined: Wed Mar 31, 2004 6:56 am
Contact:

RE: Milo-Question: Nebulas

Post by Mehrunes »

It comes with the game, it's called modfile.exe. The instructions for it seem to have disappeared though.
Kuokkanen
Posts: 3752
Joined: Fri Apr 02, 2004 1:16 pm

RE: Milo-Question: Nebulas

Post by Kuokkanen »

http://www.starshatter.com/downloads.htm
As I recall, program available there should contain instructions. I assume instructions are compatible with retail version.
You know what they say, don't you? About how us MechWarriors are the modern knights, how warfare has become civilized now that we have to abide by conventions and rules of war. Don't believe it.

MekWars
Post Reply

Return to “Starshatter: The Gathering Storm”