Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds some geography. This one is a kind of big deal. #69912

Merged
merged 6 commits into from
Dec 3, 2023

Conversation

I-am-Erk
Copy link
Member

@I-am-Erk I-am-Erk commented Dec 2, 2023

Summary

Features "The map changes as you travel east-west and north-south, revealing either rural areas or oceans and megacities"

Purpose of change

Our current mapgen creates a sort of weird suburban zone. It's fine but it's bland. There's very little reason to explore outside one overmap. There are no real cities. No ocean. No mountains. No vast forests.

Describe the solution

Adds these things.

  1. As you travel West, the cities don't get smaller but they start to space out more.
  2. As you travel East, the cities get bigger and more crowded until you're basically in a constant megacity.
  3. As you travel West and North, the forests get denser and thicker until you're soon in a rural forest interspersed by roads and campgrounds
  4. In the eastern megacity as you travel north, the cities remain big but get less dense again.

Describe alternatives you've considered

The massachussets mod would be another way to do this but I've wanted to boost the mapgen abilities for a while, and it turned out to be easier than I thought.

I wanted to add oceans in this PR (see screenshot below) but they were causing things to hang on generation and I don't want to introduce too many points of failure in one go.

Testing

here's a large image showing just the change to cities:
image

This shows forest density increasing as you head West from the starting map
image

This is a city at overmap 10,10, which is getting into the outskirts of boston.
image

When you get into the really rural areas approaching what would be vermont, you get... rural areas.
image

But zooming in, those areas still have roads and points of interest:
image-1

This is just a cool shot around the 5,-2 area:
image
I can't get over how much cooler this is because here's a shot from in the same worldgen, a bit more to the west and north:
image

Additional context

this one shows the later ocean change. It's super cool but I have moved it to a later PR so I can push the stuff that's working right... the ocean stuff causes worldgen to hang and crash, and the fix is not super simple.
image

@I-am-Erk I-am-Erk added the Map / Mapgen Overmap, Mapgen, Map extras, Map display label Dec 2, 2023
@github-actions github-actions bot added [C++] Changes (can be) made in C++. Previously named `Code` <Enhancement / Feature> New features, or enhancements on existing json-styled JSON lint passed, label assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions labels Dec 2, 2023
@Qrox
Copy link
Contributor

Qrox commented Dec 2, 2023

Do you plan to jsonify this? I think the math parser for EOC could be used for it.

@Terrorforge
Copy link
Contributor

Terrorforge commented Dec 2, 2023

Will this bias scenarios like Missed towards dumping you in the eastern megacities? Or is that not how starting locations work

Conversely, would it be possible to do that on purpose? It would be fun to have scenarios where you start right on the coast in the biggest megacities or far to the west in the most rural areas.

@KeremBabaG
Copy link
Contributor

It looks great, will this be a worldgen option or just default from the moment it is implemented? Might be worth adding it as an option, between realistic like this or completely random like before

@I-am-Erk
Copy link
Member Author

I-am-Erk commented Dec 2, 2023

Qrox: I do definitely plan to expose it to JSON, but not this PR. For now I just want it working and getting bug tested.

Terrorforge: I don't think scenarios will usually search far enough afield to find the big cities at this point, but I would like some infrastructure and logic related to them so that we can have scenarios where you start in the city or on an island in the ocean at some point. There's nothing preventing it

Karem: not making it an option, no. When it's parameterized out into JSON people could recreate the old boring way

@github-actions github-actions bot added the astyled astyled PR, label is assigned by github actions label Dec 2, 2023
@I-am-Erk I-am-Erk marked this pull request as ready for review December 2, 2023 18:53
src/overmap.cpp Show resolved Hide resolved
src/overmap.cpp Outdated Show resolved Hide resolved
src/overmap.cpp Outdated Show resolved Hide resolved
src/overmap.cpp Outdated Show resolved Hide resolved
src/overmap.cpp Outdated Show resolved Hide resolved
src/overmap.cpp Outdated Show resolved Hide resolved
@github-actions github-actions bot removed astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions labels Dec 2, 2023
@github-actions github-actions bot added BasicBuildPassed This PR builds correctly, label assigned by github actions astyled astyled PR, label is assigned by github actions and removed BasicBuildPassed This PR builds correctly, label assigned by github actions labels Dec 2, 2023
@fairyarmadillo
Copy link
Contributor

Aren't the southeastern parts of New England swampier? Could do something with that.

Looking great btw!

@OtherBiscuit
Copy link

Oh yeah, this is good. Personally, I'd relegate it to a mod for those without processing capability for this, but it's really cool!

@I-am-Erk
Copy link
Member Author

I-am-Erk commented Dec 2, 2023

It doesn't really add any processing. The cities are no more intensive than any other city.

@github-actions github-actions bot added the BasicBuildPassed This PR builds correctly, label assigned by github actions label Dec 3, 2023
@Maleclypse Maleclypse merged commit 6056bc4 into CleverRaven:master Dec 3, 2023
25 checks passed
@I-am-Erk I-am-Erk deleted the overmap-shenanigans branch December 3, 2023 06:07
@kevingranade
Copy link
Member

This pull request has been mentioned on Cataclysm: Dark Days Ahead. There might be relevant details there:

https://discourse.cataclysmdda.org/t/i-did-some-mapgen-changes-you-might-find-cool/29087/1

@DeftGrain
Copy link

DeftGrain commented Dec 3, 2023

This looks fantastic Erk. Is the new mapgen going account for temperature/rainfall variances due to lake/ocean effect the farther you move inland/toward the ocean?

@I-am-Erk
Copy link
Member Author

I-am-Erk commented Dec 3, 2023

It doesn't presently come close to any capacity for that. It's possible to do that and not really difficult but it's entirely separate.

Basically this change causes gradual shifts but doesnt make any strict assertions saying "it's city time now" or anything. We could mix this up with some actual biome changes covered in regional settings, and that might actually be a really interesting way to do some stuff.

@DeftGrain
Copy link

Absolutely, just looking at the generation itself this has a lot of potential and opens up a lot of possibilities. The map generation itself reminds me a bit of UnReal World mapgen in a very good way. You have the general expectation of something in a particular direction, but it's still procedurally done. I feel like this will open up the opportunity to start work on a framework for more realistic storms and temperature drops during winter, adding another layer to the game, especially with the dicussed addition of tile slickness values for winter. An excellent addition Erk.

@Inglonias
Copy link
Contributor

A little late, but I think this is super neat. Fantastic work.

@ashGlaw
Copy link
Contributor

ashGlaw commented Dec 6, 2023

Erk, thank you. This is wonderful! I've wanted this for a long time now. Bless

@Irets
Copy link
Contributor

Irets commented Dec 6, 2023

This looks very cool - can't wait for my compiler to put together a fresh copy of the game.
You didn't mention anything about what's expected at south. How do these changes apply to travelling south?

@Inglonias
Copy link
Contributor

It occurs to me that while this is super cool, we should probably find a way to tell people about this. If people go from 0.G to 0.H and mapgen is sufficiently different in long-running games, people might get confused.

@I-am-Erk
Copy link
Member Author

I-am-Erk commented Dec 7, 2023

It occurs to me that while this is super cool, we should probably find a way to tell people about this. If people go from 0.G to 0.H and mapgen is sufficiently different in long-running games, people might get confused.

It shouldn't have that big an effect that it needs to be anywhere besides the changelog. THe worst thing someone might see is a sharp, ugly line at the edge of the changed mapgen where the gradient jumps suddenly. Nothing ought to break.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions [C++] Changes (can be) made in C++. Previously named `Code` <Enhancement / Feature> New features, or enhancements on existing json-styled JSON lint passed, label assigned by github actions Map / Mapgen Overmap, Mapgen, Map extras, Map display
Projects
None yet
Development

Successfully merging this pull request may close these issues.