Profile image

[Mod|Map|SimplePlanes] Your first map - page 1

316k mikoyanster  6.0 years ago

Hello everyone, in this article I will try to explain the basics to design a simple map in SimplePlanes. In subsequent articles I will explain how to improve it, and create more advanced or complex maps.

The first step is to install the Unity program and its complements, as indicated in the following article. https://www.simpleplanes.com/Forums/View/729515

Step 1. Create a new project

Once we have Unity installed correctly, the next step is to open Unity, register and create our first project. In this case, we will give it the name "myfirstmap"

img1
fig.1 Click new project

img2
fig.2 Name your project and create it

Step 2. Recognition of the Unity screen

Before starting to work on the map, it is important to recognize the main functions of Unity and the location of its options, to facilitate all our work.

img3
fig.3 Unity screen

First of all we observe a top bar with the following menu options: File, Edit, Assets, GameObject, Component, Window, Help.

  • The "File" menu allows you to save our project and the scenes in which we are working, within this project. This means that by default, when we create a project, a main scene is created on which we will work.

  • The "Edit" menu allows you to perform predetermined tasks such as copy, paste, undo, delete, duplicate. It also has playback control options if we design kinematics with Unity.

  • The "Assets" menu is very important, since it allows you to import new functions, tools, elements, objects and resources to our Unity editor. For example, from here you import the toolkit for SimplePlanes, for modeling the terrain, etc. On the other hand, it also allows developers of programming languages C, C-Sharp, Javascript ... to elaborate routines that influence the game or the map.

  • The "GameObject" menu is also important, since it will allow us to introduce any type of object we need into our map. For example the main geometric figures (cube, cylinder, sphere, capsule,...), terrains, lights, text, audio, triggers, particles, cameras,...

  • The "Component" menu allows to edit the components or properties of the objects that are introduced in the scene of our project. However, it is not used directly, since its properties can be modified from the "Inspector", which is the details window for any object that we select in the scene.

  • The "Window" menu allows you to change the organization of all open windows in Unity. However, I do not recommend modifying it if you still do not know the program well. By default, the configuration is optimal and in few occasions we will resort to this menu.

img4
fig.4 Hierarchy of objects in the scene

The figure 4 shows the window of hierarchy of objects in the scene. It is important that as we create our map, all objects such as terrains, 3D objects that we import, ships, convoys, etc., will be displayed here. It will be important to group and sort them, in order to manage them properly, as well as edit their properties and see them selected in the Unity preview screen.

img5
fig.5 Preview window of the scene

In figure 5, we have the window dedicated to preview the scene. We will interact a lot with this window, since it allows us to move along the map that we are going to create in the infinite space. At the same time 3 tabs will be observed. The first one that is already selected, called "Scene", that shows us the plane of the scene. The second called "Game" that presents the view in game mode (In our case it is not used). And the third tab called "Asset Store" that opens the Unity assets web page, in which you can find all kinds of resources that will be useful to develop our mods. These assets are of all kinds and although many are free, others are paid. This will lead us later to the problem of getting the essential assets to work well in our SimplePlanes environment.

img6
fig.6 Asset searcher and error console

In relation to figure 6, sometimes it can be useful to find an asset, or locate an object that we know is inserted in our scene, but we do not find it easily (This happens when our map is very complex). For this we use this search engine. On the other hand, it has an error console where we will see what failures Unity gives when working, processing, compiling, etc. They are many, but do not be afraid.

img7
fig.7 Basic operations on the scene

Around figure 7, this group of tools allows you to carry out basic operations on the scene previewed in the central window. For example, the "hand" allows moving over the space left-right, up-down. The wheel of your mouse allows you to control the depth, therefore, to zoom in or out. The "cross of arrows" allows to move the selected object in the scene. The "arrows in circle" allow you to rotate the selected object. The "box with arrows at the ends" allows you to scale a selected object, without losing its ratio.

img8
fig.8 Inspector tool

The inspector tool allows you to observe, modify or edit the properties of any selected object. It is very important for our work.

Step 3. Import the basic assets that we need

There is an essential "asset" to create SimplePlanes mods. It is the SimplePlanes asset that is available in the following link http://www.simpleplanes.com/ModTools/SimplePlanes_ModTools.zip.


Note

You can also find it more updated (If you downloaded and install the game from Steam), in the following path C:\Program Files (x86)\Steam\steamapps\common\SimplePlanes\ModTools. In this location you find two packages 1) SimplePlanesModTools.unitypackage, 2) SimplePlanesModTools_Assets.unitypackage. Import all packages following the instructions.


If download this file you will need to unzip it and get the file SimplePlanes_ModTools.unitypackage. Save it to your SimplePlanes resource folder. Once done, import this asset using the menu Assets --> Import Package --> Custom Package ...

img9
fig.9 Import asset package

A window will open to select the file you want to import. Import it and you will get the result shown in figure 10.

img10
fig.10 Importing SimplePlanes ModTools Asset

Unity will always show you in a table the components of the asset that you are going to import, allowing you to even mark those contents that you want and those that do not. In this case we import everything and click on the Import button. Once imported, we will observe that the top menu includes a new option called SimplePlanes, as shown in figure 11.

img11
fig.11 SimplePlanes ModTools installed

To use the SimplePlanes tools in Unity it is essential to open the Mod Builder Window and anchor it next to the inspector tab, as shown in the following figure 12.

img12
fig.12 Mod Builder Window anchored next to the Inspector tool

If you have never anchored a menu, it is very simple. The floating window (Popup) that you will get, you will have to drag it next to the tab Inspector and drop it. That is all. The SimplePlanes ModTools package includes the essential elements to work with. These are the environments to create maps, designers, custom parts, objects such as ships, bridges, vehicles, ground defenses and even the AI of other aircraft. On the other hand, the window SP Mod Builder that we just anchor, will allow us to name the mod, indicate the author or authors, the version, brief description or briefing of the map or mission, and the description fields to share the mod through Steam.

Step 4. Editing the basic information of the Mod

Our first task will be to fill in the basic information of the map-mod that we are going to create. For this we go to the tool SP Mod Builder and complete all the fields.

img13
fig.13 Editing the basic information of the mod

Once this is done, we click on the Start creating mod button and this will enable all the functions of SimplePlanes ModTools, which are the following: a) Save Selected Scene Objects that allows to select all the objects of the scene that you want to save in the SimplePlanes mod you are preparing. (In fact, to be able to generate the mod, it is necessary to save all the objects that have been introduced in the scene, as we will see later), b) Save Selected Assets that will allow you to save those objects that have been selected, c) Reset All To delete the saved items for SimplePlanes ModTools (This does not mean that you permanently lose them, since they will still be available in the hierarchical list on the left.It means that for the purposes of the Mod of SimplePlanes, they are deleted).

img14
fig.14 New options available

d) Save Mod - Steam Workshop Allows you to save the mod in the Steam Workshop network so that any user can download it from there, e) Save Mod - PC Generates the Mod file or package for the game on PC, f) Save Mod - Android General file for the Java / Android environment, for the game on tablets and mobile phones.

Step 5. Editing the map

To edit a SimplePlanes map, the first thing we will do is eliminate the lights and cameras that appear by default in our hierarchical list of objects. These are not needed now and will help us focus on what's important. Now follow the following points:

1) Create a SimplePlanes map To do this, select the menu SimplePlanes --> Game Objects --> Map This will automatically create a Map object that must contain all the elements of our map, from hereafter.

img15
fig.15 Creating a SimplePlanes map

2) Create the terrain The terrain is the appropriate object to create our island (or continent). To generate it we will have to select the menu GameObject --> 3D Object --> Terrain

img16
fig.16 The first terrain

3) Uncheck Static option of the terrain This is the most important step when working with terrain. Select the terrain, which by default takes the name Terrain then selects the tab of the inspector tool to edit its properties. You will notice that there is a box marked, called Static. It is essential to uncheck it to avoid that the Unity program consumes all the resources of your computer to render the terrain. Otherwise, publishing a Mod can take many hours instead of a few minutes.

img17
fig.17 Unmarking the checkbox of death (Static checkbox)

4) Configuring the terrain One of the most complicated issues of working in SimplePlanes is the configuration of the terrain parameters. This is because they can be modified with great freedom and it is not known with precision, what are the maximum values accepted by SimplePlanes to generate high quality and detailed terrains. However, we know what the recommended values are, which they use in the game's maps. For example on Wright Island the following configuration is used.

img18
fig.18 Wright Island terrain configuration


Note

These are the fundamental parameters for editing terrains. You can find a complete description in the following link of the Unity manual https://docs.unity3d.com/en/current/Manual/terrain-OtherSettings.html

  • Pixel Error. This value affects the precision of the textures of the terrain in its rendering. Higher values indicate lower precision but lower rendering overload. I recommend leaving in the default values. However if we have very large maps (Above 15000x15000) maybe a higher pixel error is required.

  • Base Map. Dist. This value is important, especially in maps whose terrains have high resolution textures. This is because the textures of the terrain will be displayed in low resolution if it exceeds the distance indicated in this value. @MisterT reflects this problem very well, inherent in Unity limits. However, he found a solution to visualize the texture with the highest quality, without limits of distance, read this post https://www.simpleplanes.com/Forums/View/846990. Unfortunately this solution only applies ingame, in your developer console, not in the mod. For this reason, it seems advisable to design maps that do not involve exceeding the maximum limits of Base map dist. Based on my experience, I recommend a distance between 1000 and 2000 depending on the quality of the textures. Higher the resolution, greater is the distance. Also depending on the size of the map. Larger the size, greater is the distance. Probably it all comes down to a problem of the resolution of the textures and the size of the map. It will require different tests of the mod, until specifying the appropriate value for each case.

  • Terrain Width. Size of the terrain object on its X axis. The limit of a terrain in Unity is approximately 50000x50000. I have done tests and above this value, the terrain becomes very difficult to manipulate. However, the larger the size, the lower quality and resolution the terrain will have and the more problems Base map dist will have. In the mods that I have made, I have verified and ratified that the value 15000x15000 is the most appropriate. It has a sufficiently large size, and is at the limit to avoid problems of visualization of the details of the terrain. However, as the size of the land is smaller, better qualities and details you can have on your map. In spite of everything, there may be modders who want much larger maps ... of continental size. In that case, I would recommend creating many terrain objects with a maximum size of 15000x15000. We will explain in another tutorial, how to elaborate continents with good quality.

  • Terrain Length Size of the terrain object on its Z axis. What is indicated for the Terrain Width parameter is applicable to Terrain Length.

  • Terrain Height The difference between the Y coordinate between the lowest possible heightmap value and the largest. The height of the terrain is important, to generate mountains and an orography of the terrain in the future. That's why I recommend a value that varies between 3000 and 5000.

  • Heightmap Resolution Resolution in pixels of the terrain heightmap (it must be a power of two plus one, for example, 513 = 512 + 1). This parameter will determine the quality of the texture that is applied in the terrain, specifically in the slopes of the mountains, valleys, canyons, etc. I recommend values that vary between 1024 and 2049. This varies depending on the height of the map. Higher is the height, higher is the resolution, proportionally.

  • Detail Resolution The resolution of the map that determines the patches. A higher resolution gives smaller and more detailed patches. I recommend values between 512 and 1024. Higher resolutions can cause lags in the game.

  • Detail Resolution Per Patch The length/width of the square of patches rendered. I recommend using the default value 8 for an 8x8 patch. If smaller patches are used, in theory a better resolution is obtained but it will cause a greater use of graphics card to render. If it is greater, for example 12x12 the level of detail of the texture will be less but it will cover more ground and it will load better. In any case I recommend the default value 8.

  • Control Texture Resolution The resolution of the splatmap that controls the mixing of different terrain textures. This is important for the resolution between the overlay / mix of various textures will be adequate. Its value should be equal to the parameter Detail Resolution.

  • Base Texture resolution The resolution of the composite texture used in the terrain when viewed from a distance greater than Basemap Distance. its value, is usually twice the parameter Detail Resolution.


Taking into account all these changes, the configuration of our first map is as follows, see figure 19. Once the terrain is configured, do not forget to drag it and move it inside the main object of the Simple Planes Map, as shown in figure 20. Remember that all the objects must be inside Simple Planes Map to be loaded correctly in the mod.

img19
fig.19 Configuration of our terrain

img20
fig.20 Drag and drop the terrain object into the Simple Planes Map object


Go to the page 2


  • Log in to leave a comment
  • Profile image
    22.1k longanbieu

    @owenliu where can you find tree and delete it

    one year ago
  • Profile image
    1,795 GuevanGroup

    where do i get modtools

    +1 1.8 years ago
  • Profile image
    30.0k 32

    Good Stuff. Too bad the tutorial was never completed.

    1.8 years ago
  • Profile image

    Hello ths is quite hard for me but can u please make a grid map mod for mobile and pc

    3.7 years ago
  • Profile image

    @owenliu Wow! Great! Thanks for share the problem

    4.1 years ago
  • Profile image
    2,587 owenliu

    @mikoyanster I solved the problem. There's something wrong with speedtree and it worked after I deleted all trees.

    +1 4.1 years ago
  • Profile image

    @owenliu I think it is better to ask someone from Jundroo, the truth is that I do not know how to solve that problem... Sorry

    4.1 years ago
  • Profile image
    2,587 owenliu

    @mikoyanster I think it's the problem with modtools because this message showed up only 3 seconds before the error:
    Saving mod(20:51:49): C:/Users/davor/AppData/LocalLow/Jundroo/SimplePlanes/Mods/Japari Park.spmod
    UnityEngine.Debug:LogFormat(String, Object[])
    Jundroo.ModTools.Editor.ModBuilderWindow:CompleteAndSaveMod(ModTargetPlatform, Boolean)
    Jundroo.ModTools.Editor.ModBuilderWindow:OnGUI()
    UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)
    It seems that modtools forgot to close the "OnGUI".
    (just a guess, I know nothing about Unity programming)

    4.1 years ago
  • Profile image

    @owenliu I think is problem of Modtools... mmm or GUIClips... sorry but i dont´t remember what is GUICLIps. Take a look about GUIclips error... mmmm

    4.1 years ago
  • Profile image
    2,587 owenliu

    @mikoyanster I tried but the problem still exist.

    One or more errors occurred building the mod: (10:09:25): GUI Error: You are pushing more GUIClips than you are popping. Make sure they are balanced.
    GUI Error: You are pushing more GUIClips than you are popping. Make sure they are balanced.
    UnityEngine.Debug:LogErrorFormat(String, Object[])
    Jundroo.ModTools.Editor.ModBuilderWindow:BuildAndSaveProjectAssemblies(BuildTarget, Boolean)
    Jundroo.ModTools.Editor.ModBuilderWindow:BuildAssetBundle(BuildTarget, Boolean)
    Jundroo.ModTools.Editor.ModBuilderWindow:BuildAssetBundles(String, BuildTarget[], Boolean)
    Jundroo.ModTools.Editor.ModBuilderWindow:CompleteAndSaveMod(ModTargetPlatform, Boolean)
    Jundroo.ModTools.Editor.ModBuilderWindow:OnGUI()
    UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

    This message appeared after the window which said "copying files to final destination" closed.
    Maybe there's problems with my textures?

    4.1 years ago
  • Profile image

    @owenliu I have Unity 2018.3.8f1 (64bit) and work perfectly, and this version of Modtools

    4.1 years ago
  • Profile image
    2,587 owenliu

    @mikoyanster Thanks!

    4.1 years ago
  • Profile image

    @owenliu ok this is the problem you must use other versión of modtools. I Will Yale a look the exact versión and share with you. No problem. When i regret to home, answer your question

    4.1 years ago
  • Profile image
    2,587 owenliu

    @mikoyanster I'm using Unity 2019.4.8f1 which is recommended by the latest version of modtools.

    4.1 years ago
  • Profile image

    @owenliu probably Will be the versión of Unity or modtool.. what versión is It?

    4.1 years ago
  • Profile image
    2,587 owenliu

    How to solve this problem?

    One or more errors occurred building the mod: (15:26:50): Error building Player because scripts have compile errors in the editor
    GUI Error: You are pushing more GUIClips than you are popping. Make sure they are balanced.
    UnityEngine.Debug:LogErrorFormat(String, Object[])
    Jundroo.ModTools.Editor.ModBuilderWindow:BuildAndSaveProjectAssemblies(BuildTarget, Boolean)
    Jundroo.ModTools.Editor.ModBuilderWindow:BuildAssetBundle(BuildTarget, Boolean, Boolean)
    Jundroo.ModTools.Editor.ModBuilderWindow:BuildAssetBundles(String, BuildTarget[], Boolean)
    Jundroo.ModTools.Editor.ModBuilderWindow:CompleteAndSaveMod(ModTargetPlatform, Boolean)
    Jundroo.ModTools.Editor.ModBuilderWindow:OnGUI()
    UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

    4.1 years ago
  • Profile image

    I just scrolled through the entire article to see the pictures😅

    4.2 years ago
  • Profile image

    @HawaiiRanger I think you have it available in the top menu, next to "Window" and "Component". Just select it and drag it to the right panel.

    4.3 years ago
  • Profile image
    6,300 HawaiiRanger

    @mikoyanster I have tried everything you said about importing the SP assets to Unity, and it worked, but it won't show the Simple Planes tab for editing the map. If you know how to fix this, or what is wrong, I would really appreciate it!
    Thanks!

    +1 4.3 years ago
  • Profile image
    1,350 EstevanTB

    Question, this version is Unity 5.3 right? now explain to me why THE VERSION OF UNITY 5.6 MORE UPDATED THAN THE DOWNLOAD 32BITS,WHY THE ASSETS OF SIMPLEPLANES 32 Bits doesn't work either?

    4.7 years ago
  • Profile image

    can you give me assets pack compatible for simpleplanes

    5.6 years ago
  • Profile image

    @mikoyanster Mind If I Send You The Project File To Try Compiling It Your Self? It Might Be A Problem On My Side

    5.7 years ago
  • Profile image

    @FairFireFight I think the error could be due to that "Pure Mod Tools". It happens to me when I install the Terrain Toolkit mod. The textures can be loaded without the need for Mods. You only need to copy the textures and paste them into a folder that you will create with the name "textures", in the path of the Unity project you are doing. For example, in the path "C: / Documents / nameOfyourProject / Assets / Textures" When you paste the images, they are automatically recognized in your project.

    As for the SimplePlanes mod, when you import it for the first time, it will appear in the "Windows" menu. You select it and you can drag the tool window.

    5.7 years ago
  • Profile image

    @mikoyanster I'm Using Pure Mod Tools (Mod Tools And Mod Tools Assets) and import the textures I'm using (Your Textures Pack)

    Slight Note: When I Import The Mod Tools , The "SimplePlanes" Tab Does not appear , I have to save the project then close it and open it again for it to appear
    is that your case too?

    5.7 years ago
  • Profile image

    @FairFireFight ok in this case could be a Asset that you import un Unity. I get these error when i use Terrain Toolkit 2017... Still not find a solution...

    5.7 years ago
  • Log in to see more comments