VazkiiMods / Psi

Spellcrafting mod for Minecraft based around Vector math and stack-based processing
http://psi.vazkii.net
314 stars 89 forks source link

Crash executing spell #302

Closed mwchase closed 5 years ago

mwchase commented 7 years ago

Encountered against Psi-r1.1-45, AutoRegLib-1.1-4, forge-1.11.2-13.20.0.2226 (with mercurius, apparently), recent Java 8.

I attempted to use the following loopcast spell (gotten from another bug) to create a wall. The spell compiles successfully, and, with a stack of e.g. cobble in the hotbar after the CAD, works until it doesn't. http://pastebin.com/GKXS9fYN Specifically, the CAD places blocks until four remain, at which point the game freezes.

Crash log: http://pastebin.com/4M00hHrC FML log: http://pastebin.com/PeQWDyGt

mwchase commented 7 years ago

Still encountered against Psi-r1.1-46, all others the same.

Crash log: http://pastebin.com/UY1wwJ0r FML log: http://pastebin.com/cPmvdeAR

williewillus commented 7 years ago

two missing null -> ItemStack.EMPTY here. the setter and the return value

williewillus commented 7 years ago

theoretically, you shouldn't even have to do the if (getCount == 0) set(I, EMPTY), because 0 sized stacks are automatically empty by definition.