Game performance drops after a while

Correct, Trigger Once does not behave as you’d expect on for each. It makes the event only occur once…but only for the first instance it is used on. A lot of people fall into that issue and it leads to something where they create object instances, then they’re wondering why they’ve ended up with hundreds of object instances when they expect 5.

Normally the recommendation is instead of trigger once, add a boolean variable to the object, require it to be false as a condition of the “For each” event, then set it to True as the last action of the event. (You would then also reset that to False whenever you do your other actions that would normally be triggering the “For each”)

Really? So there are some changes under the GDevelop hood that effect performance? I hope someone who works on developing GDevelop is taking note…

1 Like

For clarification, the Devs have been tracking this:

Unfortunately, no one has been able to provide a reproduceable issue that occurs, pinpoint an exact version where it performs differently (130 didn’t have any major changes, for example), or are reporting different things entirely (other users reporting their games suddenly perform slowly from the start, which is very different than what Brainofcthulu is experiencing).

The only through-line has been the users may have older hardware that is no longer supported by Chromium’s WebGL setup, which would mean they’re no longer supported by current versions of electron.

So it is either isolated to events that haven’t been reproduced yet, specific to their machines and WebGL support, or a placebo from going back to prior versions (even something as simple as their machine not clearing cache/memory/storage correctly on previews, and going back to prior versions clears it could lead to this).

I do know there is going to be another electron update, which will include a newer version of Chromium (incase it is a Chromium memory leak or something), but if it is a minimum-WebGL spec change, that’s permanent.

2 Likes