Presentation is loading. Please wait.

Presentation is loading. Please wait.

3D Game Programming All in One By Kenneth C. Finney.

Similar presentations


Presentation on theme: "3D Game Programming All in One By Kenneth C. Finney."— Presentation transcript:

1 3D Game Programming All in One By Kenneth C. Finney

2 Chapter 18 Making the Game World Environment

3 Making the Game World Environment Sky Clouds Water

4 Making the Game World Environment Skyboxes cube that surrounds the player character each inside face depicts a view in all cardinal directions, plus up and down Skybox is never reachable by player character

5 Making the Game World Environment Skyboxes perspective correction of skybox images is necessary skybox images need to be tilable all images should be the same resolution skybox image resolution can be mathematically optimized

6 Making the Game World Environment Lab 1: Making Skybox Image Use paint program to create a skybox Practice making images tilable Practice adjusting for perspective error Introduction to material (DML) file Test in game world

7 Making the Game World Environment Cloud Layers Create cloud textures with alpha channel Multiple layers can be created Layers move at different speeds Layers are unreachable Layers can be set to varying 'virtual' separations

8 Making the Game World Environment Lab 2: Creating clouds Practice making cloud images with alpha channel Practice adjusting cloud layer properties More practice with DML file Test in game world

9 Making the Game World Environment Fog limited volumetric fog adjustable vertical height & thickness, but not horizontal depth adjustable color fog is enterable by player character

10 Making the Game World Environment Storms Torque has built-in storm generation capability A storm is precipitation, fog, thunder, and lightning Storm parameters are adjustable Timing, gradual onset and ending

11 Making the Game World Environment Storm Materials precipitation particle images defined in a single PNG file with alpha channel Precipitation particle image has 16 'drop' images in a 4x4 grid

12 Making the Game World Environment Storm Materials Lightning images defined in separate PNG files without alpha channel Black color is used to define transparent areas of images

13 Making the Game World Environment Lightning Need a LightningData datablock LightningData datablock points to lightning images with a DML file Need a Lightning object definition Lighting object points to the desired LightningData datablock

14 Making the Game World Environment Rain PrecipitationData datablock points to a DML file A Precipitation object definition points to a PrecipitationData datablock Rain only falls in an area around the player character

15 Making the Game World Environment Lab 3: A Perfect Storm use console to invoke a storm combine use of Sky.stormCloud method and Precipitation.stormPrecipitation method

16 Making the Game World Environment Waterblocks Special objects inserted as part of a mission tiled like terrain tiles textures can be used, same as clouds

17 Making the Game World Environment Terraforming Torque Terrain Editor allows you to 'paint' terrain Adjustable brush can be used to add or remove dirt Ideal method for quick terrain creation

18 Making the Game World Environment Lab 4: Terraforming learn the Terrain Editor practice creating various terrain shapes learn how to use 'fly' mode

19 Summary Skyboxes, clouds, and water define a game world environment Use Skyboxes to simulate distant horizons and sky Use Cloud layers in the Sky object to define overhead cloud movement Storms are the integration of cloud layers, fog, precipitation, and lightning Use WaterBlocks to define bodies of water


Download ppt "3D Game Programming All in One By Kenneth C. Finney."

Similar presentations


Ads by Google