Closed abel1502 closed 6 months ago
Actually, Gizmos are destroyed and remade each frame, so that line works as intended and updates the description once per gizmo.
@legodude17 perhaps this is a conflict with some performance mod, like RocketMan or Dub's Mint Menus? Apparently some mod caches gui elements for performance reasons. If so, I'd argue this issue still deserves attention, since those mods are used very frequently, including in conjuction with VE.
Also, once again, I have evidence that:
the highlighted code segment executes multiple times for a gizmo. Several times the preview did briefly render when I moved the mouse away, and I could clearly see the description had a large number of repetitions of a single line at the start of it.
the highlighted code segment is the cause of the observed issues. I have removed it and nothing else from VFECore.dll
via dnSpy, and the issue has been resolved for me.
As such, I'd argue this is both frequent enough and trivial enought to hotfix, that it deserves attention from the VE team, despite apparently being a mod conflict.
It's a conflict with Performance Optimizer, which has been known for a very long time. You can disable the gizmo optimization in that mod and it will fix the issue. Removing that line would remove the name of the ability from the tooltip when shrunk, which is a problem, because the name doesn't show anywhere else. There's not really a simple way to fix the issue while keeping the name. Technically we could keep another variable to only update the description once, but personally that's more complexity than I'm willing to introduce to fix what is essentially an issue with a seperate mod.
I've implemented a more robust mechanism which will work correctly with cached gizmos in #80, and will be glad if you take a look. I believe it's simple enough to your liking
Tooltips on psycasts (and other abilities, but psycasts are the most frequent case) don't show when the gizmo icon is shrunk. I've tracked the issue down to:
https://github.com/Vanilla-Expanded/VanillaExpandedFramework/blob/c3e880e0e27a6814d78818751728c6bb1af876e6/Source/VFECore/Abilities/Command_Ability.cs#L43-L46
This seems to cause infinitely stacking side effects, and since it's called in an OnGui method, it results in the description being unable to load itself. Removing those lines through dnSpy fixed the issue for me, so I'm certain this is indeed the cause.