PDA

View Full Version : Tutorial: creating new skies



Duke John
07-12-2006, 09:21
Creating new skies for battlemaps
In this tutorial you will learn how to add new sky textures to R:TW.

Tools used in this tutorial
3ds Max 6.0, the image http://files.upl.silentwhisper.net/upload0/tut_tree_3dsmax.jpg indicates that a 3ds max command or menu option is used.
PhotoShop or any other image editing program.
Skybox creator scene, see appendix A for link.


Step 1: Sky texture
You will need to have a texture depicting a sky with clouds. The ratio width:height should be around 4:1. Try to get an image that does not have strong lighting effects. The left side of the image needs to match up seamlessly with the right side.


Step 2: Setting the material
Open the Sky Creator scene in 3ds max. You probably get warnings about textures that cannot be found, so lets first fix that:
http://files.upl.silentwhisper.net/upload0/tut_tree_3dsmax.jpg Open the Material Editor and select the second material. Set the Diffuse Color Map to your sky texture you made in step 1.
http://files.upl.silentwhisper.net/upload4/how_skies_are_made_material.jpg

Step 3: Rendering
http://files.upl.silentwhisper.net/upload0/tut_tree_3dsmax.jpg Open the Material Editor again and select the first material. Then click on "Pick Object and Render Maps" (see image in step 2). Then select "Box01" (see image below).
http://files.upl.silentwhisper.net/upload4/how_skies_are_made_scene.jpg
3ds max will now render the sphere with the sky texture as reflected on the sides of the cube. The renders will automatically be saved. You can remove the render of the bottom side.

Step 4: Image editing
The image below should explain clearly enough what steps you need to do. But first remove all the black parts from the horizontal renders and resize them to 1008x506 and resize the top image to 1008x1008.
http://files.upl.silentwhisper.net/upload4/how_skies_are_made_-_diagram.gif

And in plain text:

Non-overlapped dimensions
Resize to:
cloud_01 BK: 1008x506
cloud_02 RT: 1008x506
cloud_03 LT: 1008x506
cloud_04 FR: 1008x506
cloud_TOP UP: 1008x1008

Additions
1 to 4: add 8 pixels from a horizontal neighbour.
TOP: add 8 pixels from the top of each horizontal texture.
1 and 3: add to the top 6 pixels from bottom/top of the top texture with a 8 pixel offset.
2 and 4: add to the top 7 pixels from left/right side of the top texture with a 8 pixel offset.

Cropping
2 and 4: bottom row of pixels is removed.

Merging
Attach 2 to the bottom of 1.
Attach 4 to the bottom of 3.

Step 5: Naming the files
The images containing side 1 and 2 are called cloud_01-02_##.tga.dds.
The images containing side 1 and 2 are called cloud_03-04_##.tga.dds
The images containing the top side are called cloud_top_##.tga.dds

Where ## is a number depending on wether the cloud is put in the light, medium or heavy cloud folders; Data\sky\clouds\. Each folder has a range of allowed numbers as follows:
- light: 06, 07, 08, 09, 10, 22, 23, 26;
- medium: 01, 02, 03, 04, 05, 16, 17, 18, 19, 20, 21;
- heavy: 11, 12, 13, 14, 15.


A few remarks
You can dictate which cloud type (light, medium, heavy) is used for which type of weather in descr_daytypes.txt.

R:TW seem to randomly pick a sky texture from a folder so edit all textures with the same style for an uniform look.

This method does not use alpha maps and as a result you will not see the actual sky colour of the R:TW engine.

You can probably use programs such as TerraGen to create the same kind of textures as the original R:TW skies. I would suggest using photos though for a more realistic and natural look.

This method is most likely also used for M2:TW.

And the sky textures featured in NTW2:
http://forum.thelordz.co.uk/files/image70_399.jpg
Note that I will not upload these sky textures and neither will the NTW2 sky textures be allowed to extracted and used for public use. This has nothing to do with making an unique mod as I have already released some vegetation models and have kept nothing secret. Lets just say that the skies might look familiar to some people :wink:


That was the end of the tutorial. I hope I have included every step. If it is not working for you then please describe your problem in detail and include screenshots if needed. Anything less is not honouring the time I put in researching and writing this method and you might not get a reply from me.

Have fun and good luck with making skies!

Good luck,
Duke John




Appendix A: Sky creation tools
I have made a pack containing a scene to setup and render your skies.

User Agreement
Do whatever you like with the files.

Download
http://www.totalwar.org/Downloads/Rtw_Uploads/RTWupload/skybox_creator.zip Please PM me if the link is broken.
In the ZIP-file you will find images used for this tutorial, plus a quick rundown of all edits in the textfile.
skybox creator.max is the 3ds max scene that contains the sky sphere and the materials to render the sides for the skybox.

PROMETHEUS
07-13-2006, 15:10
Lets just say that the skies might look familiar to some people ~;) ~;)

PROMETHEUS
07-14-2006, 10:08
Thanks DJ , I made actually the same thing by fowwoling a tutorial online from wikipedia , Can't find it now though to add the link there too for the ones interested , anyway online there are other tutorials too , but yours is the best ^^ ....:laugh4:

Duke John
07-14-2006, 10:31
Yes, I also found an online tutorial from which I learned how to create proper textures for simulating a sky with just a box. The tricky bit which took alot of time was finding out how many extra pixels were placed on each side. I guess CA did that to avoid "bleeding" of pixels, just like you see black lines in the middle of soldier faces when the UV coordinates are too close to a black background.

PROMETHEUS
07-14-2006, 11:26
True , I instead was making it only on one side shifting to the left , weird but worked , the problem I was having was about curvature of the skyes .... then I discovered the online tut , but didnt had time to experiment , with your preset scene will be another thing ... thanlyou ^^ ....

wagtailcello
07-15-2006, 00:16
Note that I will not upload these sky textures and neither will the NTW2 sky textures be allowed to extracted and used for public use


So for those of us who cant afford to buy a £2000 3ds max software we do what? Its like dangling a carrot to the majority that will never benefit, still its your work i suppose.

PROMETHEUS
07-15-2006, 08:14
Note that I will not upload these sky textures and neither will the NTW2 sky textures be allowed to extracted and used for public use


So for those of us who cant afford to buy a £2000 3ds max software we do what? Its like dangling a carrot to the majority that will never benefit, still its your work i suppose.
Ho man , there are other modders that could do those skyes thanks to DJ for sharing the tutorial , so you should be happy , and wait for someone to soon produce some great sky and share with everyone .....

Btw DJ You forgot to edit the title of the tutorial ....~;)

wagtailcello
07-15-2006, 09:06
ive calmed down now anyway, ive been waiting TEN months because i wanted to use DJ's scenery because i regard his work as perfect. I would have liked to use it to improve the RTW scenery (just on my PC), my not a big fan of the napoleonic era you see. So i was dissapointed when i read his statement.
Anyway Prom, if you do some for us then i cant thankyou enough and to all of you that share your work with the rest of us
To DJ, thanks for sharing your knowledge with the rest and good luck with NTW2 :2thumbsup:

Duke John
07-16-2006, 08:34
ive been waiting TEN months because i wanted to use DJ's scenery because i regard his work as perfect.
That is a nice thing to say! :bow:

But I'm not going to stop you from using the NTW2 skies in your own personal mods or original R:TW. You will have to wait though, since I guess you understand that if I released my vegetation and sky files alot of mods will look like NTW2. First release of NTW2 should be in August.

This tutorial is primarily for modding teams that practically cannot exist without someone having 3ds max.


Btw DJ You forgot to edit the title of the tutorial ...
:grin:

wagtailcello
07-17-2006, 15:58
[QUOTE=Duke John]That is a nice thing to say! :bow:

But I'm not going to stop you from using the NTW2 skies in your own personal mods or original R:TW. You will have to wait though, since I guess you understand that if I released my vegetation and sky files alot of mods will look like NTW2. First release of NTW2 should be in August.

Thankyou DJ, most apprechiated :-)

Lovasìjász
07-26-2006, 22:44
couple of things about this.

When you get the FR (front) image, it will have an edge straight down the center, unless you manage to get a screenshot where the clouds either end and only blue sky shows, or somehow the clouds are so thick that it's not noticable, altough you need to be lucky not to have some sort of edge going on.

So,

I'm not sure, either try to smudge away the edge in photoshop, or...how about
using the BK (back) image flipped 180 vertically as the front image?

:juggle2:

Duke John
07-28-2006, 14:38
The source image should be edited in such a way that the left side matches up with the right side, so that it can seamlessly be mapped on a cilinder. What you could do is copying a middle section of the image and paste one half on the left side and the other on the right side.

davide.cool
08-23-2006, 16:50
can u explain me a little bit easily what to do after step number 2? thanks

repman
09-03-2006, 10:48
The problem is if you don't have the rendering tool and you take a big 360degree picture (examples from the internet) and cut it into pieces and follow the duke tutorial you get still the problems with the edges, because its not a real skxbox

Here is a tutorial how to generate the necessary files with terragen to construct then a real skybox as the duke has shown in his tutorial
http://fps.brainerd.net/terragen.htm

Here is a tutorial how to generate skyboxes from imported images using freeware blender
http://en.wikibooks.org/wiki/Blender_3D:_Noob_to_Pro/Build_a_skybox

here is a wiki about skyboxes
http://en.wikipedia.org/wiki/Skybox_(video_games)

here is a very good tutorial about skyboxes in general and using 3dmax (you need to register)
http://www.gamasutra.com/features/19981023/bell_01.htm

repman