java.lang.ClassCastException: class net.minecraft.core.Holder$Reference cannot be cast to class org.spongepowered.api.world.biome.Biome (net.minecraft.core.Holder$Reference and org.spongepowered.api.world.biome.Biome are in unnamed module of loader cpw.mods.modlauncher.TransformingClassLoader @36061cf3)
Log:
at net.minecraft.world.level.chunk.LevelChunk.biome(LevelChunk.java:1318) ~[?:?]
at org.example.Example.getBiome(Example.java:120) ~[?:?]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) ~[?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:264) ~[?:?]
at org.spongepowered.api.scheduler.Task$Builder.lambda$execute$0(Task.java:85) ~[?:?]
at org.spongepowered.common.scheduler.SpongeScheduler.lambda$startTask$1(SpongeScheduler.java:274) ~[sponge.jar:1.19.4-10.0.0-RC1469]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) ~[?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:264) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]
at java.lang.Thread.run(Thread.java:840) ~[?:?]
Code:
WorldChunk chunk;
Vector3i blockMin = chunk.min();
var biome = chunk.biome(blockMin.add(0, 80, 0)); //<-- this line fails
Affected Product(s)
SpongeVanilla
Version
1.19.4-10.0.0-RC1469
Operating System
Linux
Java Version
17
Plugins/Mods
Describe the bug
Log:
Code:
Link to logs
No response