Crash with Mekanism Flamethrower
mxnmnm opened this issue · 3 comments
Describe the bug
Crash after setting trees on fire using a flamethrower from mekanism. This ends up locking your world and preventing you from logging back in without crashing.
To Reproduce
I was burning down a forest of fir trees but it took a while to crash
Crashes
https://gist.github.com/mxnmnm/21143cf05f86d1e72a90f280e69d0bd2
Alright so apparently the real issue is the game doesn't like it when you burn some trees which include vanilla dynamic trees.
The best way to test and see if it will crash would be to try and flint and steel the side of a tree and if it doesn't burn then it will crash if you throw a flamethrower at it.
This is happening because Mekanism are throwing a null BlockPos at Block.isAir, which thick branches are then trying to use. I have a simple fix for this - just assume the thick branch is not air if the BlockPos is null.
Mekanism is trying to find out if our block is smeltable, and they won’t get a result back for that on thick branch anyway so this fix works fine to prevent the crash.