Proper river shores under bridges #3212
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
SUMMARY: Bugfixes "Proper river shores under bridges"
Purpose of change
Bridges used to override river shores if they started or traverse next to them. No more.
Describe the solution
Added predecessor_mapgen to bridges with new builtin mapgen, which looks around and generates suitable map.
Also there was a bug in mapgen of shore corners, which prevented them from spawning any dirt. Those weird corners always stumbled me. Fixed now.
Describe alternatives you've considered
A lot actually. Adding bunch of new terrains for different bridge\shore variations. Or forbidding bridges from spawning where it'll mess with shore. Or altering river shape. But then i remembered about predecessor_mapgen, which can do the job perfectly.
Testing
Generated bunch of bridges.
Additional context
In theory this mapgen can replace all other river terrains, but that's pretty ambitious task.