yurisuika / Raised

Raises the hotbar so the selector is not cut off!
GNU Lesser General Public License v3.0
17 stars 5 forks source link

AutoHUD Compatibility #75

Closed DarkFireNinja closed 7 months ago

DarkFireNinja commented 9 months ago

When using this mod with the AutoHUD mod, i noticed that the items in the hotbar are misaligned. As shown here: 2023-11-22_23 51 43

After digging around in the AutoHUD settings a little bit, i found that if i turned off the Fade option then the items were aligned, but the item borders from the Item Borders mod were not: 2023-11-23_00 05 04

I am using version 1.20.1 of Minecraft on Quilt, with the newest version of both Raised and AutoHUD. And i have my Hud height at 10 in the Raised settings. (turning the Support option in the Raised settings on or off didn't seem to be changing anything)

Thanks!

yurisuika commented 9 months ago

Item Borders was determined to not be compatible because it creates a new matrix stack (#65). As far as its behavior with AutoHud, that is peculiar. You may notice that while it may fade ItemBorders, it will not animate it, whether Raised is installed or not. This is likely because of the same reason.

Crendgrim commented 9 months ago

Ah, you raised this here as well. Link for reference: Crendgrim/AutoHUD#79

I can confirm that AutoHUD is incompatible with ItemBorders for the same reason as #65. I sent a PR to ItemBorders that has not been accepted (or responded to) yet.

If there is a further incompatibility between AutoHUD and Raised, I'm happy to investigate that, but I believe this to be ItemBorder's doing (AHilyard/ItemBorders#20, AHilyard/ItemBorders#21).

DarkFireNinja commented 9 months ago

@yurisuika Thanks for letting me know about the issue having to do with Item Borders and not with Raised. But is there still a way to get Raised to work with AutoHUD without having to turn the fade option off?

Thanks!

Crendgrim commented 9 months ago

I have a fix for this lined up in the next AutoHUD release, though for Fabric only.

@yurisuika is there a way similar to Fabric's ObjectShare to easily get the HUD offset on Forge?

DarkFireNinja commented 9 months ago

@Crendgrim Thanks a lot for fixing this issue in the newest version! I'm very grateful. As for the problem with Item Borders and Raised, i will be patient, no worries :D

yurisuika commented 8 months ago

I have a fix for this lined up in the next AutoHUD release, though for Fabric only.

@yurisuika is there a way similar to Fabric's ObjectShare to easily get the HUD offset on Forge?

In the past I asked on the Forge Discord if there was an analog to ObjectShare with Forge and the post was just deleted, so if they don't want me to know I guess I cannot answer you. It would be great if there were.

If you are willing to have a soft dependency, in the RaisedConfig class I have some public static methods that should expose these variables such as RaisedConfig.getHud(). You'd just have to run a check like ModList.get().isLoaded("raised"). https://github.com/yurisuika/Raised/blob/Forge-1.20.2/src/main/java/dev/yurisuika/raised/client/option/RaisedConfig.java

Sorry for the slow response.