Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Mining Crash workaround #2354

Merged
merged 1 commit into from
Aug 16, 2024
Merged

Fix: Mining Crash workaround #2354

merged 1 commit into from
Aug 16, 2024

Conversation

hannibal002
Copy link
Owner

@hannibal002 hannibal002 commented Aug 15, 2024

What

Added a try catch block around MiningCommissionsBlocksColor so that we no longer crash but rather only show an error.

Stack Trace
java.lang.ClassCastException: java.util.LinkedHashMap$Entry cannot be cast to java.util.HashMap$TreeNode
at java.util.HashMap$TreeNode.moveRootToFront(HashMap.java:1859)
at java.util.HashMap$TreeNode.treeify(HashMap.java:1975)
at java.util.HashMap.treeifyBin(HashMap.java:773)
at java.util.HashMap.putVal(HashMap.java:645)
at java.util.HashMap.put(HashMap.java:613)
at at.hannibal2.skyhanni.mixins.hooks.BlockRendererDispatcherHookKt.modifyGetModelFromBlockState(BlockRendererDispatcherHook.kt:46)
at net.minecraft.client.renderer.BlockRendererDispatcher.handler$bpp001$modifyGetModelFromBlockState(BlockRendererDispatcher.java:1520)
at net.minecraft.client.renderer.BlockRendererDispatcher.getModelFromBlockState(BlockRendererDispatcher.java:155)
at net.minecraft.client.renderer.BlockRendererDispatcher.renderBlock(BlockRendererDispatcher.java:93)
at net.minecraft.client.renderer.chunk.RenderChunk.rebuildChunk(RenderChunk.java:316)
at net.minecraft.client.renderer.chunk.ChunkRenderWorker.processTask(SourceFile:78)
at net.minecraft.client.renderer.chunk.ChunkRenderWorker.run(SourceFile:38)
at java.lang.Thread.run(Thread.java:750)

Changelog Fixes

  • Fixed a rare crash occurring on a mining island. - hannibal2

@hannibal002 hannibal002 added the Bug Fix Bug fixes label Aug 15, 2024
@hannibal002 hannibal002 added this to the Version 0.26 milestone Aug 15, 2024
@hannibal002 hannibal002 merged commit d524fe1 into beta Aug 16, 2024
11 checks passed
@hannibal002 hannibal002 deleted the workaround-for-mining-crash branch August 16, 2024 09:17
@github-actions github-actions bot removed the Bug Fix Bug fixes label Aug 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant