[QnD] Grimz Quick and Dirty 3d skybox

GrimGriz

L10: Glamorous Member
Jan 2, 2009
774
133
There are other skybox tutorials, most notably the one I learned most of the following from:
http://forums.tf2maps.net/showthread.php?t=116

but as they still left me slightly confused, I thought I'd try to put one together for those of us that are less gifted :)

This tutorial assumes that you have a map already that you want to build a skybox for. The map being used for the tutorial is very small, so if yours looks much larger, that's completely normal :)

1. CLEAR THE ORIGIN'S PLANES
The origin is the very center of the mapping environment made available to you in hammer. When you zoom the front, side, and top views very far out, you can identify the origin by the intersecting teal lines.
picture.php


As you can see in the side view, part of my map intersects one of the origin lines, and to avoid future complications*1 it's best to grab the whole map and move it off the teal lines at this point.
picture.php
YAY!

2. STEAL A VALVE ENVIRONMENT
The quickest and dirtiest way is to snatch the entities from the environment gallery that acegikmo posted here: http://forums.tf2maps.net/downloads.php?do=file&id=916

Just pick the environment you want and click on the group of entities in the middle of it. Select copy, go back to your map, and paste them near your own entities.

!Important! - If you do this, select the light environment entity, and copy the comment section - then open the map properties and paste the comment into the "skybox texture name" field (see below).
picture.php
picture.php



3. ENCASE YOUR MAP IN A SKYBOX ROOM
Make 6 walls, a floor, and a ceiling around your map using tools/toolsskybox texture. I go 64 units thick to be on the safe side.
picture.php


*1 - skybox in a solid error
 

GrimGriz

L10: Glamorous Member
Jan 2, 2009
774
133
4. EXTEND THE GROUND

Part of the benefit of a 3d skybox is making the map look bigger than it is...and when you do that, it helps if the ground lines up inside and outside the skybox. Lucky for me, the ground for this tutorial is flat. The following theory should work for unflat ground, though your mileage may vary.

Simply select your ground, grab the edge, and extend it so it sticks out of your skybox map encasement, like so:
picture.php


(don't worry, we'll put it back later)

5. POSITION THE SKY CAMERA

Create a sky camera entity and put it on the origin by moving it to where the teal lines intersect. Be sure to move it to the origin on the top view AND the side view, not like the monkey in this picture did:

picture.php


6. MAKE A MINIATURE OF WHAT YOU HAVE

Holding control and clicking, select your extended ground, your skybox encasement, and the sky camera you just placed. Then shift+click and drag it to make a copy.

Right-click on the copy and select transform (or hit ctrl+m), select scale, and set the values to 0.0625 (1/16th).

picture.php


When you hit enter, you'll have your map in its encasement, and a miniature copy too.


7. STEAL THE SUN FROM THE SKY (OPTIONAL)

I like to grab the sky camera and propdynamic sunnoon.mdl from the decompiled valve maps found here: http://forums.tf2maps.net/showthread.php?t=4855

Select them both from the valve skybox, shift+drag the group to clone it, then copy it and paste it into your map.

Drag it so the sky camera from the stolen sun and sky camera is in the exact same position as your sky camera from the sky camera and miniature map. This will position the stolen sun correctly. Again, be sure and position using both the top and side view.

picture.php

Once in place, go ahead and delete one of sky cameras.
 
Last edited:

GrimGriz

L10: Glamorous Member
Jan 2, 2009
774
133
8. CREATE YOUR SKYBOX!

Again using the tools/toolsskybox texture and the brush tool, create all 6 sides of a box. This time, encase the stolen sun, sky camera, and miniature map.

picture.php


In the picture, I've retextured the miniature with an ugly texture so that you could better see how massive the skybox is compared to the miniature. That's a side effect of making it big enough to contain the sunnoon.mdl

9. CLONE AND STRETCH THE MINIATURE GROUND

Grab the little piece of miniature ground sticking out of your model in top view, and shift drag it to clone it. Stretch the cloned ground to fill from the skybox wall to the miniature wall.

picture.php


When my default texture scale was 0.25, I change the texture scale on the new pieces. I put 0.015625 in the boxes (which my calculator tells me is 0.25/16) but I'm not sure if it works as when I look at it later it is rounded to 0.02 :)

Repeat step 9 three more times until your the space between your miniature and the walls of the skybox is completely filled on every side of the miniature.


10. DROPAPROPIN (OPTIONAL)

You can place props in your skybox. Just remember, they'll be 16 times larger while you're playing. For this map, I've opted to put a pyro ragdoll in the skybox ...but for most maps I'd recommend a model with skybox in its name. They tend to be 16 times smaller than normal so they look normal size while you play.

11. CLEANUP TIME!

- Delete the sky camera at the origin (each map only needs one, and yours is now in the skybox).
- Delete the miniature walls and floor in the skybox.
- pull your ground back inside your map encasement.


12. TADA!

zip containing vmf and bsp -> http://forums.tf2maps.net/downloads.php?do=file&id=975
 
Last edited: