Optimising maps for the idtech3 engine

CSG Subtract can cause problems if you subtract curves or complex brushes.

If your map leaks at compiling do NOT build a box around it but rather fix the leak. Follow the red line and you will always find the leaked spot. Sometimes it can be an entity, placed into the void by mistake, occurring the leak.

Or just a very small hole somewhere behind a patch mesh.

Always be sure you've built walls around your patch meshes, since they act like detail brushes. For leak-finding turn off all the detailed brushes (ctrl+d) and patches (ctrl+p). If the leak is resulting from a big wall then look if you turned the wall into a detail and make it structural again.

Turn a straight wall with many brushes and textures into one huge texture and one brush. It is about texture count and size versus brush count.

Use "detail brush" to reduce compile time.

Example 1: Stairs.

Converting those stairs into detail brushes tells the map compiler not to create leaf nodes.

Example 2: In the screenshot you can see several arches, triggers, water (under the triggers), cones and other patches.

Filter the cones and the patches since they are detailed anyway (ctrl+p). Now select all the small brushes (like the ones on the floor), the arches and all the brushes which won't block the view anyway and press (ctrl+m). You should also detail glass.

Patch meshes and detail brush filtered

Brushwork! The hollow function is a bad example how to arrange brushes because parts of the brush faces aren't visible in game. In old versions of gtkradiant the hollow function creates overlapping brushes. Try to avoid to use this function.

Do not overlap brushes like this

Using shaders or skies that cast light are easier to change and look far better than placing and testing each light entity one by one. Moreover wrong placed lights can cause nasty light spots.

Light entity unadjusted in the room.

Or they just look misplaced or wrong colored in game and thereby destroy the atmosphere. For example when the lighting is too strong for certain lights placed on the walls. Shader-emitted light looks more real and softer.

JPEG textures are smaller than TGA textures in bytes. TGA textures have more quality than JPEG textures. Does size still matter?

Place area portals into doors to reduce the amount of brushes being rendered when the door is closed and you can't see what's behind it anyway.

As you can see in this picture the door is closed but the engine still renders the faces behind.

Closed door without an areaportal and triangles enabled (r_showtris)

If you place an area portal, with the same sizes like the door, into the door the engine won't do anything behind until you open it.

Selected door

Selected area portal

Area portal and closed door

Area portal and opened door

Be sure that the brushes, connected to the ceiling, the floor and the four walls, around the area portal are structural. Furthermore the door musn't use any glass the player can look through.