Quote from: bigsofty on 2022-Aug-03for me most understandable and competent sources were those:
Where did you get all those various maze generating algorithms?
https://weblog.jamisbuck.org/2011/2/7/maze-generation-algorithm-recap.html
https://professor-l.github.io/mazes/
https://www.astrolog.org/labyrnth/algrithm.htm
I didn't implement all of algorithms found on those websites as not all were optimal/interesting and could be used as base for something more in game based environment.
@erico
Generally I also do something different from classic algorithms, or rather don't care which things from particular method are useful in current situation, as level generation is kind a different thing and needs more complex solutions. Some example can be multi-stage generation with way-points navigation using A-star pathfinding and so on.
Bridges/tunnels can be done in several ways, depending on what is required in game, either pre-calculate their positions and use some modified algorithm or place them in main loop using some markers (tiles counter from last bridge and similar) as I made in last algorithm in attached code (Growing Tree) - yet this implementation isn't best, bridges aren't evenly distributed on whole map.