maruohon / litematica

A modern client-side schematic mod for Minecraft
GNU Lesser General Public License v3.0
686 stars 190 forks source link

Minecraft crashes when joining a world #846

Open Nearbysoda opened 1 month ago

Nearbysoda commented 1 month ago

I'm playing on 1.16.5. I'm trying to add litematica forge to one piece craft modpack, I currently have litematica-forge-1.16.5-0.0.0-dev.20210917.jar and malilib-forge-1.16.5-0.10.0-dev.21+beta.1.jar my issue is when I join a world it works for 3 seconds minecraft saves the world and then it crashes. The mods that are included in one piece craft modpack are architectury API (Fabric/forge/neoforge), Better advancements, Cherished worlds (Fabric/forge/Neoforge/quilt), Cloth config API (Fabric/forge.Neoforge), Clumps, Collective, Cosmetic armor reworked, Curious API (Forge/Neoforge), Fast leaf decay, fastfurnace, Fastsuite, FastWorkBench, Ferritecore ((Neo)forge), FTB chunks (Forge), FTB library (Forge), FTB Team island (Forge), FTB Teams (Forge), Furnace recycle, Guard villagers, Islands, JourneyMap, Just enough items, Just enough resources, Kotlin for forge, Kotlin libraries, Lazy DataFixerUpper, Mine Mine no Mi, Mine mine no mi - Haki bar, Neko's enchanted books, Not enough recipe books, Placebo, Relics, small ships, Snowball freeze mobs, tool stats, Valkyrien skies, Vanilla cookbook, and XP tome.

Here is the crash report crash-2024-05-30_13.45.30-client.txt

Please tell me if there's any other info I can give

maruohon commented 1 month ago

Looks like it's probably because of Valkyrien Skies. It tries to cast the Litematica Schematic World to a vanilla client world without checking it's type first.

Nearbysoda commented 1 month ago

Wow that was fast. Thank you so much for the help, I'm able to play the game now without it crashing. I just have one question, is there a way I can play with Valkyrien skies or are the two just not compatible?

maruohon commented 1 month ago

With the current mod version it will probably always just crash. Unless it only crashes with schematics that have some block entities?

The fix on Valkyrien Skies' side would probably be simple, one added instanceof check and otherwise just don't do anything with that world. I don't know what Valkyrien Skies is or does and if this would cause some visual weirdness, but I'd imagine it probably shouldn't be trying to do anything with Litematica's world and rendering anyway(?)

The "fix" on Litematica's side would be to extend the vanilla client world, but that adds some extra code and complexity, plus it kinda opens the door for some other mods to do more stuff in Litematica's schematic world, which would probably just mess stuff up. So I don't want to change how this works on my side.