Minenash / CustomHUD

A highly customizable variable-based text HUD for Minecraft
MIT License
77 stars 23 forks source link

item variable's conditionals crash the game #87

Closed waxt0n closed 1 year ago

waxt0n commented 1 year ago

when trying to use any of the item variables as a conditional, the game crashes

potato8432 commented 1 year ago

i have the same issue, cant use item:\:max_dur as a condition

Minenash commented 1 year ago

Can both of you provide logs?

waxt0n commented 1 year ago

https://paste.ee/p/ICzdb here is log, i made a new instance, put mod menu, custom hud, and fabric api on it, then launched and added "{{item:weapon.mainhand:dur, "item has durablility"}}" to profile1

Minenash commented 1 year ago

Interesting, apparently I didn't add "." to the list of characters a variable could have in conditionals. I'll fix that for the next update.

In the meantime, you can avoid this by using the "shortcut" names like "mainhand" or "main" instead of "weapon.mainhand"

Minenash commented 1 year ago

Fixed in v3.1