TerraFirmaCraft

TerraFirmaCraft

2M Downloads

Unexpected Crash on Death While Barrel is Loaded.

Quatroctus opened this issue ยท 3 comments

commented

latest.log
Describe the bug
Make sure to include:

  1. What did you expect to happen?
    I expected the respawn screen to come up instead of Minecraft crashing.
  2. What actually happened instead (i.e. what was the bug)
    The game crashed
  3. If it was a crash, upload the full log file (latest.log)
    Done.

To Reproduce
The crash occurred on a server, it is unknown if it also happens on singleplayer.

  1. Place down a barrel. Unknown if fluid inside affects the block. It's unlikely. But the barrels around had Tannin, Water, and Limewater.
  2. Then die while those barrels are loaded and rendering.

Meta Info

  • TFC Version: 0.30.3.124
  • Inventory Tweaks: 1.63+release.109.220f
  • Journey Map: 1.12.2-5.7.0
  • JEI - 4.15.0.293
  • Waila: 1.8.26
  • Forge: 14.23.5.2847

Seems like the easiest fix would be to check at the top of TESRBarrel::render if the block at the TileEntities BlockPos is the Barrel Block.

crash-2020-03-30_21.05.52-client.txt
latest.log
debug.log

commented

Logs have no mention of barrels, only chests.
You left out the fact you are using Optfine.

The only difference between the vanilla code and the TFC code is that the block pulled isn't stored as Block but as BlockChest with some casting to shorten the if below it. The fact it's taken this long to surface points to something else likely causing the issue as the code hasn't been touched in ~8 months and that was to fix another optifine issue.

If you can reproduce it without optifine, then it would be worthwhile to look into.

commented

I had forgotten about optifine being installed as it doesn't appear in the Mods list.

However weirdly enough I can't seem to reproduce the crash even with Optinfine installed at this time.

That is true. Those were from the second crash I assumed the first and the second were identical. Here are the first ones.
debug-4.log
crash-2020-03-30_20.24.54-client.txt

commented

The only difference between the vanilla code and the TFC code is that the block pulled isn't stored as Block but as BlockChest with some casting to shorten the if below it.

This is also not true. The vanilla code has an instanceof check before it casts the Block to BlockChest. Which is what is causing the error. However I will not rule out the crash being caused by Optifine.