Performance issues and overall choppiness in Bad Business

We can see that Windows experienced a drop in performance in late October but mostly recovered in November. Since then it has been somewhat variable and similar to historic levels. We can’t diagnose a specific drop in performance without Microprofiler dumps before and after the change. We will continue to monitor performance but there’s nothing specific we can do at this stage.

Microprofiler dumps are way too big in file sizes. What do these even contain?
and we are not authorized to send compressed 7z archives…

Post it on Google Drive or another cloud service and post the link here

Each Microprofiler dump is an HTML file that contains all the information that you see on screen non-mobile platforms. It contains the details of where the CPU time and memory is being used.

Hello! Bad Business programming guy here.

After messing around with this issue for a while we have finally cracked the puzzle and found the source of lag. Turns out, infinite tweens in hidden viewport frames impact performance negatively and cause a lot of jitter.
In the most recent Bad Business update, once the player exits a menu all contents of viewports in that menu are deleted and are reinserted once again when the player enters the menu anew. Contents of viewports are also not inserted on game start up.

Here is a comparison between the old version of the game and the new one:

The upper Before part of the image is from november last year, when we first started encountering the issue. Averaging 111 FPS, much jitter
The lower After part of the image was snapped yesterday, under the same conditions but with all the hidden viewports cleaned up and with all the new client updates ever since the issue was reported. Averaging 198 FPS (+78% !!!) and relatively no jitter

Example of how we have our UI set up:

9 Likes

I feel like I need to ask, were you running code on the contents of the viewport frames while they weren’t visible? I could understand the performance impact if your code is still animating the camos even while the frame isn’t visible.

However, if viewport frames that are invisible are just decreasing performance on their own with no code running, I should definitely look into removing their contents in my own games too.

There is no code running, just tweens

This is really interesting. I will take note of this for future development that may use tweens and viewports. Glad to gear you’s finally solved this one!

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