NuclearCraft

NuclearCraft

31M Downloads

[1.7.10] "java.lang.NullPointerException" in NEI

FenrlX opened this issue ยท 1 comments

commented

Hey hey,
I know everything pre overhaul has stopped development and all but I really would appriciate if you could take a quick look at the error I'm getting.
In the last days I spent a lot of time building my retro-modpack with a lot of 1.7.10 mods incl. old nuclearcraft.
Modlist: https://pastebin.com/rMpV166u

The GTNH-Fork of NEI seems to be running into an error when it loads something from the nuclear craft (non electric) crusher:

"[CHAT] There was an error during loading the recipe. Please check log for details."

"at nc.crafting.nei.CrusherFuelRecipeHandler.loadUsageRecipes(CrusherFuelRecipeHandler.java:65)"

https://pastebin.com/L3ssjtGN

A user named @OvermindDL1 on the Legacy Modding discord said:

https://github.com/tomdodd4598/NuclearCraft/blob/1.7.10/src/main/java/nc/crafting/nei/CrusherFuelRecipeHandler.java#L63
"I'm guessing there's a null fuel stack in there

A hack-fix is to null test before using them, a proper fix is to figure out 'why' a null one is being entered to begin with, it's in an invalid state, and the author didn't assert their invariants apparently

Considering there's a branch in there they might be willing to fix it, would be a simple fix for the hack-fix anyway

If they need help with the old 1.7.10 ecosystem feel free to have them ping me on github (@OvermindDL1) or just have them join this discord. :-)"

I'm not knowledgeable at all in modding and my java lessons are about 10 years old. If it's a simple fix, it would be really nice to have that sorted out.

Thanks.

commented

Specifically crashing on the line if (crusherfuel.stack.contains(ingredient)).

(Well, not strictly crashing, NEI is catching and reporting it and continuing, but it does mean the NEI handler for it doesn't work and thus nothing inside it works in NEI.)