# Welcome to Moonlander

<figure><img src="https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/oGxJ2uW9ZECIdSofpgwR/mono.png" alt=""><figcaption></figcaption></figure>

> "Don't tell me the sky is the limit when there are footprints on the Moon." — Paul Brandt

## The Basics

Moonlander is an AI powered copilot that helps you to **build virtual worlds in just a few seconds**.&#x20;

With Moonlander, you can build games, virtual meeting rooms, e-learning modules, and more through **a text prompting interface and powerful UI**. Just upload your own or bought assets and let our AI tagger enrich the metadata of your library. After that you can quickly build your first world!

The Moonlander Unity SDK Quick Guide is a concise reference that provides essential information for installing and operating the Moonlander SDK. **You can find the downloads** [**here**](https://drive.google.com/drive/folders/1dPlIhgHyVxxkdmDHWm_ZAFFkH33-K3H8).

### SDK Version

The Moonlander SDK for Unity is currently in version **v1.0.0-alpha.6**. This version contains a Run Time API that provides an **interface for virtually any task** involving a scene. You can now read our documentation to integrate the API in your game or product and help explore the possibilities and limitations with this technology. Not only it handles procedural generation within the product features at runtime, but it's also an extensible tool that allows you to create your own generators and algorithms. For questions about porting your project to this version, we recommend contacting us on [Discord](https://discord.com/invite/sNGPThMEc2).

## Get Started

We've put together some helpful guides for you to get setup with our product quickly and easily.

{% content-ref url="/pages/zq4W4tS82wJnMZPImp4Y" %}
[Getting set up](/fundamentals/getting-set-up)
{% endcontent-ref %}

{% content-ref url="/pages/U1eLsWuJFGe5wijj42kB" %}
[Hello Virtual World!](/fundamentals/getting-set-up/hello-virtual-world)
{% endcontent-ref %}

{% content-ref url="/pages/oLyKIgA4c83M3XydT4WX" %}
[Generator Stack Presets](/fundamentals/getting-set-up/generator-stack-presets)
{% endcontent-ref %}


# Getting set up

This page contains all the necessary information to install the Moonlander SDK.

<details>

<summary>Step 1: Download and Install Unity</summary>

This SDK requires you to have [Unity 2022.3.10f1](https://unity.com/download) installed on your system. At this moment, we do not actively support other Unity versions.

</details>

<details>

<summary>Step 2: Download the Moonlander Unity SDK and Content Packages</summary>

Download our [SDK and content packages](https://drive.google.com/drive/folders/1dPlIhgHyVxxkdmDHWm_ZAFFkH33-K3H8). Each release consists of three files: the SDK, the MoonlanderContent package, and the BoosterPack. You need the first two files to get started, but we highly recommend to install the BoosterPack as well. The BoosterPack gives you enough assets to create an interesting virtual world.

:warning:Warning! The assets in the **BoosterPack** **are not royalty-free**. They serve only as example material and they cannot be used on any public builds for commercial purposes or otherwise and cannot be redistributed.:warning:

</details>

<details>

<summary>Step 3: Make sure you have the credentials to get started</summary>

Make sure you have an SDK key to get access to the Moonlander SDK. You can apply [here](https://dashboard.mailerlite.com/forms/279674/110790421244806303/share), and you should receive an email automatically within a few minutes. If you didn't receive your SDK key, feel free to contact <bram@moonlander.ai>.

</details>

<details>

<summary>Step 4: Install the SDK!</summary>

To test and install the SDK, we recommend starting a new project. The SDK is made to work with the **3D (URP)** template, so select this template and give it a name.

Once the project is done loading, it is time to install the SDK:

1. Click on the *Window* menu and navigate to the *Package Manager.*
2. Press the plus sign, and click Navigate *Add package from Tarball.* ![](https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/cD7GxVL1aTgNb0ZTwdfo/install%20package.png)

   ![](https://prod-files-secure.s3.us-west-2.amazonaws.com/9047f298-486b-4cd4-bf52-ae4516adc0b7/028cfdea-05c9-4f47-819d-2d8f6f02dd03/Unity_2023-10-17_12-33-40.png)
3. Open the *com.mnlndr.moonlander-1.0.0-alpha.5.tgz* package. This will install the Moonlander SDK.
4. **Enter your SDK License key.** This will give you access to the SDK!
5. You now have access to the SDK!

</details>

{% embed url="<https://youtu.be/_xVo-t_qNEA>" %}


# Hello Virtual World!

This page contains a guide to install the content packages, and to create your first AI generated virtual world.

Now that you have installed the SDK, it is time to start generating.&#x20;

<details>

<summary><strong>Step 1: Install the Content Package(s)</strong></summary>

To get started quickly, we provide a set of assets that you can use to test the functionality. Just drag the **MoonlanderContent.unity** package in the window, and it will install. If you want to create visually stunning worlds, install the **BoosterPack** as well.

</details>

<details>

<summary><strong>Step 2: Assign a Library of Assets</strong></summary>

Shapeshifter needs a Library of Assets to generate worlds. Go to the **Setup** foldout and select one of the Libraries.&#x20;

![](https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/7MWs2rGsncctFFp7IkKE/assign%20library.png)

</details>

<details>

<summary><strong>Step 3: Choose your first generator</strong></summary>

<img src="https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/FqF652dQdHiWTvKo11yH/generators.png" alt="" data-size="original">

Now setup the generators for Shapeshifter to use. This can be done via the Generators window, which can be opened by clicking the "**Edit Generators**" button on the Shapeshifter overlay.

You can add generators through the "+" button at the top left of the Generators window. Pressed it, and then select "**Generator Stack** > **MoonlanderContentSampleGeneratorStack** from the dropdown menu.”

Now press **Generate** in the Shapeshifter menu, and you will generate your first world!

</details>

<figure><img src="https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/x8bwrqAmTRfxJC46sL1E/Screenshot%202024-01-04%20at%2011.07.20.png" alt=""><figcaption><p>A land generated by the <strong>MoonlanderContentSampleGeneratorStack</strong>, our Hello World! Example.</p></figcaption></figure>

{% hint style="info" %}
Each Library consists of a number of assets in the Library Manager. In order to create the world that you want, make sure you have assets that are related to that world. For example, to make a Desert terrain you need cacti, rocks, and the right textures.
{% endhint %}

Congratulations! You have now created your first AI generated Virtual World. Now let's go through the **Generator Stack**, to start building some visually appealing terrains!


# Generator Stack Presets

This page shows the Generator Stack Presets, the demo generations of Moonlander.

Generator Stack Presets provide a wide array of types of worlds that show the potential of the Moonlander SDK. You can use these as a starting point and a point of reference. You need the BoosterPack to generate these examples yourself.

***

## CandyLand

<figure><img src="https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/J8hxtQZIPdqkCvQ1cc2u/Screenshot%202023-12-07%20at%2018.27.46.png" alt=""><figcaption><p>CandyLand is a low poly cartoon candy styled scene, suitable for both Mobile and PC. </p></figcaption></figure>

## DesolateDesert

<figure><img src="https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/FLFw28ZbvHbEatSR6fnv/Screenshot%202023-12-07%20at%2017.47.05.png" alt=""><figcaption><p>A high quality nature pack, ideal for creating post-apocalyptic or Wild Wild West games. Vegetation very similar to what grows in Arizona and (New) Mexico.</p></figcaption></figure>

## LushForestPath

<figure><img src="https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/GLYKsV36WOGKMpjwncZE/Screenshot%202023-12-07%20at%2016.19.30.png" alt=""><figcaption><p>LushForestPath offers a vivid world of dense greenery and enchanting trails, perfect for fantasy realms or serene woodland scenes. Immerse players in the beauty of a lively forest with towering trees, meandering streams, and captivating flora.</p></figcaption></figure>

## MushroomForest

<figure><img src="https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/01dhP9OzjvNf5eKLJYQi/Screenshot%202023-12-07%20at%2018.01.28.png" alt=""><figcaption><p>Meadow grass, pine trees, and a wide array of mushrooms make this terrain perfect for European forests and other temperate climates.</p></figcaption></figure>

## StylizedTrees

<figure><img src="https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/azUiAEj9PKL9R8mdbqGP/stylized.png" alt=""><figcaption><p>StylizedForest combines realism with artistic flair, offering a visually striking environment for various game genres. Immerse players in a stylized rendition of nature, with meticulously crafted trees, rocks, and streams to enhance the overall gaming experience.</p></figcaption></figure>

## TropicalIsland**Archipelago**

<figure><img src="https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/im7amaT1qHUB8t2xDX9f/Screenshot%202024-01-11%20at%2022.40.47.png" alt=""><figcaption><p>TropicalIslandArchipelago unveils the beauty of interconnected islands surrounded by azure waters. Perfect for open-world environments or sea-faring adventures, the pack features lush landscapes, diverse flora, and the allure of tropical exploration on each captivating island.<br></p></figcaption></figure>


# Using The Copilot

In this page we explain everything you need to know about our game developer copilot.

While the [Generator Stack Presets](/fundamentals/getting-set-up/generator-stack-presets) look very pretty, the real fun is making your own custom worlds of course! The easiest way to get started with your custom worlds is to use our Copilot FLX.

FLX is trained to do a varied range of tasks, among them:

1. Creating Generators for you
2. Customising and improving Generators for you
3. Give feedback on how to improve your scenes
4. Explaining how Moonlander works

## Getting Started

<figure><img src="https://4179000272-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAgMv3vfjtskHQTtxEVyx%2Fuploads%2FdCLOMcobsH65dVtuEaQc%2Fopen_copilot-ezgif.com-video-to-gif-converter.gif?alt=media&amp;token=dcacfa82-de80-4dfa-bb87-60392324e976" alt=""><figcaption><p>Call FLX by clicking on the Copilot in the Shapeshifter overlay</p></figcaption></figure>

First, navigate to the Copilot menu in the Shapeshifter window. This will open a chat window.

<figure><img src="https://4179000272-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAgMv3vfjtskHQTtxEVyx%2Fuploads%2FpRFgpuvZL0xTK17m05El%2FScreenshot%202024-01-30%20at%2021.58.17.png?alt=media&amp;token=99a32a25-8ede-4aff-ad25-651bc198e7a2" alt=""><figcaption><p>Use one of the prompt suggestions or use your own imagination and type your own prompt</p></figcaption></figure>

On opening the chat interface, FLX will show you a few prompt suggestions. These will give you an idea of what kind of prompts you can instruct, but you can generate whatever you want of course.

<figure><img src="https://4179000272-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAgMv3vfjtskHQTtxEVyx%2Fuploads%2Fo2OZLI3JrUtjx2i3Fdee%2FScreenshot%202024-01-30%20at%2022.03.27.png?alt=media&amp;token=903433a9-a03b-449f-a50f-2a16921e8e61" alt=""><figcaption><p>Once you have started a conversation with FLX, you can keep talking to it to prompt for new results</p></figcaption></figure>

Now FLX will start suggesting you generators, that you can apply to your scene.

{% hint style="info" %}
FLX creates generators with 3D Objects from your Library. This means that it can only generate a Forest for you if you have trees in your library.
{% endhint %}


# High Level Overview

This page describes all the high level concepts of the Moonlander SDK

If you have followed the fundamentals in [Getting set up](/fundamentals/getting-set-up), you have already touched all the important components of Moonlander. When you look at the Shapeshifter overlay, you will see all of them in one user interface:

<figure><img src="https://4179000272-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAgMv3vfjtskHQTtxEVyx%2Fuploads%2FBzrtJKUY5CT6mzohY0Td%2FScreenshot%202024-01-30%20at%2022.09.03.png?alt=media&amp;token=01adee9e-7a8a-49b1-875d-bbf6d179a7a6" alt=""><figcaption><p>The Shapeshifter overlay that connects you to the <a data-mention href="/explore-topics/library">Library</a>, <a data-mention href="/explore-topics/generator">Generator</a> and Copilot.</p></figcaption></figure>

1. Copilot (optional). The Copilot is a LLM that can generate scenes for you through a text prompt.
2. [Library](/explore-topics/library). The Library stores all your 3D Assets, Skyboxes, and Terrain Textures. When you generate a terrain, Shapeshifter will look into your Library to find everything it needs to generate a terrain to your liking. So the better your Library, the better your worlds! We have provided a BoosterPack with a lot of Assets to start out with, but we highly recommend in creating your own Library as well.
3. [Generator](/explore-topics/generator). A Generator is a Base Class that instructs Shapeshifter how to build up the scene. All your Generators together are called the Generator Stack, which consists of several types of Generators. The Generators are highly customisable, so knowing all the different settings are crucial for creating a virtual world exactly how you would like.

Since we have already covered the Text Prompting in [Using The Copilot](/fundamentals/getting-set-up/using-the-copilot), let's quickly move to the [Library](/explore-topics/library)!


# Library

This page describes the purpose and basic functionality of the Moonlander library

The Library is a scriptable object file that contains all the assets separated into properties like *3D Assets* for the prefabs, materials for the *Skyboxes*, and *Terrain Textures* for the Unity Terrain Layers. Furthermore it serves as a repository for all your custom properties, for example prefabs linked to custom mechanics.


# Asset Tagging

Assets need the right metadata to make sure they can be placed by Shapeshifter. To do this, go to the Asset Library and navigate to the assets in your library.&#x20;

<figure><img src="https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/0Db3JKPzP0cgfpTl2rda/Screenshot%202024-01-04%20at%2014.54.41.png" alt=""><figcaption></figcaption></figure>

Select the assets that you want to tag, and click Auto-Tag. This will then send the assets to our server, and return the right metadata back. You can also manually configure the tags if you want.


# Generator

This page describes what a Generator is and how they shape your scenes

Generators define how the scene is built up, what objects are spawned and the the rules of placement of objects on the terrain. Every scene that you will build with Moonlander consists of several generators, each responsible for a different component in your scenes. All generators combined in your scene is called your Generator Stack.

There are two types of Generators: the [Global Generator](/explore-topics/generator/global-generator) and the [Bounds Generator](/explore-topics/generator/bounds-generator). You can define global settings through Global Generators and define the placing of objects and creation of Unity terrains through the Bounds Generator.

Each Generator consists of two tabs:

* Properties. The properties tab consists of all settings that make up this generator. Some Generators are very simple, while others can be very complex.
* Dependencies. In this tab, you can see the links between generators. The Input lists the Generators to which the current Generator listens, the Output lists the Generators that have the current Generator as Input. For more information see [DataRegistry](/explore-topics/dataregistry).

{% hint style="info" %}
Dependencies are key for building scenes that make sense. For example, you don't want to have your vegetation to grow on your roads! Linking your road generator with your foliage generator can quickly solve this issue.
{% endhint %}

####


# Global Generator

Global generators are generators that create global settings and affect the entire scene.

&#x20;There are several types of global generators:

* [MapGenerator](/explore-topics/generator/global-generator/map-generator): a Generator that creates a 2D data file that can be used for Terrain Height, Object Density, Texture, and many more.
* [TerraformerGenerator](/explore-topics/generator/global-generator/terraformergenerator): a Generator that can allows you to customise the scene, for example the weather effects and overall style.
* [SkyShaperGenerator](/explore-topics/generator/global-generator/skyshapergenerator): a Generator responsible for setting the Skybox and the Directional Light
* [ColorGradingGenerator](/explore-topics/generator/global-generator/colorgradinggenerator): a Generator that allows you to post process effect colours


# Map Generator

A Map Generator is a generator to create important components of the landscape, like roads, the height of the terrain, and its steepness.&#x20;

####


# TerraformerGenerator

TerraformerGenerator is a Global Generator that links the the shaders and the textures and the sky of the whole scene. Terraformer allows you to mix and match these shader effects to create a distinctive visual style that sets your game apart from the rest. The TerraformerGenerator is the centralised generator for control over your scene.

{% hint style="info" %}
In order to use the functionalities of TerraformerGenerator all materials need to have the [Multi Shader](/explore-topics/multi-shader) assigned.
{% endhint %}

#### Foliage Amount

With Foliage Amount, you can override the Alpha Clipping of your foliage. The higher this setting, the sparser the foliage will be.&#x20;

#### Top Weather Cover

Top Weather Cover allows you to apply Terrain Texture Assets to the assets placed by your ObjectPlacementGenerators. You can use this to cover your entire scene in snow.

#### Top Texture Cover

Top Texture Cover allows you to apply Terrain Texture Assets to the assets placed by your ObjectPlacementGenerators. You can use this to cover your scene with wild grass.

{% hint style="info" %}
The Top Weather Cover and Top Texture Cover are very similar, but there are small differences. The former also covers trees and stones, while the latter doesn't. If you enable both, the Top Texture Cover will be applied first and the Top Weather Cover will be applied afterwards.
{% endhint %}

#### Outline

Outlines will give your assets an outline with a custom color and thickness, which gives your scene a unique style.

#### Toon Effect

The Toon Effect submenu provides you options to create a visual style for your assets to make it look more cartoonish or animated.

#### Color Palette

The Color Palette allows you to set a base, first, and second color for your scene. This is useful for example when you want to change your scene to the Fall, or Summer. It will overlay a color based on the position of the terrain. So the position of an object determines which tint of color it picks. Color Palettes can create a lot of looks and styles for your scenes.

#### Wind Effect

The Wind Effect allows you to create wind behaviours that affect your foliage.&#x20;


# SkyShaperGenerator

This page describes the role of the SkyShaperGenerator and the several ways to create a Skybox

SkyShaperGenerator is a Generator that is responsible for generating a Skybox and the Directional Light. There are two ways to generate a Skybox through the SkyShaperGenerator:

1. Through the [Asset Loader](/explore-topics/asset-loader).
2. By manually selecting a Skybox from your [Library](/explore-topics/library)

Besides selecting a Skybox in the SkyboxGenerator, you can also create one through prompting a Skybox in the [AI Skybox Generator](/explore-topics/ai-toolkit/ai-skybox-generator).


# ColorGradingGenerator

This page describes the ColorGradingGenerator and its use cases.

ColorGradingGenerator is a post process effect for color grading the image after rendering. This can be a useful generator for example when you want to create a cartoony game. When you select a ColorGenerator profile, it will spawn a Color Grading object in your hierarchy. This will allow you alter the color grading.&#x20;

<figure><img src="https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/JU5XprNLsUVQ1ZEQBMYQ/Screenshot%202024-01-11%20at%2021.00.39.png" alt=""><figcaption></figcaption></figure>


# Bounds Generator

Bounds Generators are Generators that have the size of the bound of your terrain and operate within that scope.&#x20;

* [TerrainGenerator](/explore-topics/generator/bounds-generator/terraingenerator): A Generator that grabs height information from a layer stack
* [ObjectPlacementGenerator](/explore-topics/generator/bounds-generator/objectplacementgenerator): A Generator that places 3D Assets in your terrain
* [PlaneGenerator](/explore-topics/generator/bounds-generator/planegenerator):  A Generator that spawns the prefab&#x20;


# ObjectPlacementGenerator

ObjectPlacementGenerator is a generator that spawns objects on your terrain.  With each ObjectPlacementGenerator you can select the types of assets that you want to load, to which other terrain behaviour it should listen, and how they should orient. Furthermore the ObjectPlacementGenerator can set the Rendering and Collision for you.


# PlaneGenerator

A PlaneGenerator spawns a prefab the size of the bounds at the given height. This is mainly used for water, oceans, lava, or similar objects.


# TerrainGenerator

A single generator that generates a terrain for you.

Height Layers: Edit Layers

Terrain Layer Data:


# Multi Shader

This page describes how Multi Shader works and how it can be used to customise your assets

The Multi Shader is a custom Shader you can assign your materials to to function for [Terraformer](/explore-topics/generator/global-generator/terraformergenerator) and conforming objects to the terrain in [ObjectPlacementGenerator](/explore-topics/generator/bounds-generator/objectplacementgenerator). With Multi Shader you can quickly apply terrain customisation to your materials.

{% hint style="warning" %}
Warning! The Multi Shader will overwrite the files of the Materials that you convert, so be careful of which Materials you use. When testing, make sure you have a backup of your materials before converting.
{% endhint %}

You can convert your own materials as follows:

<details>

<summary>Step 1: In the menu, go to MoonlanderSDK > Terraformer > Multi Shader Converter.</summary>

![](https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/Uu1o9bo4VxdnSULnADVe/Screenshot%202024-01-11%20at%2021.55.29.png)

</details>

<details>

<summary>Step 2: Move a material file (.mat) to the Multi Shader Converter and press 'Convert Materials'.</summary>

![](https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/oyyWkYq4vkQtT0075I3o/Screenshot%202024-01-11%20at%2021.58.26.png)

This will convert your material to a Multi Shader. You can now modify your assets with [TerraformerGenerator](/explore-topics/generator/global-generator/terraformergenerator) and [ObjectPlacementGenerator](/explore-topics/generator/bounds-generator/objectplacementgenerator).

</details>

<details>

<summary>Step 3: Test if your new materials have been converted!</summary>

Move your asset to the scene and hover zoom in on the asset. Now add some Snow in the Top Weather Cover of the [TerraformerGenerator](/explore-topics/generator/global-generator/terraformergenerator). If everything works correctly, you should be able to see snow on your scene.

![](https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/YMsQJXJ0TtkaJgNmomYt/Screenshot%202024-01-11%20at%2022.08.05.png)![](https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/2Q1xDGzUyJfehKUXJCqx/Screenshot%202024-01-11%20at%2022.08.50.png)

![](https://content.gitbook.com/content/AgMv3vfjtskHQTtxEVyx/blobs/aOwqq1yxk0yKxd5m3diG/Screenshot%202024-01-11%20at%2022.12.59.png)

</details>


# DataRegistry

DataRegistry is a collection that link generators to each other. This is a powerful tool in the creation of your terrains, as this makes it possible to depend the behaviour of terrain elements on other elements. For example, it makes sense to add Mushroom objects only on the grass and not on the road. With a DataRegistry this becomes trivial.


# Layers

This page describes the layer functionality that you can find in many Generators.

If you go to the *edit layers* section, it will spawn a photoshop like editor that allows you to the height map. There are several types of (sub)layers:

* GroupLayer: Group Layers allow you to combine a set of layers together.
* PresetLayer
* DataRegistryLayer:&#x20;
* NoiseLayer: A layer that generates a noise field. The noise layer consists of several properties:

  * Type: the noise type, where you can choose between perlin, simplex, and cellular:
    * Perlin: Smooth, continuous noise with realistic-looking textures due to its smooth transitions between values
    * Simplex: Same as Perlin but computationally cheaper.
    * Cellular: Generates a pattern of cells in space, often used for irregular and diverse patterns. A good example of cellular is when you want to generate dunes.
  * Offset: This parameter allows you to shift the entire noise pattern in the x and y dimensions, influencing how the pattern aligns with the coordinates of the space it occupies.
  * Octaves: individual layers or iterations of noise that contribute to the overall pattern.
  * Persistence: controls how quickly the influence of each octave diminishes, affecting the prominence of details.
  * Lacunarity: determines the rate at which the frequency of octaves changes, influencing the diversity and complexity of the overall texture.

  Besides the properties, the NoiseLayer also has several filters:

  * Steepness filter: creates a data set for the steepness of the terrain. By taking the steepness filter over a terrain, you would get a darker value the steeper it gets. The filter takes its samples from its neighbouring pixels and calculates the angle from every pixel. This is useful for how when you will spawn in the grass, for instance, that it will follow the lines of the terrain or for wherever you want to use it for.
  * Invert filter
  * Curves filter
  * Levels filter

A layer that generates a noise field

* UniformLayer: A solid value. Useful as a base to mix with other layers and to create constant features.


# Asset Loader

This page describes the working of the Asset Loader


# AI Toolkit

The AI Toolkit is a collection of AI powered services that will speed up &#x20;


# AI Color Palette

This page describes the working of the AI Color Palette to customise your assets

The AI Color Palette is a feature that turns the description of your landscape into a Color Palette. You can use this as input of your [TerraformerGenerator](/explore-topics/generator/global-generator/terraformergenerator#color-palette) in your [TerraformerGenerator](/explore-topics/generator/global-generator/terraformergenerator). To open the AI Color Palette, navigate to the MoonlanderSDK in your Unity Window, and click AI Toolkit > AI Color Palette.

You can then type in a scenario or mood of your palette, and select the number of colors you would like to receive.

{% embed url="<https://www.loom.com/share/1696a1578d254d919a4352963895e8b3>" fullWidth="false" %}


# AI Skybox Generator

This page describes the AI Skybox Generator and how to apply them to your scene

{% embed url="<https://www.loom.com/share/1c1d1142f171403490a729472463e02b>" %}


# Licenses


# Changelog

```
## MoonlanderSDK-1.0.0-alpha.5

* Feature: Asset picking and matching algorithm overhaul
* Feature: Automatic stack generation
* Feature: Prompting workflow overhaul
* Feature: ML based stack generation


## MoonlanderSDK-1.0.0-alpha.4

* Feature: Added a vignette filter (allows islands and edge objects)
* Feature: GPU Layer sampling and filtering (10x generation-time performance boost)
* New noise sampler types (improved generation possibilities and faster iteration)
* Domain warping on noise samplers. (improved generation possibilities)
* Collision with GPU instanced objects.
* Automatic asset footprint calculation (ability to pick assets by size on asset loaders)
* Improvements in the asset loaders.
* BoosterPack: adapted all content to the new GPU based generation
* Content metadata update (Auto-tagged / revised all assets)
* Sample scenes included on the content and booster pack.
* Many bugfixes and UX improvements.


## MoonlanderSDK-1.0.0-alpha.3.1

* Fix: On the MultiShader, the Normalmap tiling and offset didn’t match the albedo texture.
* Fix: Small UI fixes on the Library window and Generators.
* Feature: Allow manual tagging on multiple assets at once.
* Fix: Generator window sometimes didn’t update correctly.
* Feature: Added an advanced options foldout on the Shapeshifter overlay.
* Feature: Added tiling and offset options on the MultiShader.
* Fix: Prompting is disabled when no generators are using Asset Loaders.
* Feature: Added a ColorGrading Generator.
* Added a toggle to enable or disable the Asset Loaders
* Fix: The multishader material converter now works again after the shader migration of alpha.3


## MoonlanderSDK-1.0.0-alpha.3

* Feature: Complete rewrite of the Library Window interface.
* Feature: Auto-tagging of library assets with AI.
* Feature: Activated the AI Toolkit:
    - AI Color Palette Generator
    - AI Script Generator (describe functionality in English, get a C# script)
    - Skybox Generator (text-to-Skybox)
* Editor: Multi-shader converter now works. It will automatically convert standard shader materials to use Moonlander's multi-shader. This enables your assets to:
    - Bend to conform to terrain
    - Terraformer shading (toon shading, outlines, etc.)
    - Terrain texture blending
    - Top covers and weather covers (Like adding a layer of dust or snow to your assets)
* Feature: Added migrations and installation hooks that facilitate the installation and updating of the SDK.
* Fix: many Bugfixes and workflow improvements.

## MoonlanderSDK-1.0.0-alpha.2 (Wrongly released as v1.0.1-alpha.1)

* Feature: Both TopWeatherCover and TopTextureCover are now compatible with the TerrainTextureAssets used for the terrain layers.
* Fix: When using ‘Conform To Terrain’, the placement offset works correctly (only works with assets using the multishader).
* Fix: Same seed and same prompt should now always result in the same generation.
* Feature: Added a toggle to let the spawned object from the ObjectPlacementGenerators perfectly stick to the terrain.
* Feature: Added a ‘PlaneGenerator’. This spawns a plane prefab at a given height. Used for water, lava, etc.
* Fix: When a generator setting changes, and you press generate, it will regenerate everything to ensure it is all up to date and consistent.
* Additions: Added a new version of the MoonlanderContent pack compatible with the new SDK release.
* Additions: Added a content pack ‘BoosterPack1’ containing example assets and presets.
* Fix: Multiple bugfixes and improvements.

Known issues
* Editor: The multishader converter doesn’t work yet.
```


# Run Time Examples

## Overview

The runtime API is split in to two main access points the \`Shapeshifter\` class, for generating worlds and configuring data. And the \`FLX\` class, for prompting and interacting with the AI.

## Getting Started

To get started is very easy, you simply need to set the Library that assets will be pulled from, and the generators or generator stack that will be used. Then generate!

```cs
using UnityEngine;
using Moonlander.Core;

public class SetupAndGenerateExample : MonoBehaviour
{
    public Library library;
    public GeneratorStackPreset generatorStack;
   
    public Bounds generationArea = new Bounds(Vector3.zero, new Vector3(50, 15, 50));
        
    private void Start()
    {
        Shapeshifter.Library = library;
            
        Shapeshifter.InstantiateGeneratorStack(generatorStack);
            
        Shapeshifter.GenerateAreaAsync(generationArea);
    }
}

```

You only need to set the library and generator stack once, `Shapeshifter.GenerateAreaAsync` can then be called repeatedly from anywhere on the main thread to generate multiple areas.

{% hint style="info" %}
If you set the Library in the editor via the overlay, and set the generators via the Generators window. You can just call `Shapeshifter.GenerateAreaAsync` at runtime without any setup.
{% endhint %}

### Using Copilot FLX

All AI interaction in Moonlander is done through the FLX assistant(pronounced Felix). With the `FLX` class being the main access point.

To get started, you need to first create a `Chat`, a Chat is a local copy of the back and forth conversation with FLX. It also acts as a unique key for sending messages and deleting chats.

`Chat myChat = await FLX.CreateChat()`

{% hint style="info" %}
Most methods in `FLX` have overloads for either raising a callback when completed, or using an async/await pattern. You can use whichever works best for you!
{% endhint %}

Once you have created a Chat, you can send a message on that Chat to FLX.

`FLX.SendMessage(myChat, "A pine tree forest.")`

If FLX responds with a Generator Stack, it will be extracted from the message and automatically instantiated, replacing any previous generators.

Multiple messages can be sent to the same Chat to continue the conversation `FLX.SendMessage(myChat, "Add some ferns too")`. However you must wait for a response before sending another message to the same chat.

Chats are not stored locally at runtime, so when exiting a runtime environment (either play mode, or closing the application in a build), it is important to delete the chats that were created. Otherwise they will stay on the server with no way to get or delete them.

`FLX.DeleteChat(myChat)`

A Chat can be serialized and deserialized like any other C# object, so can be integrated in to a custom save system for storing them between runtime sessions.

{% hint style="warning" %}
When saving locally, you do not want to delete the chat, as doing so would remove it from the server and it cannot be restored. Even if you have the local copy.
{% endhint %}

The following example creates a new Chat, sends a prompt to FLX requesting a pine forest, and after it gets a response and has applied a stack, deletes the Chat.

```cs
using UnityEngine;
using Moonlander.Core;

public class ChatExample : MonoBehaviour
{
    public string prompt = "A pine tree forest.";

    private async void Start()
    {
        Chat quickChat = await FLX.CreateChat();

        await FLX.SendMessage(quickChat, prompt);

        FLX.DeleteChat(quickChat);
    }
}
```

{% hint style="warning" %}
Generally it is better to keep a reference to a Chat and send it new prompts instead of creating and then deleting them.&#x20;
{% endhint %}

### Using Shapeshifter and Data Registries

Data Registries hold data that Generators can use and have generated. As such, it can be helpful to access them for gameplay.

The `DataRegistryRef<T>` class is the easiest way to get a reference to a Data Registry that is being used by a generator. To use it, you specify the type `T` of the `IDataRegistry` that you want to get a reference to, and specify the name of the DataRegistry. The type combined with the name, act as unique identify for a DataRegistry. No two DataRegistry of the same type can also have the same name.

{% hint style="info" %}
The name of the DataRegistry is case sensitve, so "terrain", and "Terrain" would be two different registries.
{% endhint %}

Once you have setup the `DataRegistryRef<T>`, you can resolve the reference at any time by calling the `Resolve()` method. For example:

`myRegistry = registryRef.Resolve()`

The following example sets up a reference to a Terrain DataRegistry, then resolves the reference, and if a DataRegistry is found, logs the terrain height at the GameObject's position.

```cs
using UnityEngine;
using Moonlander.Core;
using Moonlander.Core.DataRegistries;

public class GetDataRegistryExample : MonoBehaviour
{
    public DataRegistryRef<TerrainDataRegistry> terrainDataRegistryRef = new DataRegistryRef<TerrainDataRegistry>()
    {
        RegistryName = "Terrain" 
    };

    private void Start()
    {
        TerrainDataRegistry terrainRegistry = terrainDataRegistryRef.Resolve();

	if (terrainRegistry != null)
        {
 	    float terrainHeight = terrainRegistry.GetHeight(transform.position);
        
	    Debug.Log($"Height: {terrainHeight}");
        }
    }
}
```

Some Generators automatically output DataRegistries, while some have a text field where you need to set the name of the DataRegistry that it will output.

{% hint style="info" %}
The ObjectPlacementGenerator for example has a `Output` text field. Giving it a name will cause the Generator to put all of the objects it generates in to a `ObjectDataRegistry` with the same name.
{% endhint %}

{% hint style="info" %}
Multiple Generators can output to the same DataRegistry.
{% endhint %}

###

##


# Welcome to Moonlander

<figure><img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FJxQxNH6q0t5IoYkX3mi8%2Fmono.png?alt=media&amp;token=45919af1-2445-4bcf-b8e2-df01db235337" alt=""><figcaption></figcaption></figure>

> "Don't tell me the sky is the limit when there are footprints on the Moon." — Paul Brandt

## The Basics

Moonlander is an AI powered copilot that helps you to **build virtual worlds in just a few seconds**.&#x20;

With Moonlander, you can build games, virtual meeting rooms, e-learning modules, and more through **a text prompting interface and powerful UI**. Just upload your own or bought assets and let our AI tagger enrich the metadata of your library. After that you can quickly build your first world!

The Moonlander Unity SDK Quick Guide is a concise reference that provides essential information for installing and operating the Moonlander SDK. **You can find the downloads** [**here**](https://drive.google.com/drive/folders/1sLttSyPugbCeAyrWaDT-dCMU4ApjrbSw)**.**

### SDK Version

The Moonlander SDK for Unity is currently in version **v1.0.0-alpha.4**. As we are still in Alpha mode, some breaking changes can be expected. This version contains a substantial amount of breaking changes, so we do not recommend using older versions at this point. For questions about porting your project to this version, we recommend contacting us on [Discord](https://discord.com/invite/sNGPThMEc2).

## Get Started

We've put together some helpful guides for you to get setup with our product quickly and easily.

{% content-ref url="/pages/zq4W4tS82wJnMZPImp4Y" %}
[Getting set up](/v.1.0.0.alpha-4/fundamentals/getting-set-up)
{% endcontent-ref %}

{% content-ref url="/pages/U1eLsWuJFGe5wijj42kB" %}
[Hello Virtual World!](/v.1.0.0.alpha-4/fundamentals/getting-set-up/hello-virtual-world)
{% endcontent-ref %}

{% content-ref url="/pages/oLyKIgA4c83M3XydT4WX" %}
[Generator Stack Presets](/v.1.0.0.alpha-4/fundamentals/getting-set-up/generator-stack-presets)
{% endcontent-ref %}


# Getting set up

This page contains all the necessary information to install the Moonlander SDK.

<details>

<summary>Step 1: Download and Install Unity</summary>

This SDK requires you to have [Unity 2022.3.10f1](https://unity.com/download) installed on your system. At this moment, we do not actively support other Unity versions.

</details>

<details>

<summary>Step 2: Download the Moonlander Unity SDK and Content Packages</summary>

Download our [SDK and content packages](https://drive.google.com/drive/folders/1sLttSyPugbCeAyrWaDT-dCMU4ApjrbSw). Each release consists of three files: the SDK, the MoonlanderContent package, and the BoosterPack. You need the first two files to get started, but we highly recommend to install the BoosterPack as well. The BoosterPack gives you enough assets to create an interesting virtual world.

:warning:Warning! The assets in the **BoosterPack** **are not royalty-free**. They serve only as example material and they cannot be used on any public builds for commercial purposes or otherwise and cannot be redistributed.:warning:

</details>

<details>

<summary>Step 3: Make sure you have the credentials to get started</summary>

This SDK requires an SDK key to get access. If you haven’t received your SDK key, feel free to contact <bram@mnlndr.com>.

</details>

<details>

<summary>Step 4: Install the SDK!</summary>

To test and install the SDK, we recommend starting a new project. The SDK is made to work with the **3D (URP)** template, so select this template and give it a name.

Once the project is done loading, it is time to install the SDK:

1. Click on the *Window* menu and navigate to the *Package Manager.*
2. Press the plus sign, and click Navigate *Add package from Tarball.* ![](https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FC5tkxK6PVMIpi4kGN9Fq%2Finstall%20package.png?alt=media\&token=dd550c5f-5909-4974-8ca9-42b146793b25)

   ![](https://prod-files-secure.s3.us-west-2.amazonaws.com/9047f298-486b-4cd4-bf52-ae4516adc0b7/028cfdea-05c9-4f47-819d-2d8f6f02dd03/Unity_2023-10-17_12-33-40.png)
3. Open the *com.mnlndr.moonlander-1.0.0-alpha.4.tgz* package. This will install the Moonlander SDK.
4. **Enter your SDK License key.** This will give you access to the SDK!
5. You now have access to the SDK!

</details>

{% embed url="<https://youtu.be/_xVo-t_qNEA>" %}


# Hello Virtual World!

This page contains a guide to install the content packages, and to create your first AI generated virtual world.

Now that you have installed the SDK, it is time to start generating.&#x20;

<details>

<summary><strong>Step 1: Install the Content Package(s)</strong></summary>

To get started quickly, we provide a set of assets that you can use to test the functionality. Just drag the **MoonlanderContent.unity** package in the window, and it will install. If you want to create visually stunning worlds, install the **BoosterPack** as well.

</details>

<details>

<summary><strong>Step 2: Assign a Library of Assets</strong></summary>

Shapeshifter needs a Library of Assets to generate worlds. Go to the **Setup** foldout and select one of the Libraries.&#x20;

![](https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FHjkBCymHlI93FIzMSZDt%2Fassign%20library.png?alt=media\&token=4e107792-91c6-4d97-8f2c-10e3ebce4570)

</details>

<details>

<summary><strong>Step 3: Choose your first generator</strong></summary>

<img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FKBnigRNCfucB4h66Epgj%2Fgenerators.png?alt=media&amp;token=d4fa7191-308b-4dd4-8994-c59fb77d4488" alt="" data-size="original">

Now setup the generators for Shapeshifter to use. This can be done via the Generators window, which can be opened by clicking the "**Edit Generators**" button on the Shapeshifter overlay.

You can add generators through the "+" button at the top left of the Generators window. Pressed it, and then select "**Generator Stack** > **MoonlanderContentSampleGeneratorStack** from the dropdown menu.”

Now press **Generate** in the Shapeshifter menu, and you will generate your first world!

</details>

<figure><img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2F2UX0mknKDhooJa03ttQE%2FScreenshot%202024-01-04%20at%2011.07.20.png?alt=media&amp;token=98ee6a83-6d43-48d7-971d-538d816b6f76" alt=""><figcaption><p>A land generated by the <strong>MoonlanderContentSampleGeneratorStack</strong>, our Hello World! Example.</p></figcaption></figure>

{% hint style="info" %}
Each Library consists of a number of assets in the Library Manager. In order to create the world that you want, make sure you have assets that are related to that world. For example, to make a Desert terrain you need cacti, rocks, and the right textures.
{% endhint %}

Congratulations! You have now created your first AI generated Virtual World. Now let's go through the **Generator Stack**, to start building some visually appealing terrains!


# Generator Stack Presets

This page shows the Generator Stack Presets, the demo generations of Moonlander.

Generator Stack Presets provide a wide array of types of worlds that show the potential of the Moonlander SDK. You can use these as a starting point and a point of reference. You need the BoosterPack to generate these examples yourself.

{% hint style="info" %}
The Generator Stack Presets are fully configured, this means that all the assets are already loaded. As a result the prompting is disabled. In order to use Text Prompting, please refer to [PromptableTemplate](/v.1.0.0.alpha-4/fundamentals/getting-set-up/promptabletemplate)
{% endhint %}

***

## CandyLand

<figure><img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FTSrVIMdArYisi4il4PTi%2FScreenshot%202023-12-07%20at%2018.27.46.png?alt=media&amp;token=2042f5a5-3b5f-48dc-b0c6-ea08f57b3db4" alt=""><figcaption><p>CandyLand is a low poly cartoon candy styled scene, suitable for both Mobile and PC. </p></figcaption></figure>

## DesolateDesert

<figure><img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FBmemq6bDfUnRPL491Gij%2FScreenshot%202023-12-07%20at%2017.47.05.png?alt=media&amp;token=1d8f5297-cbf4-428f-9369-f0fee265ad13" alt=""><figcaption><p>A high quality nature pack, ideal for creating post-apocalyptic or Wild Wild West games. Vegetation very similar to what grows in Arizona and (New) Mexico.</p></figcaption></figure>

## LushForestPath

<figure><img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FptSNOpHPlfTba4UqGCwr%2FScreenshot%202023-12-07%20at%2016.19.30.png?alt=media&amp;token=cdc07d5f-0cef-4f8c-8d75-5c2b497fc3ce" alt=""><figcaption><p>LushForestPath offers a vivid world of dense greenery and enchanting trails, perfect for fantasy realms or serene woodland scenes. Immerse players in the beauty of a lively forest with towering trees, meandering streams, and captivating flora.</p></figcaption></figure>

## MushroomForest

<figure><img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2Fe4Wc5HZ4WaZxDiyrFe9j%2FScreenshot%202023-12-07%20at%2018.01.28.png?alt=media&amp;token=92c9a773-54fb-4424-aca7-07e86074758e" alt=""><figcaption><p>Meadow grass, pine trees, and a wide array of mushrooms make this terrain perfect for European forests and other temperate climates.</p></figcaption></figure>

## StylizedTrees

<figure><img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FyMZyk43cG8h7SCYGeOgN%2Fstylized.png?alt=media&amp;token=eabf4c5b-1019-47ee-9665-66067ca80585" alt=""><figcaption><p>StylizedForest combines realism with artistic flair, offering a visually striking environment for various game genres. Immerse players in a stylized rendition of nature, with meticulously crafted trees, rocks, and streams to enhance the overall gaming experience.</p></figcaption></figure>

## TropicalIsland**Archipelago**

<figure><img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FWImfuoiEeRbcvRmwj06B%2FScreenshot%202024-01-11%20at%2022.40.47.png?alt=media&amp;token=53e876be-d90e-4b5e-8562-610a7bbb2938" alt=""><figcaption><p>TropicalIslandArchipelago unveils the beauty of interconnected islands surrounded by azure waters. Perfect for open-world environments or sea-faring adventures, the pack features lush landscapes, diverse flora, and the allure of tropical exploration on each captivating island.<br></p></figcaption></figure>


# PromptableTemplate

In this page we explain the PromptableTemplate, the generator stack that allows users to use a text interface for the world creation.

While the [Generator Stack Presets](/v.1.0.0.alpha-4/fundamentals/getting-set-up/generator-stack-presets) look very pretty, the real fun is making your own custom worlds of course! The easiest way to get started with your custom worlds is with the **PromptableTemplate**, as it is already preconfigured to listen to your text prompts. Besides that, the generator settings are set in a default way that works well with different types of terrains.

With the PromptableTemplate you can load assets through the text prompting interface. By typing a list of assets that you would like to see, Shapeshifter will create generators (and terrains) that will resemble your input.

{% hint style="info" %}
As of now, prompting works only for loading the right assets! **V1.0.0-alpha.5 will contain much more sophisticated prompting**, like creating the generator settings as well. Please stay tuned!
{% endhint %}

## Getting Started

First, make sure your asset library has the type of assets that you are looking for. You can also wait for the terrain to generate, but **if you prompt palm trees without having them in your library, you won't see any**. Luckily, the BoosterPack will consists of a good variety of assets to start out with.&#x20;

{% hint style="info" %}
You can also use your own assets of course. In that case, make sure the assets have the right metadata by using our [Asset Tagging](/v.1.0.0.alpha-4/explore-topics/library/asset-tagging).&#x20;
{% endhint %}

Now, let's get generate your first custom world! You can follow this example to see how it works:

<details>

<summary><strong>Step 1: Load the BoosterPack library in Shapeshifter and select the</strong> PromptableTemplate <strong>in the Generator Stack</strong></summary>

<img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FoJMIXtdGAT4vMfybbegN%2FScreenshot%202024-01-04%20at%2014.18.39.png?alt=media&amp;token=cb47df90-cf66-4f35-bef8-a8bae276db5a" alt="" data-size="original">

In the Shapeshifter **Setup**, select in **Library** the **BoosterPack**. Then, press **Edit Generators** if you don't have the Generator page in view. Then, select the **Generator Stack** and select the **PromptableTemplate** in the list:

<img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FFZwI1gAkoxqhcZYyqbny%2FScreenshot%202024-01-04%20at%2014.20.55.png?alt=media&amp;token=dc3abcc2-5d0a-48d5-8ce4-589abc9915ba" alt="" data-size="original">

</details>

<details>

<summary>Step 2: Write a prompt to load assets, like "Cacti, meadow, sunny, mushrooms, giant rock<strong>"</strong> </summary>

<img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FcrCM4mN0TDBk3LNrF4p0%2FScreenshot%202024-01-04%20at%2014.24.58.png?alt=media&amp;token=8bae70bb-eb0f-4c95-8ac0-ad6e6bc60af1" alt="" data-size="original">

</details>

<details>

<summary>Step 3: Press Generate Area and create your terrain!</summary>

Shapeshifter will now look through your **Asset Library** to find related assets and spawn them.

</details>

## Inspecting your new generator

<figure><img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FEK85kM7AXICRxaoyUP6G%2FScreenshot%202024-01-04%20at%2014.26.52.png?alt=media&amp;token=b20bd45f-a106-44ea-89af-9681d245ef12" alt=""><figcaption><p>A world generated with the prompt: "Cacti, meadow, sunny, mushrooms, giant rock<strong>".</strong></p></figcaption></figure>

Now that your world is generated, you can start iterating your world by inspecting the generators. This will give you insights in which assets were loaded, and allow you to change the scene a bit. The **PromptableTemplate** have a few generators loaded, and several of them have an asset loader in place.  Let's take a look of a few of them:

### ObjectPlacementGenerator

The Flowers generator is an ObjectPlacementGenerator responsible for finding flowers. As you can see, the generator has found several cacti to place! The same goes for the Scattered Objects Generator, both mushrooms and rocks were found.

<div><figure><img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FhC73hNm6xzYkRthbN7Le%2FScreenshot%202024-01-04%20at%2014.35.29.png?alt=media&amp;token=fbe618f4-e112-4aa4-9c6b-608859e977ed" alt="" width="301"><figcaption><p>Flowers generator</p></figcaption></figure> <figure><img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FPzb5hfC6QIx6ZM86xtg3%2FScreenshot%202024-01-04%20at%2014.39.32.png?alt=media&amp;token=894a738f-c069-4976-8039-d34fdeb49637" alt="" width="196"><figcaption><p>Scattered Objects generator</p></figcaption></figure></div>


# High Level Overview

This page describes all the high level concepts of the Moonlander SDK

If you have followed the fundamentals in [Getting set up](/v.1.0.0.alpha-4/fundamentals/getting-set-up), you have already touched all the important components of Moonlander. When you look at the Shapeshifter overlay, you will see all of them in one user interface:

<figure><img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FI3IptSO3XHbxfzf1jWHK%2FScreenshot%202024-01-10%20at%2017.13.16.png?alt=media&amp;token=e3ca8bc1-a823-41e9-88ab-e1920693b02e" alt=""><figcaption><p>A screenshot of the Shapeshifter, the Overlay that ties all important Moonlander concepts together: Text Prompting, the Library, and Generators</p></figcaption></figure>

1. **Text Prompting** (optional). The text prompting interface allows you to set the sky, lighting, and which assets to use from your library. In the next iteration the text prompting interface will be able to generate terrains as well.
2. [Library](/v.1.0.0.alpha-4/explore-topics/library). The Library stores all your 3D Assets, Skyboxes, and Terrain Textures. When you generate a terrain, Shapeshifter will look into your Library to find everything it needs to generate a terrain to your liking. So the better your Library, the better your worlds! We have provided a BoosterPack with a lot of Assets to start out with, but we highly recommend in creating your own Library as well.
3. [Generator](/v.1.0.0.alpha-4/explore-topics/generator). A Generator is a Base Class that instructs Shapeshifter how to build up the scene. All your Generators together are called the Generator Stack, which consists of several types of Generators. The Generators are highly customisable, so knowing all the different settings are crucial for creating a virtual world exactly how you would like.

Since we have already covered the Text Prompting in [PromptableTemplate](/v.1.0.0.alpha-4/fundamentals/getting-set-up/promptabletemplate), let's quickly move to the [Library](/v.1.0.0.alpha-4/explore-topics/library)!


# Library

This page describes the purpose and basic functionality of the Moonlander library

The Library is a scriptable object file that contains all the assets separated into properties like *3D Assets* for the prefabs, materials for the *Skyboxes*, and *Terrain Textures* for the Unity Terrain Layers. Furthermore it serves as a repository for all your custom properties, for example prefabs linked to custom mechanics.


# Asset Tagging

Assets need the right metadata to make sure they can be placed by Shapeshifter. To do this, go to the Asset Library and navigate to the assets in your library.&#x20;

<figure><img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2F9x5DUsOF4cFsgvbxxeC4%2FScreenshot%202024-01-04%20at%2014.54.41.png?alt=media&amp;token=7c280570-8c0a-4d9a-a78b-3c5d93648d42" alt=""><figcaption></figcaption></figure>

Select the assets that you want to tag, and click Auto-Tag. This will then send the assets to our server, and return the right metadata back. You can also manually configure the tags if you want.


# Generator

This page describes what a Generator is and how they shape your scenes

Generators define how the scene is built up, what objects are spawned and the the rules of placement of objects on the terrain. Every scene that you will build with Moonlander consists of several generators, each responsible for a different component in your scenes. All generators combined in your scene is called your Generator Stack.

There are two types of Generators: the [Global Generator](/v.1.0.0.alpha-4/explore-topics/generator/global-generator) and the [Bounds Generator](/v.1.0.0.alpha-4/explore-topics/generator/bounds-generator). You can define global settings through Global Generators and define the placing of objects and creation of Unity terrains through the Bounds Generator.

Each Generator consists of two tabs:

* Properties. The properties tab consists of all settings that make up this generator. Some Generators are very simple, while others can be very complex.
* Dependencies. In this tab, you can see the links between generators. The Input lists the Generators to which the current Generator listens, the Output lists the Generators that have the current Generator as Input. For more information see [DataRegistry](/v.1.0.0.alpha-4/explore-topics/dataregistry).

{% hint style="info" %}
Dependencies are key for building scenes that make sense. For example, you don't want to have your vegetation to grow on your roads! Linking your road generator with your foliage generator can quickly solve this issue.
{% endhint %}

####


# Global Generator

Global generators are generators that create global settings and affect the entire scene.

&#x20;There are several types of global generators:

* [MapGenerator](/v.1.0.0.alpha-4/explore-topics/generator/global-generator/map-generator): a Generator that creates a 2D data file that can be used for Terrain Height, Object Density, Texture, and many more.
* [TerraformerGenerator](/v.1.0.0.alpha-4/explore-topics/generator/global-generator/terraformergenerator): a Generator that can allows you to customise the scene, for example the weather effects and overall style.
* [SkyShaperGenerator](/v.1.0.0.alpha-4/explore-topics/generator/global-generator/skyshapergenerator): a Generator responsible for setting the Skybox and the Directional Light
* [ColorGradingGenerator](/v.1.0.0.alpha-4/explore-topics/generator/global-generator/colorgradinggenerator): a Generator that allows you to post process effect colours


# Map Generator

A Map Generator is a generator to create important components of the landscape, like roads, the height of the terrain, and its steepness.&#x20;

####


# TerraformerGenerator

TerraformerGenerator is a Global Generator that links the the shaders and the textures and the sky of the whole scene. Terraformer allows you to mix and match these shader effects to create a distinctive visual style that sets your game apart from the rest. The TerraformerGenerator is the centralised generator for control over your scene.

{% hint style="info" %}
In order to use the functionalities of TerraformerGenerator all materials need to have the [Multi Shader](/v.1.0.0.alpha-4/explore-topics/multi-shader) assigned.
{% endhint %}

#### Foliage Amount

With Foliage Amount, you can override the Alpha Clipping of your foliage. The higher this setting, the sparser the foliage will be.&#x20;

#### Top Weather Cover

Top Weather Cover allows you to apply Terrain Texture Assets to the assets placed by your ObjectPlacementGenerators. You can use this to cover your entire scene in snow.

#### Top Texture Cover

Top Texture Cover allows you to apply Terrain Texture Assets to the assets placed by your ObjectPlacementGenerators. You can use this to cover your scene with wild grass.

{% hint style="info" %}
The Top Weather Cover and Top Texture Cover are very similar, but there are small differences. The former also covers trees and stones, while the latter doesn't. If you enable both, the Top Texture Cover will be applied first and the Top Weather Cover will be applied afterwards.
{% endhint %}

#### Outline

Outlines will give your assets an outline with a custom color and thickness, which gives your scene a unique style.

#### Toon Effect

The Toon Effect submenu provides you options to create a visual style for your assets to make it look more cartoonish or animated.

#### Color Palette

The Color Palette allows you to set a base, first, and second color for your scene. This is useful for example when you want to change your scene to the Fall, or Summer. It will overlay a color based on the position of the terrain. So the position of an object determines which tint of color it picks. Color Palettes can create a lot of looks and styles for your scenes.

#### Wind Effect

The Wind Effect allows you to create wind behaviours that affect your foliage.&#x20;


# SkyShaperGenerator

This page describes the role of the SkyShaperGenerator and the several ways to create a Skybox

SkyShaperGenerator is a Generator that is responsible for generating a Skybox and the Directional Light. There are two ways to generate a Skybox through the SkyShaperGenerator:

1. Through the [Asset Loader](/v.1.0.0.alpha-4/explore-topics/asset-loader).
2. By manually selecting a Skybox from your [Library](/v.1.0.0.alpha-4/explore-topics/library)

Besides selecting a Skybox in the SkyboxGenerator, you can also create one through prompting a Skybox in the [AI Skybox Generator](/v.1.0.0.alpha-4/explore-topics/ai-toolkit/ai-skybox-generator).


# ColorGradingGenerator

This page describes the ColorGradingGenerator and its use cases.

ColorGradingGenerator is a post process effect for color grading the image after rendering. This can be a useful generator for example when you want to create a cartoony game. When you select a ColorGenerator profile, it will spawn a Color Grading object in your hierarchy. This will allow you alter the color grading.&#x20;

<figure><img src="https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FPUqpd5zKZl8oWtRKCx2T%2FScreenshot%202024-01-11%20at%2021.00.39.png?alt=media&amp;token=f4c070ef-350a-4b77-a444-39bf60c28907" alt=""><figcaption></figcaption></figure>


# Bounds Generator

Bounds Generators are Generators that have the size of the bound of your terrain and operate within that scope.&#x20;

* [TerrainGenerator](/v.1.0.0.alpha-4/explore-topics/generator/bounds-generator/terraingenerator): A Generator that grabs height information from a layer stack
* [ObjectPlacementGenerator](/v.1.0.0.alpha-4/explore-topics/generator/bounds-generator/objectplacementgenerator): A Generator that places 3D Assets in your terrain
* [PlaneGenerator](/v.1.0.0.alpha-4/explore-topics/generator/bounds-generator/planegenerator):  A Generator that spawns the prefab&#x20;


# ObjectPlacementGenerator

ObjectPlacementGenerator is a generator that spawns objects on your terrain.  With each ObjectPlacementGenerator you can select the types of assets that you want to load, to which other terrain behaviour it should listen, and how they should orient. Furthermore the ObjectPlacementGenerator can set the Rendering and Collision for you.


# PlaneGenerator

A PlaneGenerator spawns a prefab the size of the bounds at the given height. This is mainly used for water, oceans, lava, or similar objects.


# TerrainGenerator

A single generator that generates a terrain for you.

Height Layers: Edit Layers

Terrain Layer Data:


# Multi Shader

This page describes how Multi Shader works and how it can be used to customise your assets

The Multi Shader is a custom Shader you can assign your materials to to function for [Terraformer](/v.1.0.0.alpha-4/explore-topics/generator/global-generator/terraformergenerator) and conforming objects to the terrain in [ObjectPlacementGenerator](/v.1.0.0.alpha-4/explore-topics/generator/bounds-generator/objectplacementgenerator). With Multi Shader you can quickly apply terrain customisation to your materials.

{% hint style="warning" %}
Warning! The Multi Shader will overwrite the files of the Materials that you convert, so be careful of which Materials you use. When testing, make sure you have a backup of your materials before converting.
{% endhint %}

You can convert your own materials as follows:

<details>

<summary>Step 1: In the menu, go to MoonlanderSDK > Terraformer > Multi Shader Converter.</summary>

![](https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FPe005e4a8wGH1iRhK6tz%2FScreenshot%202024-01-11%20at%2021.55.29.png?alt=media\&token=c719bb5c-826f-4e0d-bc84-5f5bb413d677)

</details>

<details>

<summary>Step 2: Move a material file (.mat) to the Multi Shader Converter and press 'Convert Materials'.</summary>

![](https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FKjlf7kBjmDp5FnPcXeis%2FScreenshot%202024-01-11%20at%2021.58.26.png?alt=media\&token=6781d2ef-5061-4359-b17a-069a24d3f6e4)

This will convert your material to a Multi Shader. You can now modify your assets with [TerraformerGenerator](/v.1.0.0.alpha-4/explore-topics/generator/global-generator/terraformergenerator) and [ObjectPlacementGenerator](/v.1.0.0.alpha-4/explore-topics/generator/bounds-generator/objectplacementgenerator).

</details>

<details>

<summary>Step 3: Test if your new materials have been converted!</summary>

Move your asset to the scene and hover zoom in on the asset. Now add some Snow in the Top Weather Cover of the [TerraformerGenerator](/v.1.0.0.alpha-4/explore-topics/generator/global-generator/terraformergenerator). If everything works correctly, you should be able to see snow on your scene.

![](https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2FoBeLbRRNzmx1tEJ6hdY5%2FScreenshot%202024-01-11%20at%2022.08.05.png?alt=media\&token=a9de4400-79f7-446e-ad04-e6661cdfc2ee)![](https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2F1qQhnSRYfK04iN9agxQI%2FScreenshot%202024-01-11%20at%2022.08.50.png?alt=media\&token=4882b2b7-2fcf-410e-b426-39bfd09b6274)

![](https://791121862-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUTEH16mxQKIQde6BlaH2%2Fuploads%2F0DZhVpXln24W1z0cBESy%2FScreenshot%202024-01-11%20at%2022.12.59.png?alt=media\&token=2b9c5239-7cf3-472d-9ab1-7344b72081d6)

</details>


# DataRegistry

DataRegistry is a collection that link generators to each other. This is a powerful tool in the creation of your terrains, as this makes it possible to depend the behaviour of terrain elements on other elements. For example, it makes sense to add Mushroom objects only on the grass and not on the road. With a DataRegistry this becomes trivial.


# Layers

This page describes the layer functionality that you can find in many Generators.

If you go to the *edit layers* section, it will spawn a photoshop like editor that allows you to the height map. There are several types of (sub)layers:

* GroupLayer: Group Layers allow you to combine a set of layers together.
* PresetLayer
* DataRegistryLayer:&#x20;
* NoiseLayer: A layer that generates a noise field. The noise layer consists of several properties:

  * Type: the noise type, where you can choose between perlin, simplex, and cellular:
    * Perlin: Smooth, continuous noise with realistic-looking textures due to its smooth transitions between values
    * Simplex: Same as Perlin but computationally cheaper.
    * Cellular: Generates a pattern of cells in space, often used for irregular and diverse patterns. A good example of cellular is when you want to generate dunes.
  * Offset: This parameter allows you to shift the entire noise pattern in the x and y dimensions, influencing how the pattern aligns with the coordinates of the space it occupies.
  * Octaves: individual layers or iterations of noise that contribute to the overall pattern.
  * Persistence: controls how quickly the influence of each octave diminishes, affecting the prominence of details.
  * Lacunarity: determines the rate at which the frequency of octaves changes, influencing the diversity and complexity of the overall texture.

  Besides the properties, the NoiseLayer also has several filters:

  * Steepness filter: creates a data set for the steepness of the terrain. By taking the steepness filter over a terrain, you would get a darker value the steeper it gets. The filter takes its samples from its neighbouring pixels and calculates the angle from every pixel. This is useful for how when you will spawn in the grass, for instance, that it will follow the lines of the terrain or for wherever you want to use it for.
  * Invert filter
  * Curves filter
  * Levels filter

A layer that generates a noise field

* UniformLayer: A solid value. Useful as a base to mix with other layers and to create constant features.


# Asset Loader

This page describes the working of the Asset Loader


# AI Toolkit

The AI Toolkit is a collection of AI powered services that will speed up &#x20;


# AI Color Palette

This page describes the working of the AI Color Palette to customise your assets

The AI Color Palette is a feature that turns the description of your landscape into a Color Palette. You can use this as input of your [TerraformerGenerator](/v.1.0.0.alpha-4/explore-topics/generator/global-generator/terraformergenerator#color-palette) in your [TerraformerGenerator](/v.1.0.0.alpha-4/explore-topics/generator/global-generator/terraformergenerator). To open the AI Color Palette, navigate to the MoonlanderSDK in your Unity Window, and click AI Toolkit > AI Color Palette.

You can then type in a scenario or mood of your palette, and select the number of colors you would like to receive.

{% embed url="<https://www.loom.com/share/1696a1578d254d919a4352963895e8b3>" fullWidth="false" %}


# AI Skybox Generator

This page describes the AI Skybox Generator and how to apply them to your scene

{% embed url="<https://www.loom.com/share/1c1d1142f171403490a729472463e02b>" %}


