Problem: Frames Win Games?


Reported By: David Tarnowski

November 17th, 2023

THE PROBLEM

This week, our focus shifted to a critical performance issue affecting our game. Players experienced significant framerate drops while exploring different areas of our world. This was particularly noticeable in densely populated areas with complex environmental elements. The challenge was to identify and rectify the causes without compromising the visual appeal and immersive experience of the game.

THE SOLUTION


Image A. Detail and beauty abound

After thorough analysis and testing, we implemented two key changes to address the performance issues.

Firstly, we tackled the excessive rendering load caused by shadows. By removing shadows from plants and trees, we significantly reduced the graphical processing required. This step alone improved the framerate considerably, and, surprisingly, it had minimal impact on the overall visual quality. The game world still retains its vibrant and detailed appearance, but now runs much smoother (Image A).


Image B. The world is alive but no enemies, because no player.

Secondly, we revised the enemy spawning mechanism. Previously, enemy spawners activated all their entities at the game's start, leading to a high number of idle enemies that consumed resources unnecessarily. We've now optimized this by altering the spawners to activate only when the player is within a certain range (Image B). This change means that the game doesn't waste resources on enemies that the player might not encounter for a while, or possibly ever.

Looking ahead, we plan to further optimize the game by implementing triggers within levels. These triggers will dynamically spawn and despawn certain world elements based on the player's location and actions. The goal is to make these changes imperceptible to the player, yet effective in conserving resources and maintaining a high and stable framerate.

Overall, these optimizations have already had a noticeable impact on game performance. We're committed to continuously refining our game to ensure the best possible experience for our players. Stay tuned for more updates as we progress in our journey of making our game world as efficient as it is engaging.

Stay connected for more updates from our development journey. Your feedback and support are invaluable to us as we strive to create an immersive and seamless gaming experience.

Get Psyche

Leave a comment

Log in with itch.io to leave a comment.