Optimization/Level Design
Jump to navigation
Jump to search
Optimization is the act of reducing the computer's workload. In level design terms this is almost always related to reducing the amount of rendering that the video card must perform at any one time.
Areas
- Leaks
- There's no excuse! Leaks will invalidate almost all of your efforts elsewhere.
- Visibility
- Reducing the number of surfaces and objects that are be drawn in the first place. This is the largest section.
- Physics
- There are various tricks to avoid overloading the CPU with physics calculations.
- Material choices
- Correct material choices will allow your map to scale down its demands on slower computers.
- Lighting and reflections
- Real-time and file-size optimisations.
Commands
showbudget
- A panel which displays how your computer is spending its budget for each frame. It's the premier tool for working out exactly what's sucking up performance in your map.
- It's invoked with
+showbudget
and-showbudget
, which means that you can bind the former to a key (i.e.bind <key> +showbudget
) and it will only appear when you hold that button down. mat_wireframe
- A console variable that lets you see through walls. This way, you can see exactly what is being drawn - for reasons described in the visibility optimisation article, often more than you might think is sensible.
- There are three wireframe modes,
1
through to3
, which display the information you need with progressively fewer lines.
See also
- Budget
- Controlling Geometry Visibility and Compile Times
- Optimizing and Checking Your Map
- Optimization Commands
- Optimization (Non-Geometry)
- Geometry optimizations can be complicated, but there are several non-geometry aspects of optimization. Handling them can be an easy way to make your map faster. Keep these in mind when designing a new map, and consult individual sections where showbudget reports problems.
- Optimization (Geometry)
- Geometry-based optimizations are those that manipulate map geometry in order to change the way BSP behaves. These can be difficult, but extremely effective. Any professional-grade map will make use of some or all of these techniques.