Hello, I’d like some help with an issue I’ve experienced while developing my game. its is experiencing high lag spikes caused by my main game scene and is carrying over to others when switching. When loading into the main game scene from the Godot editor, it runs smoothly. But loading from my menu into it has spikes of 1 second, and stays when switching. Strangely, pausing and resuming removes it, but also not always.
I think it’s because of the Animated sprite of the Environment background I have in the main scene, when testing, removing the background also got rid of the lag. So if anyone has advice on maintaining a large animated sprite, tell me. Or if I’m wrong, tell me.
I’d say this is a smaller game that loads fast enough. But I don’t have one. but I’ll try some graphic saving stuff I thought of and if those don’t work. I’ll add one.
It’s gone for now. The game has 1 environment with a different version for every combination of lights being on, instead of doing the obvious thing of splitting each lighted area into split images. So, fixed that. I should really think these things out before making them.
Edit:
I feel guilty for having this solution be what it appears for this. It’s a very general problem with a very only I can only do this because of how my game is set up. so I’ll give what little tips about game dev I know to make this a bit more satisfying for others with similar issues, but I am not qualified. Please one-up me in comments.
For my case, it was mainly a CanvasRendering issue with my sprites, so I just attempted to downsize high-res images to be more efficient. Inherit on texture settings makes it look better.
I’m sorry if this isn’t a satisfying answer.