Skybox

Posted By: hankenb01

Skybox - 12/23/06 03:58

I just bought gamestudio and read the tutorials and I cant figure out how to put a skybox in. I have bought skybox textures and I dont know how to implement them. Do I have to attach the skybox to the player as an entity or something? What am I missing here? Please be easy on me, I am kind of new at this.
Posted By: Zelek

Re: Skybox - 12/23/06 04:57

Create a new level, place a large cube and add the default texture, then add a position above the cube. Go to map properties, click the new script button, make it an A6 template project. Now for the sky stuff:

Open your project's .wdl file that was created when you created a new script in map properties. Add some code like this right before function main():
Code:

sky daysky_cube
{
type = <daysky+6.tga>;
flags = cube,visible;
layer = 3;
}



but change daysky+6.tga to your cube image. Do a search in the manual for "sky cube" to see how to set it up (it's the second result).

Lastly, add a large hollow cube to your level. Scale it up really big. Now go to the texture manager and add standard.wad to your project. Scroll down in the wad menu and assign your hollow cube one of the two sky textures. These textures have a special sky flag, and they won't actually show up when you run the game - it will be replaced by the sky you defined in the code. Make sure your hollow cube is passable to prevent collisions oddities.
Posted By: hankenb01

Re: Skybox - 12/23/06 05:31

Thank you so much, I never would have figured that out!
© 2024 lite-C Forums