A performance bug can hide in the tiniest details

#1

This post (in a generally helpful topic) shows a practical examination of a performance bug causing game performance to suffer heavily, including a fun try-this-at-home experiment to lower your frame rate nearly instantly.

8 Likes

#2

Thanks for the insight, I’ve been looking for something like this for some time as I currently have 180 resources and I’d like to figure out what is degrading the clientside performance.

Keep the updates coming! :tada:

1 Like

#3

ESX maintainer here, I also hate the while true loops. Running all sorts of tasks including comparing coordinates to draw a circle is very common in a lot of scripts with a wait time… of basicly 0 frames. Then when you start to stack up scripts with heavy math every frame ofc performance will degrade.
I’ve always changed the wait times on loops to at least 10ms, which should help a bit, but e.g drawing circles must be run every frame on slow computers or else you’ll spot the circle blinking

2 Likes

#4

Could someone answer me why it is actually necessary to draw the circle continuously instead of making just a single call to show it and a single call to hide it.

0 Likes

#5

Because the native to draw it only draws it 1 frame each time you call it.

0 Likes