ArmorChroma Incompatibility
naqaden opened this issue ยท 3 comments
Though backpacks can be worn as armor, ItemBackpack cannot be cast to ItemArmor, causing a crash with ArmorChroma:
[main/FATAL] [minecraft/Minecraft]: Unreported exception thrown!
java.lang.ClassCastException: net.mcft.copy.backpacks.item.ItemBackpack cannot be cast to net.minecraft.item.ItemArmor
at nukeduck.armorchroma.GuiArmor.drawPartialRow(GuiArmor.java:145) ~[GuiArmor.class:?]
at nukeduck.armorchroma.GuiArmor.drawPiece(GuiArmor.java:137) ~[GuiArmor.class:?]
at nukeduck.armorchroma.GuiArmor.draw(GuiArmor.java:92) ~[GuiArmor.class:?]
at nukeduck.armorchroma.ArmorChroma.onRenderOverlay(ArmorChroma.java:50) ~[ArmorChroma.class:?]
at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_35_ArmorChroma_onRenderOverlay_Pre.invoke(.dynamic) ~[?:?]
at net.minecraftforge.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:90) ~[ASMEventHandler.class:?]
at net.minecraftforge.fml.common.eventhandler.EventBus.post(EventBus.java:182) ~[EventBus.class:?]
at net.minecraftforge.client.GuiIngameForge.pre(GuiIngameForge.java:907) ~[GuiIngameForge.class:?]
at net.minecraftforge.client.GuiIngameForge.renderArmor(GuiIngameForge.java:290) ~[GuiIngameForge.class:?]
at net.minecraftforge.client.GuiIngameForge.func_175180_a(GuiIngameForge.java:155) ~[GuiIngameForge.class:?]
at net.minecraft.client.renderer.EntityRenderer.func_181560_a(EntityRenderer.java:1098) ~[buq.class:?]
at net.minecraft.client.Minecraft.func_71411_J(Minecraft.java:1117) ~[bib.class:?]
at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:397) [bib.class:?]
at net.minecraft.client.main.Main.main(SourceFile:123) [Main.class:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_181]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_181]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_181]
at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_181]
at net.minecraft.launchwrapper.Launch.launch(Launch.java:135) [launchwrapper-1.12.jar:?]
at net.minecraft.launchwrapper.Launch.main(Launch.java:28) [launchwrapper-1.12.jar:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_181]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_181]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_181]
at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_181]
at org.multimc.onesix.OneSixLauncher.launchWithMainClass(OneSixLauncher.java:196) [NewLaunch.jar:?]
at org.multimc.onesix.OneSixLauncher.launch(OneSixLauncher.java:231) [NewLaunch.jar:?]
at org.multimc.EntryPoint.listen(EntryPoint.java:143) [NewLaunch.jar:?]
at org.multimc.EntryPoint.main(EntryPoint.java:34) [NewLaunch.jar:?]
Mods have to learn that it's not just ItemArmor
items that could go into the armor slots. It's actually pretty common for server plugins to put blocks on players' heads. In fact, a pumpkin block is not an ItemArmor
and it can still be equipped. I wonder if that would also crash ArmorChroma.
This will have to be handled in the other mod. Backpacks won't become an ItemArmor
. It is made like this to prevent many mods from treating is as such, breaking it in unexpected ways.
I see. Thanks for the quick reply. I will take it up with ArmorChroma.
Btw pumpkin blocks are not an issue. I guess it's because they don't provide armor, but good point nonetheless.