onTick method on widgets isn't called with Forge Addon
Mads_Gamer_DK
2023-11-04 17:42:36
Robby_
Chralle2002: onTick method on widgets isn't called with Forge Addon
Popis
NOTE: This only happends when using Forge Loader Addon
The onTick method will not be called for widgets that occour after a widget that extends ItemHudWidget (which is enabled) in the list HudWidgetRendererWidget#getChildren() returns.
ItemStack#getCurrentDamageValue() causes a NullPointerException:

which causes the rest of the widgets' onTick method not to be called.
NOTE: Only if you have no item equiped (as shown in the video)
STEPS TO REPRODUCE:
Step 1:
- Install Forge Loader Addon
Step 2: - Enable any item widget that shows the durabilty (Make sure you dont have this item equiped)
Step 3: - Now all widgets that is updated after the item widget. Will not be updated. (NOTE: this is only the case if the widget is updated from the onTick method)
Step 4: - For example the HeadOwner addon's Head Owner widget will not be updated.
Showcase:https://youtu.be/FvJcFs00V2 E
Operating System: Windows 10
LabyMod Version: 4.1.3
Minecraft Version: 1.8.9
Installed Addons: Forge Loader