A Cute Little Crock Pot

A Cute Little Crock Pot

204k Downloads

placing block on heat source crashes client

nephatrine opened this issue ยท 4 comments

commented

Using crockpot-0.7.1+1.18.1.jar, when I put the crockpot onto a campfire or stove, I immediately get a client crash. I can put it onto the ground successfully (and like the new look/color fyi). This happens both in singleplayer and on a server. I am using sodium+iris so it could be a compat issue or something like that.

This did not occur using crockpot-0.6.5+1.18.1.jar so I think it must be specifically related to the new appearance.

[12:20:36] [Render thread/FATAL]: Unreported exception thrown!
java.util.concurrent.CompletionException: java.lang.ClassCastException: class net.minecraft.class_3924 cannot be cast to class com.github.nosrick.crockpot.blockentity.CrockPotBlockEntity (net.minecraft.class_3924 and com.github.nosrick.crockpot.blockentity.CrockPotBlockEntity are in unnamed module of loader net.fabricmc.loader.impl.launch.knot.KnotClassLoader @6d00a15d)
	at Not Enough Crashes deobfuscated stack trace.(1.18.1+build.22) ~[?:?]
	at java.util.concurrent.CompletableFuture.reportJoin(CompletableFuture.java:413) ~[?:?]
	at java.util.concurrent.CompletableFuture.join(CompletableFuture.java:2118) ~[?:?]
	at me.jellysquid.mods.sodium.common.util.collections.WorkStealingFutureDrain.findNext(WorkStealingFutureDrain.java:47) ~[sodium.jar:?]
	at me.jellysquid.mods.sodium.common.util.collections.WorkStealingFutureDrain.hasNext(WorkStealingFutureDrain.java:28) ~[sodium.jar:?]
	at me.jellysquid.mods.sodium.client.render.chunk.region.RenderRegionManager.setupUploadBatches(RenderRegionManager.java:123) ~[sodium.jar:?]
	at me.jellysquid.mods.sodium.client.render.chunk.region.RenderRegionManager.upload(RenderRegionManager.java:59) ~[sodium.jar:?]
	at me.jellysquid.mods.sodium.client.render.chunk.RenderSectionManager.updateChunks(RenderSectionManager.java:322) ~[sodium.jar:?]
	at me.jellysquid.mods.sodium.client.render.SodiumWorldRenderer.updateChunks(SodiumWorldRenderer.java:196) ~[sodium.jar:?]
	at net.minecraft.client.render.WorldRenderer.setupTerrain(WorldRenderer:16479) ~[?:?]
	at net.minecraft.client.render.WorldRenderer.render(WorldRenderer:1253) ~[?:?]
	at net.minecraft.client.render.GameRenderer.renderWorld(GameRenderer:1031) ~[?:?]
	at net.minecraft.client.render.GameRenderer.render(GameRenderer:811) ~[?:?]
	at net.minecraft.client.MinecraftClient.render(MinecraftClient:1117) ~[?:?]
	at net.minecraft.client.MinecraftClient.run(MinecraftClient:733) ~[?:?]
	at net.minecraft.client.main.Main.main(Main:238) [client-intermediary.jar:?]
	at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
	at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) ~[?:?]
	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
	at net.fabricmc.loader.impl.game.minecraft.MinecraftGameProvider.launch(MinecraftGameProvider.java:416) [fabric-loader-0.13.3.jar:?]
	at net.fabricmc.loader.impl.launch.knot.Knot.launch(Knot.java:77) [fabric-loader-0.13.3.jar:?]
	at net.fabricmc.loader.launch.knot.KnotClient.main(KnotClient.java:28) [fabric-loader-0.13.3.jar:?]
Caused by: java.lang.ClassCastException: class net.minecraft.class_3924 cannot be cast to class com.github.nosrick.crockpot.blockentity.CrockPotBlockEntity (net.minecraft.class_3924 and com.github.nosrick.crockpot.blockentity.CrockPotBlockEntity are in unnamed module of loader net.fabricmc.loader.impl.launch.knot.KnotClassLoader @6d00a15d)
	at com.github.nosrick.crockpot.client.colours.CrockPotBlockColourProvider.getColor(CrockPotBlockColourProvider.java:26) ~[crockpot.jar:?]
	at me.jellysquid.mods.sodium.client.model.quad.blender.LinearColorBlender.getBlockColor(LinearColorBlender.java:28) ~[sodium.jar:?]
	at me.jellysquid.mods.sodium.client.model.quad.blender.LinearColorBlender.getVertexColor(LinearColorBlender.java:55) ~[sodium.jar:?]
	at me.jellysquid.mods.sodium.client.model.quad.blender.LinearColorBlender.getColors(LinearColorBlender.java:20) ~[sodium.jar:?]
	at me.jellysquid.mods.sodium.client.render.pipeline.BlockRenderer.renderQuad(BlockRenderer.java:127) ~[sodium.jar:?]
	at me.jellysquid.mods.sodium.client.render.pipeline.BlockRenderer.renderQuadList(BlockRenderer.java:113) ~[sodium.jar:?]
	at me.jellysquid.mods.sodium.client.render.pipeline.BlockRenderer.renderModel(BlockRenderer.java:84) ~[sodium.jar:?]
	at me.jellysquid.mods.sodium.client.render.chunk.tasks.ChunkRenderRebuildTask.redirect$dmf000$onRenderBlock(ChunkRenderRebuildTask.java:555) ~[sodium.jar:?]
	at me.jellysquid.mods.sodium.client.render.chunk.tasks.ChunkRenderRebuildTask.performBuild(ChunkRenderRebuildTask.java:99) ~[sodium.jar:?]
	at me.jellysquid.mods.sodium.client.render.chunk.compile.ChunkBuilder.processJob(ChunkBuilder.java:254) ~[sodium.jar:?]
	at me.jellysquid.mods.sodium.client.render.chunk.compile.ChunkBuilder$WorkerRunnable.run(ChunkBuilder.java:294) ~[sodium.jar:?]
	at java.lang.Thread.run(Thread.java:833) ~[?:?]
commented

Oh no, sorry about this.

I'm gonna look into it, see what's causing it. I might have just missed stuff while testing.

Thank you for the report!

EDIT: Pretty sure it's because I did an unsafe cast (hence the ClassCastException) when I was testing something. I'll hopefully push a fix in a moment.

EDIT 2: Think I've fixed it. Tested with Sodium + Iris (no shaders), can't reproduce, now.

commented

Alright, that should hopefully fix it.

Download the .jar from here:
https://github.com/Nosrick/crock-pot-mod/releases/tag/test-build

If it fixes it, drop me a comment and close this issue. If not, I'll see what I can do.

EDIT: I also really appreciate the kind words regarding the new look of the pot!
It took a lot of fiddling to get it (mostly) right, so I'm glad you like it.

commented

Wow that was quick. Build works flawlessly. Thanks!

commented

Awesome, I'm glad!
You actually caught me having just finished for the day, so it was easy to drop a quick build on something that was literally a single line that I'd messed up. ;)