procedural generation
128 subscribers
5.33K photos
1.78K videos
7 files
11.3K links
Created by @r_channels
Download Telegram
Media is too big
VIEW IN TELEGRAM
After 4 years of developing procedural generators, I've finally released my game Vagabond in Early Access!

https://redd.it/139ik00
@proceduralgeneration
How to detect and fix isolated terrain (islands or lakes) in a tile-based terrain?

Hey, I'm making a game with procgen for the terrain. It's a boat game, so the player can traverse the water. In my generation, I sometimes get isolated "lakes", which I would like to avoid so that the player can reach all the water on the map. Here are a couple examples, with the lakes I'd like to avoid circled in red: https://imgur.com/a/GgZVsCV

I am using WFC to generate the terrain, with pretty much a copy-paste implementation of the original WFC implemented into Unity.

1. How do I detect these lakes in code?
2. How do I fix them?
3. Should I do this as part of the WFC propagation, or is it better to do it as a post-process step? My worry here is that doing it at WFC propagation might be very expensive and take a lot of time.

I thought of a couple of solutions, both being post-process solutions.

"Paint bucket tool": Essentially just take any random water, and use the same algorithms that paint (or others) use to fill images based on the tile. If there is still water that I didn't "fill", then I have a lake. This is only the detection step, but it seems fairly cheap.
A pathfinding: The unsailable terrain would just have very high costs, meaning it will only go over that terrain if it can't find another path. If unsailable terrain is then on this path, I would just replace it with water to create a pathway. Perhaps this could even be combined with the above, and use the above as a cheaper broadphase and A as the narrowphase (which I would of course need to benchmark to see if I even have to).

Are there any other solutions to this? Maybe something I can do as part of the WFC propagation. I'm not very familiar with the algorithm, so any input is appreciated.

Bonus points if you can also help me make my map non-square, but still have a outer border.

https://redd.it/13al3eg
@proceduralgeneration
Flaming Sword in Houdini 19.5 | Houdini Fire Tutorial | Houdini Tutorial
https://youtu.be/405sFU7kqE4

https://redd.it/13apluy
@proceduralgeneration
Media is too big
VIEW IN TELEGRAM
Perlin noise + handcrafted rooms for my open-world Forest Fire game

https://redd.it/13bpej1
@proceduralgeneration
Media is too big
VIEW IN TELEGRAM
My music generation program made this kinda 60's style song! "A Fool For Her"

https://redd.it/13bzsf9
@proceduralgeneration
Media is too big
VIEW IN TELEGRAM
My music generation program made this 60's style song! "A Fool For Her" What do you think?

https://redd.it/13c50yz
@proceduralgeneration