Optimizing for level design.
Optimization is the process of refining and improving your levels technical performance. This could mean anything from
- increasing FPS to decreasing load times.
- Planning and iteration are keys to professional level design
- Polishing the process of making minor adjustments to improve the core experience
- Good playtesting helps you identify weakness and problems you can’t see
- Optimization makes sure your level runs smoothly and packs as much awesome content as possible.
Performance Targets:
- Arbitrary goals set by the project common performance measures
- Frames per second
- Max load time
- Max memory usage
- Size on disc
- Common areas for optimization
- AI, running AI can be serious drain on CPU performance
- FX, particle emitter can quickly bog the FPS
- Script Execution, Scripted gameplay can eat CPU cycles
- Memory Usage, Assets count VS memory footprints
- Streaming & Culling, How much do you have loaded and drawing?
Improving AI Performance
- Use fewer NPC’s, usually the single biggest driver of AI load is the number of NPCs
- Use Simpler NPCs Using NPCs with less complex Ai can improve overall performance.
Improving FX Performance
- Work with Art, talk to tech, level and FX artist about the performance issues
- Consolidate FX, replace small fx used together to create a larger effect with single large FX
- LoD & Draw distance, FX should have a good LoDs and draw distance to save performance
- LoD, Level Of Detail
Symptoms of poor script performance
- Unreliable Execution
- Input lag
- Poor AI performance in scripted sequences
- Overall performance degradation
Use Count VS Memory Footprint
- Every model that appears in the level must be loaded into memory
- Additional appearances of loaded models are cheap
- Profiling tools can tell you how many times a model appears and how much memory it uses
- Replace high memory cost models that only appear a few times if you can.
Other memory Optimization
- Level streaming reduces the overall memory cost of the level by breaking into smaller chunks
- Sight lines and LoD reduces the GPU memory load by limiting the visibility and fidelity of distant objects
- Work with programmers, whether you can’t figure out what is causing a performance problem, or how to solve a problem you’ve identified, programmers can help you better understand the tools and techniques for optimizing your level
Links
https://docs.unity3d.com/Manual/LevelOfDetail.html