Jump to content

Caves Generation is unreliable?


Hornete
  • Known Issue

I've been doing some modding work related in the caves and during that I noticed something very peculiar in the caves log. I notice many "PANIC" prints during the generation of the caves due to majorly either the "sacred_chest" prefab(chest used for the Metheus puzzles and ancient furniture blueprints) being missing or too many disconnected tiles being removed. When this happens the game then regenerates a whole new world, and often times it may fail again. I tested without any server mods, and sure enough this still occurs.

What this can end up doing in practice is the generation times for the Caves increases by a large amount due to these errors. I have seen up to twelve panic prints in a row and thus this means the game tried to generate 12 worlds but it failed all those times before finally coming upon a world that had the "sacred_chest" prefab and did not disconnect too many tiles. With the first panic print happening at twelve seconds of run time in this specific cave instance:image.png.491efe8633b9ec0f615ba87e2f3c6e83.png
and the final twelfth panic print happening 49 seconds at run time.
image.png.43db95c385b9a364902414f0afb3995e.png

While this isn't the worst thing in the world, since it only amounts to extra generation time. I still thought it was something odd that might need a look at. The issues seem to be the ancient psuedoscience station set piece with the two bishops doesn't spawn most of the time as that includes the sacred_chest prefab, and the many disconnected tiles

image.png.b6d91f3374f79b311f837ce6e1888cfa.png
The game has a limit of 1000 tiles that it removes before deciding it wants to regenerate the world all over(for what I assume are good reasons), as can be seen in map/forest_map lines 795-805. If you set keep_disconnected_tiles to true for the generation params you'll notice there's a lot of out of reach tiles that appear in the Ancient Guardian's labyrinth, I assume that is where all these disconnected tiles come from.


Steps to Reproduce

1. Generate a few cave worlds
2. Look at the server logs
3. Be in awe as you see all the "PANIC" prints.

  • Like 4



User Feedback


In solo don't starve when it reaches 5, it crashes, Which I've had happen to me. Luckily that doesn't happen in DST.

Share this comment


Link to comment
Share on other sites



Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
  • Create New...