Tuesday, December 13, 2022

Craters

I've made some more refinements to my non-terran worlds. One is that multiple world terrains can now  be blended into a single world map, making for more variety within worlds. Another is the incorporation of variations on the warped fractals I've been using so far. Warped voronoi maps can (rarely) appear, and so too can the extreme kind of warped terrain that ThingOnItsOwn rather charmingly calls Monstrous Terrain. This can produce interestingly weird terrain like these:


But these worlds still look a bit dull at the regional level, because they have no proper hills or mountains. They only have the up-and-down of the basic underlying terrain, and no matter how dramatic that may be at the global scale it generally comes out looking very gentle and gradual at the regional scale. So we want some features for these worlds that will look interesting at all scales.

An obvious kind of feature for alien worlds is craters. But how to do them?

Here is my thinking. A crater is basically a big circle. Suppose we put a lot of circles at random onto the map. Each one is a flat depression. However, craters also feature a raised rim, and usually a peak in the centre. We can represent these in a similar way to mountains - an extra array, which we use to draw them directly onto the regional map. At the global level, we use that array to display the rims as raised, although the actual heightmap is not that high. As with normal mountains, rivers and the depression-filling algorithm will ignore the central peaks and the rims, as they're not part of the normal base terrain.

That gives us this:

Well, it's a start. But of course craters aren't really perfectly flat. The terrain should slope downwards from the rim towards the centre. Adding this in gives us this:

These are looking better, but they're mostly too big, and too evenly distributed. So I introduce a global fractal to determine their distribution, and also create additional rules: on some worlds they appear only above a certain elevation, on some only below a certain elevation, and on some only where the land slopes steeply. Also I make it so that craters don't raise land that's below them. This gives us maps like this:


I think this is starting to look pretty good! As you can see, some craters are low enough to create small circular seas. These look quite good, but I don't think we always want them, so I add an extra pass of the small-sea-removing function after doing the craters for most worlds.

One problem, though, is that most craters are depressions. If there isn't water in them, then that will mess up rivers. We can solve that by running our depression-removing algorithm again, but that will fill up most of our nice new craters. My solution is to create yet another global fractal and then use that to blend the new, cratered terrain with the original, uncratered terrain. This makes the craters imperfect, with lower areas in their rims, so the depressions can be filled without the craters being filled right up. If there's no sea in the world, then we don't bother with any of this, as there won't be rivers.

There's one other adjustment to make. In reality, any craters on the surface of a planet with life will have mostly eroded away, because a planet with life must (a) have a reasonably thick atmosphere and (b) not have been subject to frequent bombardment from space for a long time. In drier regions, craters may still be seen, like the famously misnamed Meteor Crater, but in wetter ones they will get eroded away. This is unlike mountains formed by tectonic action, because while those also get eroded away, they're constantly being raised up at the same time, which balances the effect.

So in the climate simulation, I give rainfall the ability to lower the "mountains" around the rims of craters.

That gives us craters on the global map. How do we deal with them on the regional map? The basic idea is to add in the central peak and the rim of each crater much as mountains are done. So we paste peaks in the centre of each crater and in a circle around the rim. As with normal mountains, we leave gaps where any rivers might be passing through. 

This gives us an effect like this:


I think this looks pretty decent. As you can see here, craters are drawn overlapping each other, with the rims of "earlier" craters being overwritten by the floors of "later" ones. The crater in the centre is partial to begin with because the elevation drops to the northwest, so the land there is lower than the floor of the crater would be.

An extra detail to make things a little more interesting is to have "arms" of peaks radiating out from the craters, like these:





And I think that's that for craters. Hopefully these should make the alien planets a little more interesting, and of course we can add a few of them to some of our Earth-like planets too, just to shake things up a bit.

No comments:

Post a Comment