Jump to content

Is a circular asteroid shape possible?


Recommended Posts

I like the idea and wanted to do some modding to create a smaller circular asteroid with just a few biomes surrounded by space. The problem is I can't seem to find the worldgen parameters to make this work. Does anyone know if it's even possible or am I wasting my time?

Link to comment
Share on other sites

yes it is possible.
with YAML, this is about the closest you can get:
image.thumb.png.81d89bcc6ffa61f0013e929947b8f907.png

The code for this world is here: https://pastebin.com/1Fj2NEu2
I simply made this by taking any of the existing asteroids (arboria in this case), and then:

  1. Changed the map size to be a square
  2. Defined the Default biome to be Space
  3. Removed any AtSurface or AtDepths biomes, only AtDistance-s and the Default were allowed to stay. so no horizontally stretching biomes can appear.
  4. Made sure my MaxDistance is at tops 4 (maybe 5 would work too)

You might want to disable traits for a world like this, like Terra, because Subsurface Ocean or Frozen Core will ruin the look.


If you want a perfect circle, that is still possible, but it will require quite a bit C# and overwriting the game-s worldgen. That isn't something I can throw a demo together in a minute, but look at MiniBase mod by Versepelles, their source code is public and they do custom world generation.

Link to comment
Share on other sites

16 hours ago, Akiart said:

yes it is possible.

I used your asteroid as an example and changed Oasisse to match the parameters set, every time the game crashes in the middle of world generation right at "Infusing Oxygen". I made a pastebin with the code I have currently on the asteroid's file. Maybe you can see what I'm doing wrong because I've tried changing several things and nothing seems to fix it. https://pastebin.com/g6sQ6ci2 image.thumb.png.d6404cd364faa46852527d80d209e5c5.png

edit: I copied your .yaml into forest_lush and got this

is it the seed that world uses that somehow made it look so even? This is definitely closer to what I'm wanting. I don't want the asteroid to be fully circular. The example you posted would be almost perfect except I'll need to use miscalculated pod location, have the center be magma (gonna work on that after I finish setting the oasis .yaml up just enough that it'll generate the right shape), have the outermost biome be tide pool, forest, and POSSIBLY frozen, etc. 

Link to comment
Share on other sites

Your yaml is crashing because your worldsize isn't a multiple of 16.

For the messy worldgen: It cannot be the seed, my yaml doesnt allow to spawn any biomes farther than 4 worldcells so at the set size they cannot be that close to the edge.

That looks like Irregular Oil trait, which spawns random oil on the world.
You can disable world traits by putting this on top of your YAML:

disableWorldTraitstrue

Also make sure your world size is big enough, if you have too big distance set in a too tiny world, it will also overflow on the sides, causing something similar to happen horizontally, or possibly crashing vertically:

worldsize:
  X384
  Y384

This size is enough to hold biomes that go out to a distance of 4.
If you want a tinier map make sure you start going lower than that, and remove biomes that go to distance 4, or even 3.

Basically imagine like this: Setting the minDistance and maxDistance at the same amount, you are telling the game to spawn one of these subworlds at exactly this distance from spawn. You are drawing rings of biomes.

Let's look at this code:

  - tagcommandDistanceFromTag
    tagAtStart
    minDistance: 3
    maxDistance3
    commandReplace
    subworldNames:
      - subworlds/ocean/Ocean

This says: "hey, spawn me oceans at exactly 3 worldcells away from spawn In a circle". Full YAML
It will look like this:
image.thumb.png.2f3d84ff56f01f99fddfd66e0cba48fe.png
 

Because we only defined a single biome (Ocean), and told it can only spawn at least 3 and at tops 3 distance, it draw a Circle of oceans. (The middle is the forest starting biome)

If you give it multiple biomes to chose from, it will start picking from them randomly, still following along that ring:
image.thumb.png.f1577b958c1eda8060feabc0ddf757b9.pngű 

And that's how you can build a circular world, ring by ring, giving your world bands of zones where you can define your biomes to spawn.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

Please be aware that the content of this thread may be outdated and no longer applicable.

×
  • Create New...