heliosphere-xiv / plugin

Dalamud plugin for downloading and managing mods from Heliosphere
European Union Public License 1.2
14 stars 1 forks source link

fix: fonts render upon boot, no more hang #2

Closed thakyZ closed 1 year ago

thakyZ commented 1 year ago

After days of tinkering with how to get the fonts to not hang, and after referencing other plugins, I have come up with, almost, the best way to load the fonts, so no matter how many plugins someone has, the game no longer hangs. There are some lines of code in GameFont.cs that could be removed or refactored (Specifically in the PreRenderFonts function).

anna-is-cute commented 1 year ago

So you're just rendering them at boot, moving the hang there instead? Do you actually hang without this? The game never becomes responsive again?

thakyZ commented 1 year ago

Yea, I just render them at boot now. No, I don't hang anymore with this. The game never becomes responsive again with the main repo version until it eventually closes because I assume it was unresponsive for too long. I have tried not interacting with the window whatsoever while I had the game hanging, and it still eventually closed out.

Also, I mentioned this in the Discord, the hangs seem to have some correlation to how many plugins the user has enabled and running actively. Because I tried doing process of elimination when going through what plugin would be causing it, and I noticed the more plugins I enabled ⇾ then restarted the game ⇾ and tried again would have a longer and longer hang, though until I enabled the last one did it just end up freezing and later crashing. I would assume having a strong CPU (AMD Ryzen 5 3600 as a base mark for one that freezes, as it's what I am currently using) could probably elevate this issue, but there are reasons people have for not getting better ones.

anna-is-cute commented 1 year ago

Yeah, should find the real cause of this issue, then.