BenjaTK / Gaea

Procedural generation add-on for Godot 4.

Home Page:https://benjatk.github.io/Gaea/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Chunk system?

bitbrain opened this issue · comments

commented

I am wondering how much out of scope would be a chunk system - generating an infinite world with this addon (depending on the generator used).

Saving/loading chunks to disk may be out of scope but I could totally see a system where depending on the player position, a level gets re-generated dynamically.

That's something I'd like to see! I don't think it would be necessary/make sense with generators like the walker or cellular one (it wouldn't really work), but with noise and heightmap we could add InfiniteNoiseGenerator and InfiniteHeightmapGenerator, and have them be separated from the static ones.
Then the user sets a node as the chunk generation origin, some parameters like chunkSize and chunkGenerationDistance

We also talked about it here #7 as a way of optimizing large world sizes.

commented

I'd like to work on something like this. I am not really sure though what would work best. For the sake of compatibility I would use a single TileMap instead of one TileMap node per chunk. The generator could get a separate generate function for a specific chunk and another script could handle the loading management.

Closed by #29