Game running at very low FPS on raspberry pi 4

Godot Version

4.2.1

Question

My fairly simple platform game (Think original super mario in size) runs at a very low FPS(between 2 - 5) on the raspberry pi 4 I am using as an arcade machine. I have run the profiler during debug to see that the amount of objects is around 2000. The level is built with tilemaps. Even a static homescreen that is built with the tilemap lags, and that is around 1.8k objects, which I assume is each of the tiles. The physics from player/enemies does not seem to affect it much, since the homescreen does not load any sort of entities. I have made sure the build is not debug, so that should be fine.

Is there any setting in tilemaps, or maybe its something else going wrong. When running the executable on the raspberry pi, the only real errors/warnings I get is that it changed to opengles(or openglss, I do not remember the exact name) instead of openGL due to drivers. So maybe things are not being rendered effectively. But even with raspberry pi limited hardware, 2000 tiles seems like something it should handle, or am I wrong?

Thank you in adnvance!

try change the tilemap quadrant size see if it actually affect the fps or not
else then you might want to render smaller amount of tiles, utilize tilemap changing/ tiles generation. so it doesnt have to load like thousands tile right away

What I read about tilemap etc so far is that you cannot really hide them, the same way as say sprites etc. I looked into the VisibilityEnabler etc, but those mostly work on sprites. Or, they could hide the entire tilemap, but since that is the entire map, might not be good. Do you maybe mean that I make several smaller tilemaps, and load sections, or eg chunks and load them as you go?

Update: When I removed all PointLight etc, i got a biiig increase in fps, going from 3 to 20 fps. Unclear why it cannot handle any light, but oh well. I can live without it for now.

yes, point light 2d consume lots of fps

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.