skiingpenguins | 2009-12-16 20:48
Making Skyboxes in Terragen Classic
46
points ]
 (10 votes)

Skyboxes for Cube 2.

- By SkiingPenguins

- August, 2009

Introduction

A skybox for Cube 2 is 6 images; Front, Back, Left, Right, Up, and Down. These images are used to create a sky, or environment, in which the map is located. Many times, the skybox holds the sun, clouds, and inaccessible terrain. The terrain showed in the skybox cannot be walked upon by the player because it is just an image. More often then none, skyboxes are essential for a map to look real. In this document I will explain how to properly use Terragen Classic in an effort to create a skybox for cube 2. I will be using Sauerbraten Trooper Edition as the game in which I show how to import a skybox. I will also be using Windows and ImageMagick 6.5.4 Q16 (Refer to Links section for download)

1. Terrain Setup

In this tutorial we will be using Terragen Classic (Refer to Links section for download) to create our skybox. I will not provide help for creating terrains in Terragen throughout this tutorial. Go ahead and create your terrain and world. After you have got a decent world in Terragen, place your camera where you want to render your images at. The camera orientation does not matter at this point.

2. Rendering

To render your skybox, we will use a Terragen Script. The script is as follows:

InitAnim "C:\myskybox", 1
Zoom 1.0
CamP 0
CamH 0
FRend
CamH 180
FRend
CamH 90
FRend
CamH 270
FRend
CamH 270
CamP -90
FRend
CamP 90
Frend


Now, save the script as “Render.tgs” without the quotes, using notepad or your favorite text editor. You will have to edit the line “InitAnim "C:\myskybox", 1” and specify your own directory for skybox render output. Go into Terragen and click Terragen, then Execute Script. Navigate to your Render.tgs and run it. The script will output 6 images. These images will be numbered, and will be in .bmp format. These are not your final skybox images.

3. Conversion

After the script has finished, navigate to the folder where the script put your images. You will need to make a “bmp2png.bat” file… or something similar. The ImageMajick script we will be using is as follows:

convert 0001.bmp myskybox_ft.png
convert 0002.bmp myskybox_bk.png
convert 0006.bmp myskybox_up.png
convert 0003.bmp myskybox_lf.png
convert 0004.bmp myskybox_rt.png
convert 0005.bmp myskybox_dn.png

You will need to modify this script and replace “my skybox” with your skybox’s name. For this tutorial we will use “my skybox” as the name. run this .bat in the same folder as your images output by Terragen.

4. In-Game

Now that you have your .png skybox images, we can use them in Sauerbraten. Navigate to your Sauerbraten/packages folder and create a new folder. Name it anything you wish. For this tutorial, we will use the name “skies”. Copy your .png images to this folder. Now, go in-game into Sauerbraten and go to a map. It can even be a newmap. This doesn’t matter. Execute “/loadsky skies/my skybox” without the quotes in-game to load your skybox into the map. Your skybox will now appear. That’s it. Your Done. You’ve just created a skybox.

5. Publishing

This section is not necessary, unless you want to share your skybox. To package it, we will use the .zip format, as it is pretty much universal. The structure of your .zip file will be as follows:

myskybox.zip

  • /Packages/
    • /Skies/
      • myskybox_ft.png

      • myskybox_bk.png

      • /myskybox_up.png

      • myskybox_lf.png

      • myskybox_rt.png

      • myskybox_dn.png


Now that your skybox is in a .zip, all someone has to do is unzip the .zip to their sauerbraten directory. That is all that they will need to do to install your skybox.

6. Conclusion

Thank you for reading this skybox tutorial. Good day to you.

(THE END)

7. Links

Terragen Classic -- http://www.planetside.co.uk/content/view/16/28/
ImageMagick 6.5.4 Q16 -- http://www.imagemagick.org/download/binaries/ImageMagick-6.5.8-7-Q16-windows-dll.exe
D/L File: http://www.quadropolis.us/files/Skybox Tutorial.html.txt

46
points
 (10 votes)
User login
Users on Quadropolis
1 guest & no users online
Gangler
36
points ]
 (4 votes)
Created 2020-10-22 00:50
3 years 21 weeks ago
Zoocata
10
points ]
 (1 vote)
Created 2024-02-11 21:20
5 weeks 2 days ago
vampirefrog
10
points ]
 (1 vote)
Created 2023-07-23 20:02
34 weeks 2 days ago
36
points ]
 (4 votes)
Created 2020-12-10 12:49
3 years 14 weeks ago
Created 2023-12-12 23:34
13 weeks 6 days ago
Zoocata
Created 2023-11-27 23:00
16 weeks 22 hours ago
20
points ]
 (2 votes)
Created 2023-10-01 15:21
24 weeks 2 days ago
20
points ]
 (2 votes)
Created 2021-05-24 00:01
2 years 42 weeks ago
9
points ]
 (1 vote)
Created 2023-06-13 17:54
40 weeks 3 hours ago
Zoocata
27
points ]
 (3 votes)
Created 2023-05-05 20:58
45 weeks 4 days ago
Zoocata
18
points ]
 (2 votes)
Created 2023-03-02 01:40
1 year 2 weeks ago
Getridou
Created 2023-01-29 23:27
1 year 7 weeks ago
Created 2023-01-19 19:36
1 year 8 weeks ago
Getridou
Created 2023-01-10 17:10
1 year 9 weeks ago
Getridou
Created 2023-01-01 14:30
1 year 11 weeks ago
Getridou
Created 2023-01-01 10:58
1 year 11 weeks ago
Getridou
Created 2023-01-01 10:49
1 year 11 weeks ago
afroninja
17
points ]
 (2 votes)
Created 2023-01-01 06:32
1 year 11 weeks ago
36
points ]
 (7 votes)
Created 2010-04-01 07:57
13 years 50 weeks ago
57
points ]
 (6 votes)
Created 2020-12-04 12:05
3 years 15 weeks ago
Who's new
  • ColdIV
  • Aidan
  • Hunk
  • letic86
  • BATMAN