Cheos137 / ArmorpointsPlusplus

A light-weight mod overhauling vanilla ui components
https://modrinth.com/mod/armorpoints
MIT License
2 stars 2 forks source link

[Bug]: Compatibility with RPG-Hud [FORGE 1.12.2] #44

Closed tomygcz closed 1 year ago

tomygcz commented 1 year ago

Is there an existing issue for this?

Description

When I try to use the "RPG-Hud" HUDs, apart from the "Vanilla" preset, the game instantly crashes. Also, when both mods are installed, the "Armor Points ++ / Health Stacking" armor bar and health bar does not render.

Version

3.0.x for Minecraft Forge 1.12.2

Version

No response

To Reproduce

  1. Create a new world.
  2. Go to the "General" section of the config of "RPG-Hud" mod.
  3. Select another preset apart from "Vanilla".

Expexted Behavior

Additional Context

No response

Screenshots

No response

Relevant Log / Crash-Report Output

java.lang.UnsupportedOperationException: Attempted to call Event#setCanceled() on a non-cancelable event of type: dev.cheos.armorpointspp.ApppRenderGameOverlayEvent.Post
    at net.minecraftforge.fml.common.eventhandler.Event.setCanceled(Event.java:96)
    at net.spellcraftgaming.rpghud.main.RenderOverlay.onGameOverlayRender(RenderOverlay.java:56)
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_2252_RenderOverlay_onGameOverlayRender_RenderGameOverlayEvent.invoke(.dynamic)
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:90)
    at net.minecraftforge.fml.common.eventhandler.EventBus.post(EventBus.java:182)
    at dev.cheos.armorpointspp.RenderGameOverlayListener.post(RenderGameOverlayListener.java:125)
    at dev.cheos.armorpointspp.RenderGameOverlayListener.post(RenderGameOverlayListener.java:120)
    at dev.cheos.armorpointspp.RenderGameOverlayListener.handle(RenderGameOverlayListener.java:79)
    at dev.cheos.armorpointspp.RenderGameOverlayListener.handlen(RenderGameOverlayListener.java:30)
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_48_RenderGameOverlayListener_handlen_RenderGameOverlayEvent.invoke(.dynamic)
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:90)
    at net.minecraftforge.fml.common.eventhandler.EventBus.post(EventBus.java:182)
    at net.minecraftforge.client.GuiIngameForge.pre(GuiIngameForge.java:907)
    at net.minecraftforge.client.GuiIngameForge.renderHealth(GuiIngameForge.java:388)
    at net.minecraftforge.client.GuiIngameForge.renderGameOverlay(GuiIngameForge.java:154)
    at net.minecraft.client.renderer.EntityRenderer.updateCameraAndRender(EntityRenderer.java:1098)
    at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:1119)
    at net.minecraft.client.Minecraft.run(Minecraft.java:4614)
    at net.minecraft.client.main.Main.main(SourceFile:123)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:497)
    at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)
    at net.minecraft.launchwrapper.Launch.main(Launch.java:28)
Cheos137 commented 1 year ago

The underlying issue is faulty implementation from rpghud. Nothing i can do on my end to change this, really.

Try disabling mantle compatibility in the armorpointspp.cfg file, this should fix the issues you're facing though.

tomygcz commented 1 year ago

Oh okay I see. Thank you!