Starting with the base input line in the planet text file we have the following section. This is a clean slate base code available to create/edit. These tell the game you are inputting terrain formulas.
"terrainFormula": [ "OUTPUT = AddHeightMap ( )", "OUTPUT = AddHeightMap ( )", "OUTPUT = AddHeightMap ( )", "M = AddHeightMap( )", "M2 = AddHeightMap( )" ],
It is assumed that these can technically be infinite, though too many lines could have adverse effects such as more intensive GPU processing, terrain lag, game crashing/freezing or any other mayhem. These formulas can change dramatically depending on the size or “radius” of the planet. Smaller planets are more heavily affected by smaller numbers in the formula so the user must be mindful of this. When making any existing planet/moon smaller or larger the user must change the numbers in the formulas accordingly.
There are 5 sections in each formula available to edit. Here is a look at the following formula and a brief description of what each part does. For the formula in the parentheses we will name each part as (section1, section2, section3, section4, section5). As of right now there are only 5 sections in the formula available to edit.
"OUTPUT = AddHeightMap( Perlin, 25000.0, 30, Curve1, M)"
Section1 of the formula has a name and each name does something different by giving the terrain a different texture or a heightmap.
Basic height maps:
Craters: This is a given. It produces a crater effect. This one in particular happens to make the plateau between the craters rise in height as the second number in the formula is made higher. Crater formulas usually have a lower Section2 and a higher Section3. It doesn’t take a dramatically high iteration number such as the Perlin formulas to see the effects.
Perlin: Gives the appearance of rolling hills. The effects of a Perlin formula are much more noticeable in smaller-radius planets. Perlin formulas usually have a higher Section2 and a lower Section3. A high iteration number is required to visually see the effect on large planets.
The following are also available but it is recommended to leave them in their own planets:
PLAINS versions of these heightmaps are also available: they have the original heightmap name on them, but with PLAINS after that, so the PLAINS version of Mars is Mars_Plains. (Note that Phobos, Deimos and Io don't have any PLAINS heightmaps.) If you want to apply a PLAINS heightmap then copy the heightmap (for example "OUTPUT = AddHeightMap (Mars, (circumference of planet in meters), 3800)") and paste it right below it. Then, change Mars to Mars_Plains, then change Section3 to 1.
Section2 of the formula has to do with the length of the formula across the planet's surface in meters. The value is a cyclic number: when you reach the value on this section, it will repeat by the circumference divided by the number. This will tell you how many times the heightmap is repeated. A value of the circumference of the planet would mean that 1 iteration of the formula is created on the entire planet's surface. It is recommended the user add a lower number of iterations for large terrain features (such as mountains and depressions). Some base planets that have their own particular height map that will use their own circumference (that is, the diameter of the planet multiplied by pi or 3.14159265359) in a formula.
Section3 of the formula is in regards to the height/depth of the effects in meters. The user may also produce negative numbers in this section, such as the following:
"OUTPUT = AddHeightMap( Perlin, 25000.0, -30, Curve1, M)"
This makes the particular terrain lower as opposed to the positive numbers that raise the terrain value.
Section4 of the formula has to do with terrain modifiers. These are used to modify the shape of the formula terrain values (and make them more realistic) and each modifier (Curve1; Curve2; Curve4; Curve8; Pow3; and many more) gives a different effect. This section also has the ability to use the “null” attribute so as not to apply any modifier to the formula.
Section5 of the formula is for additions to the particular line the user is editing. What this effect produces is an add-on to an existing terrain formula. Such as giving the plateaus of craters a Perlin effect so they aren’t just “flat”. “M” can be used as universal input (for the particular planet only) and can be added to each individual output line. The user can also input additional M series lines such as M2, M3 and so on to give a planet a widely varied look.
If there is a PLAINS formula right above it, and you want some terrain in your plains, write this section as PLAINS (for example "OUTPUT: AddHeightMap(Perlin, 21000.0, 90, null, PLAINS)"
) to ensure that the heightmap will still be used even if it is in a PLAINS area.
Completed formulas should look like this. Please be mindful of the commas and note where they are placed. The last line (here the “M”) never has a comma. If the formula the user has created has one line only, no comma must be used on the formula line.
"terrainFormula": [ "OUTPUT = AddHeightMap(Craters, 20000.0, 20, null, M)", "OUTPUT = AddHeightMap(Craters, 15000.0, 10, Curve1, M)", "M = AddHeightMap(Perlin, 30000.0, 50)" ],
This tutorial gives some insight into how to construct a base terrain for a planet. The final process is mostly trial-and-error and its appearance ultimately up to the end user.
After editing, always click the “Build New Rocket” button as resuming the game during terrain editing can have unwanted effects.