Mod Menu

Mod Menu

37M Downloads

Mod Menu icon crash (porting lib)

NolanHewitt opened this issue ยท 2 comments

commented

Going down to Porting Lib (from create patch f for fabric, 1.20.1) in Mod Menu crashes the game with the following error:

[02:24:49] [Render thread/ERROR]:
Reported exception thrown!
net.minecraft.ReportedException: Rendering screen
at net.minecraft.client.renderer.GameRenderer.render(GameRenderer.java:954) ~[client-intermediary.jar:?]
at net.minecraft.client.Minecraft.runTick(Minecraft.java:1219) ~[client-intermediary.jar:?]
at net.minecraft.client.Minecraft.run(Minecraft.java:802) ~[client-intermediary.jar:?]
at net.minecraft.client.main.Main.main(Main.java:250) ~[1.20.1-0.15.7.jar:?]
at net.fabricmc.loader.impl.game.minecraft.MinecraftGameProvider.launch(MinecraftGameProvider.java:470) ~[fabric-loader-0.15.7.jar:?]
at net.fabricmc.loader.impl.launch.knot.Knot.launch(Knot.java:74) ~[fabric-loader-0.15.7.jar:?]
at net.fabricmc.loader.impl.launch.knot.KnotClient.main(KnotClient.java:23) ~[fabric-loader-0.15.7.jar:?]
Caused by: java.lang.NullPointerException: Mod icon for porting_lib is null somehow (should be filled with default in this case)
at java.util.Objects.requireNonNull(Unknown Source) ~[?:?]
at com.terraformersmc.modmenu.util.mod.fabric.FabricDummyParentMod.getIcon(FabricDummyParentMod.java:63) ~[modmenu-7.2.2.jar:?]
at com.terraformersmc.modmenu.gui.widget.entries.ModListEntry.getIconTexture(ModListEntry.java:130) ~[modmenu-7.2.2.jar:?]
at com.terraformersmc.modmenu.gui.widget.entries.ModListEntry.render(ModListEntry.java:59) ~[modmenu-7.2.2.jar:?]
at com.terraformersmc.modmenu.gui.widget.entries.ParentEntry.render(ParentEntry.java:35) ~[modmenu-7.2.2.jar:?]
at com.terraformersmc.modmenu.gui.widget.ModListWidget.renderList(ModListWidget.java:241) ~[modmenu-7.2.2.jar:?]
at net.minecraft.client.gui.components.AbstractSelectionList.render(AbstractSelectionList.java:227) ~[client-intermediary.jar:?]
at com.terraformersmc.modmenu.gui.ModsScreen.render(ModsScreen.java:285) ~[modmenu-7.2.2.jar:?]
at net.minecraft.client.gui.screens.Screen.renderWithTooltip(Screen.java:110) ~[client-intermediary.jar:?]
at net.minecraft.client.renderer.GameRenderer.mixinextras$bridge$method_47413$299(GameRenderer.java) ~[client-intermediary.jar:?]
at net.minecraft.client.renderer.GameRenderer.wrapOperation$epl000$fancymenu$wrapRenderScreenFancyMenu(GameRenderer.java:8607) ~[client-intermediary.jar:?]
at net.minecraft.client.renderer.GameRenderer.mixinextras$bridge$wrapOperation$epl000$fancymenu$wrapRenderScreenFancyMenu$300(GameRenderer.java) ~[client-intermediary.jar:?]
at net.minecraft.client.renderer.GameRenderer.wrapOperation$gdc000$konkrete$wrapRenderScreenKonkrete(GameRenderer.java:12136) ~[client-intermediary.jar:?]
at net.minecraft.client.renderer.GameRenderer.render(GameRenderer.java:945) ~[client-intermediary.jar:?]
... 6 more

commented

To me it looks like the null check from

should also be used in
return Objects.requireNonNull(iconHandler.createIcon(iconSource, iconPath), "Mod icon for " + getId() + " is null somehow (should be filled with default in this case)");

commented

I also encountered this bug, and here is my crash log:

crash-2024-04-13_21.32.31-client.txt