Progress:

» Convert Assistant» 1. Download & Install CA» 2. Configure the Convert Assistant» 3. Choose the correct settings» 4. Convert
» XML» 1. Choose your editor» 2. Mesh-XML structure» 3. Item-XML structure
» Testing ingame» 1. something» 2. something

!!!

WARNING

this is outdated


check:

https://github.com/skyslide22/blender-addon-for-trackmania-and-maniaplanet

Creating & Importing

custom objects

for maniaplanet

Move your mouse around ... ヅ

Tutorial for creating & importing objects for Maniaplanet

Step 1: Blender

This section is about Blender, the 3D-Program, which we will use to create the custom objects! Starting from download&install, creating your first object, which includes all needed steps and basics you need to know: Modeling, UV-Mapping, Materials, Exporting in *.fbx, Hotkeys

Step 2: Convert Assistant

Here we will convert the *.fbx (3d fileformat) to *.gbx. For that, we will use the Convert Assistant, this programm helps you to use the Nadeoimporter, which is the programm, which converts your object, the Convert Assistant is only for the easy use of it!

Step 3: Mesh & Item.xml

Every *.fbx needs 2 *.xml files for the convert, the Convert Assistant creates them automatically, just choose one of the templates!.
The Item.xml includes the parameters for the block placing in the editor. The Mesh.xml includes all materials and their paramaters, also the light materials and parameter.

Step 4: Maniaplanet

Testing your object inside maniaplanet, check if textures looks fine, if they are stretched or material was named wrong, also lightmap calculate to check if something looks weird .

to check the block again, you just need to reload the map, or create a new map, game restart is not neeeded for an updated file. It only works in custom titlepacks, for example the rpg titlepack!

Step 1: Blender

1. Download & Install Blender

Download

Since Blender 2.8 will change the whole UI, and stuff, i will make this tutorial only for Blender 2.79b. You need to choose the installer or zip,
i suggest you the installer, but choose what you prefer.

download.blender.org/release/Blender2.79/

Install

Run the installer, i suggest a normal installtion (x86 etc).
You can unzip blender whereever you want!

Now, just open Blender and go!

2. Blender UI

Quick Overview

So, there we are, Blender! This is the startup file, which we will configure in the next steps, so we have all the windows we need visible!

What is what? whaaat?

1. File: Save file, open config, export, etc
2. Basic Operators: Move, Scale, Rotate, Shading, Duplicate, Stuff
3.
Mode: here you can switch between Object and Edit +etc modes
4. Object Shading/Display: Wireframe, Material, Solid, Render etc
5.
Layers: 20 Layers, sort your blocks in layers like photoshop
6.
Acess to UV-Map and Material windows/settings
7. List of all Objects: Mesh, Lights, Curves, etc

3. Basic Knownledge

Faces, Edges, Vertices

What are 3d objects made of? Well, every 3d object consists of triangular faces. And a triangular face is made out of 3 edges, and a edge is made out of 2 vertices. Also, no object is actually "round", they just look like it, because they use a smooth shader,

Materials

Materials contains the information about which face uses which textures.
For example: Material stadiumplatform uses the textures StadiumPlatform_D, StadiumPlatform_S and StadiumPlatform_N, the assigned faces to this material will show the textures of the material.

UV Mapping

Every 3d object needs a UV Map to display a texture, what is a UV Map?
The UV Map contains the entire geometry from the model itself, but in 2d, on a texture/image.

Islands, islands are bounded faces in the uv editor, example: you have row of 32 faces, they are all bounded with their neighbor, and two single circles. You have 3 Islands here, and yes, i am talking about a cylinder.

Blender UI

Blender gives you the possibility, to change the mode of every window, for example, the main window is a 3d editor, the window below is a timeline. You can change the timeline to a uv editor, or something else, and make the window bigger, smaller, or devided,

Also, every window has its own menu bar, the 3d editor has view, select. add and object, the uv editor has view and image. Those are all tabs, which opens a menu with possiblites like save image, set cursor, add mesh, hide objects, etc, Also, the main window's have 2 panels, one at the left and one at the right, open/close with T & N

4. Configure UI

Windows & settings

In this section we will configure the user interface and learn, which window is used for uv editing and modeling. We will have two main windows, and the panels at the left & right.

Addons

Addons, blender lives from addons. Since blender is opensource, you can modify the entire programm. But everything is fine, just a few things are missing. So, we will add a few addons which make modeling and uv editing alot easier.

So, lets start!

First, we open the tool and properties panels with T and N.
Then we change the timeline to the uv editor, T and N are working here too!

Here we will open the material tab, delete all basic objects and switch to layer list. You can switch the layers with 0-9 and ALT 0-9 or clicking in the layer box in the 3d bottom menu (20 gray boxes with one orange dot). Put objects in different layers: select object's, press M

Start configuration done, lets install addons!

Download my collection of blender addons, unzip the file before. Install them by install from file (.zip and .py) and activate them!
‍Download here: https://vinummusik.de/Skyslide/3d-creation-and-import-tutorial/files/BlenderAddons.zip

Maniaplanet_Blender_Script_by_Maxi031_V6.py: | left panel, tools, Maniaplanet Addon
- Export every object as single ones in defined location (disable relative path bottom left menu)
- enable scales: export in different sizes, half of base (objectname_#7 will get exported 3 times if you set "5", so #6 is half of #7 and #5 is half of #6)
- exports blockname123_Lod0 and blockname123_Lod1 as one object
- Create Lmap and Bmap:created BaseMaterial und Lightmap uv layer

io_export_selected.py: | top left, file, export
- export selected obect's with last selected objectname, if you export a checkpoint, choose the checkpointmesh at last)

fbx-import-batch.py | top left, file, import
-
imports selected fbx files

uv_squares.py | left uv panel, Misc
- Make uv islands to a vertical or horizontal aligned row. Works best only with squared faces!

uv_magic_uv.zip and textools.zip | left panel, Textool, Magic
- Many new operators like cursor location with button etc

save_image_as_dds.py | Bottom-menu, Image, save as .dds
- save texture/image as .dds

MultiEdit_1_0.py | left panel, multiple objects editing
- Edit multiple objets at once, in 3d and uv editor (go in editmode with multiple objects- use exit button to leave!)

namestack-master.zip | top right, batch name (scroll to move top menu, might be "hidden")
- Renames selected objects, choose the cube before (useful for dublicates , eg: find blockname3, replace with: blockname4)

space_view3d_screencast_keys.py | right panel, screencast
- Enables an overlay which shows pressen buttons

vtools_objectsLayerManager.py | right panel, objects layer manager
- Adds objects to custom layers, you can hide and select them

vtools_SnapShotMesh.py | right window, object data(grey triangle), snapshot meshes, at the bottom
- You can create backups from your mesh, object and edit mode

curve-modi.py | left panel, Misc
- calculate lenght of curve, you can put a mesh on it with the curve modifier. Scale the object to the curve lenght. Road on a curve!

5. Hotkeys

Basic hotkeys

Well you can use the buttons, but blender works best with hotkeys, here are some most used ones, atleast the ones i use often!

Note
: you can write parameters while operators are active. An example: you want to rotate your selected 15degree left in z axis, you would press
R + Z + 15 + ENTER (or ctrl v, if you copied "15" before, or pi with 100 numbers)

Interesting video for 51 Blender Shortcuts: https://www.youtube.com/watch?v=CWgKrFk5gU4

General hotkeys

- Hotkey

LEFT MOUSE
RIGHT MOUSE
MOUSEWHEEL SCROLL
MOUSEWHEEL

CTRL S
CTRL SHIFT S
CTRL U
CTRL N
CTRL V
CTRL Z
CTRL SHIFT Z

Enter
G
R
S
M

B
C
A/AA
SHIFT + RIGHT MOUSE
H
ALT H
CTRL M X/Y/Z
CTRL I
SHIFT S
CTRL SHIFT AXIS

O
CTRL HOLD

T
N
SHIFT SPACE

SPACE

- Function

Set cursor (new objects spawn there, can be used as origin)
Select object/vertices/edges/faces
Zoom
Rotate camera

SAVE (note: *.blend1 is a backup of the blendfile, generated automatically)
SAVE AS / SAVE ON DIFFERENT LOCATION
LOAD STARTUP FILE
NEW FILE
Insert copied numbers in operators (eg: G + Z + CTRL + V(10) = go up, 10 steps)
Undo (32 steps by default, you can change it to 256 in userpreferences, "FILE" top left)
Redo the undo (also 32 steps by default)

Apply operator / apply value
GRAB » move selected
Rotate » rotate selected
Scale » scale selected
Layers » like in photoshop, you can set your object in 20 layers

Box select (mousewheelbutton to invert)
Cirlce select (mousewheel for size, mousewheelbutton to invert)
Select all/ deselect all
Select multiple objects/vertices/edges/faces
Hide selected
Unhide everything
Mirror selected on axis
Switch between selected and unselected
Cursor menu
Disable choosen axis (CTRL SHIFT X, you can rotate(etc) now only in x and z axis)

Proportional edit (making ramps, slopes, etc)
Grid, no free movement,

Tool panel on the right (operator like remove doubles, add mesh, rotate, shading)
Setting planel on the right (position, dimension, cursor location, display settings, etc)
Enter/leave fullscreen

Opens search menu for operations (SPACE + your text, eg add plane)

3D editor hotkeys

Note: Object mode is only for rotation, move, scale and location(set origin), Edit mode is the mode you need to "edit" your object!

- Hotkey

TAB
Z
SHIFT A
ALT + C

NUMPAD + NUMBER

ALT RIGHT MOUSE
CTRL RIGHT MOUSE

F
E
SHIFT D
CTRL B
CTRL R
CTRL E
W
ALT J
CTRL N

U

- Function

Switch between object and edit mode
Switch between wireframe and solid display mode
Add objects , only in object mode (light, mesh, curve, etc)
Convert object (Text in mesh, curve in mesh, mesh in curve, etc)

1: front, 3: side, 7: top, 5: 2d view --- 9: rot 180*, 2 4 6 8: rotate 15°

Select loop (edge or face(squares only)loop)
Select the shortest line between selected and new selection (eg select faces from A to Z)

Fill selected vertices/edges with edges/faces
Extrude selected
Double selected
Bevel, makes smooth edges in edit mode
Loopcuts (mousewheel to in/decrease)
Edge menu (You need mostly: Mark-seam, Mark-sharp, Split-edge,
Special operators like subdivide, merge, flip normals, etc
Make tris to quads
Recalculate normals

Opens Unwrap menu (creates islands in the uv editor)

2D / UV / Image editor hotkeys

- Hotkey

F3
CTRL P
E

- Function

Save image/icon
Pack Islands (useful for lightmaps)
Unwrap all visible Islands again

6. Create & Modeling Mesh

So, lets finally start with the main thingie: Modeling

First, we decide, what we want to create! In this tutorial, we will create a Checkpoint-Booster as a platform block for stadium.

So, lets start, adding a cube, go in editmode, move it around and scale it!
For moving,  press G + Z + 1 to move it 1 meter up (z), then G + CTRL SHIFT Z to lock the Z axis, after that, hold CTRL to use the grid.
For Scaling,  press S + CTRL SHIFT Z 16, then S + Z  + 4

You can see the values in the right panel, DImension defines the size in meters (default cube is 2x2x2). Scale defines the original size.
Example: your object has a size(dimension) of x32 y32 z8, so the scale must be x1 y1 z1, This is important for export! You need set the current dimension to defaul, press CTRL A, choose Rotation&Scale. Blender will export your object with scale 1 for every axis, so you have to say, 32 is 1!

Here we will subdevide the surface and extend a few faces up.

For that, we go in editmode, pressing CTRL R, choose the direction, use the mousewheel to choose the number of loopcuts.
Then we select the faces with RIGHTMOUSE CLICK, and SHIFT for multiple selection.
With E you can extend/extrude the selected vertices/edges/faces
Again, with CTRL you can use the grid snapping, so you do your operators in steps, like move in 1 meter steps instead of 10mm.

Now, add two more loopcuts, move them up , keep both symmetrical. Then we will use the searchbox, open it with SPACE, type bridge, choose the operator. Now you have a bridge between your selected faces, a roof for your checkpoint booster block!

If your objects gets too many loopcuts, you can select them afterwards and remove them with CTRL X, or X and select Limited Dissolve, you can select the parameters for removing method on the left panel, like keep uv island, keep mark seams.

7. UV-Mapping

Get the textures on the model!

Here we will unwrap the selected faces from our object in different ways. Mostly i use Smart UV Project and Unwrap, open the menu with U.

Smart UV Project
cuts the faces by the max angle of 89, you can also set the island distance from 0 to1, this way dont really need mark seams, because it splits the faces automatically.

Unwrap
needs mark seam, the edges which are marked as seam are red. Those edges says, split the faces here. Select the edges, press CTRL E and then choose mark seam,

Reset unwraps every face as an single island, as big as they can get (cube = 6 seperat faces, overlapping, maximal size)

Project from View, says everything. Projects your object from your current view, i suggest you to use the 2d view, from the side , bottom or top. (NUMPAD 5 and 7/3/1)

First, lets collect the stadium textures, i have all in one folder already, download here, and install them whereever you want, i suggest you to install them in the main items folder, where the custom textures also have their forced place: Documents\Maniaplanet\Items

Second, we open the textures in the uv editor, you can open them ingame or move them in the uv editor from the windows explorer.

Now select the faces, which you want to unwrap, do it spep by step. For this kind of case, you can select them in the 2d view with the box selection, because both sides are totally flat. For that, press 1 and 5 on numpad to get in the front/side and 2d view, Z for wireframe mode, then U to open the unwrap menu, choose Project from view(bounds)

Another project from view, but faces were selected with CTRL for row/line and ALT for loop select.

Now we select the faces, where the car should spawn, this is not needed, but why not? For that, we select the two faces, unwrap with project from view, and mirror them in the UV. Rotate it before, with R 90. To mirror selected, you should use the cursor as origin, choose it in the menu at the bottom, then CTRL M Y to mirror it in the vertical axis(Y) from the cursor, which is in the middle, if he is somewhere else, you have to set the cursor coordinates on the right panel(N).Choose normalized and the put X 0.5 and Y 0.5, or choose the middleedge,SHIFT S and cursor to selected, you should choose edge select mode before at the bottom. You can download the stadiumcar as reference for size here, import at the top left FILE, IMPORT, FBX

Well, we forgot the boosters, but thats not a problem, just some things to say: the booster physicid is based on the -Y axis, so you need to rotate your object properly. You can see the axis cross in the left bottom corner, the green one is the Y axis, be sure your booster shows in the opposite direction from the green arrow (the green arrow should look to the left if you want to boost to the right)

As you noticed, the textures dont look thaaaat great on the object, thats because the aspect ratio is wrong, if you unwrap a square and the unwrapped face has a aspect ratio from 1:8. it looks stretchet on the object, so keep it 1:1 like in the 3d view. If you can not go outside the texture area, you have locked it, you can disable the lock in the bottom menu, UVs, Constrain to image bounds

Fine, now our object is almost textured.But we still need a bar which marks this object as a checkpoint, since mp4, we have a nice texture for it.
Lets create a cube, scale it, add round edges (bevel) with CTRL B. Select the edges before.

Ok, now we delete the double vertices, use the button at the left. Then we unwrap both sides with U, Unwrap. Choose the texture, and get it in the right place and mirror it with the steps above.

Fine, BaseMaterial is done! ... BaseMaterial? What is that? Well thats the main uv layer, every object for maniaplanet uses two uv layers, single one in special cases (projected textures only). So, we need to create BaseMaterial and Lightmap layer, please take attention for capital letters.

Ok, we have one uv layer already, lets call it BaseMaterial. Now we need a second one, create it (its a copy of basematerial) and name it Lightmap.
Select everything (AA) in the uv editor and remove the textures, we dont need them here, and its easier to work without textures.

Lets get to the hard part, making the lightmap. The lightmap is used to preview the shadows, its important, to keep distances between the islands, also keep in mind that every object gets only a few pixel from the lightmap (2048x2048jpg). If any crazy mapper uses 1000 blocks, like in rpg maps, the block gets only 1/1000 from 2048x2048 pixels, also the percent of the space which each block has on the lightmap is also based on the size. Imagine a block which is as big as the stadium, it would get the half space of the lightmap. Thats my knownledge, i may be wrong on some things.

So, lets get started! The fastest way to make a lightmap is using the smart uv project, it will split the faces which are over 89 degree, works fine, but just for easy blocks like a cube, works badly for spheres! Since this method is not the best way, i make all my lightmaps with mark seam.

Here a demonstration of smart uv project:

As you can see, they dont look that bad, but the cylinder is splitted in several islands, and that is wrong.
Also, there are two small circles, we dont have circles on out object! So, those are faces, we dont need, they are not visible also, so delete them.
You can also select them in the uv editor, just click on the cube with the mouse at the bottom.

You can repack the islands, change their place and their distance to other islands with CTRL P, select everything before.

Almost everything looks fine, just not the cylinder, you can fix those faces by yourself, but for this section, we will unwrap the entire object with unwrap.
For that, we need seams, select the edges and add seams with CTRL E mark seam, the edges are marked red afterwards. I suggest you to split the faces at 90 degree, so you have the faces which should share the lightmap bounded, and the islands which probably get other shadows seperated.

Unwrap with U, select everything before. Pack islands with CTRL P. Voila, Lightmap done!
As you noticed, one island looks weird at the start, that was the case because we forgot to set all needed mark seams.

Last words ... This is my way, there are a lot other ways how you can do uv mapping, and work with textures, but this is my way, and im used to it, so you can do it however you want, adding textures to materials in blender and work only with material and wireframe shading instead of solid or etc...

8. Materials

Materials: assign textures to faces

Well, you see your object textured in blender, aslong you select the basematerial layer, but thats just for blender, it is not enough for maniaplanet, we have to say, this face should have this texture, for that, we create materials. Materials contain the infos which face gets which texture. In blender, we assign some faces to material1 and some to material2, in the xml, laters, you define the texture (material1 = texture YXZ)

But for now, we just create the materials, give them a color and assign the faces to it. You can steal the materialnames from the xmls.

So, every face is assigned to a material, now you have to name your materials, steal the names from the mesh.xml's or nadeoimportlib.txt.
Or, do the easy way, and name the material like the texturename, StadiumPlatform, StadiumCircuit, StadiumEtc, just remove the _D.dds. You can copy the name in the bottom menu, just select your texture and click on the name.

If you use the easy way, the convert may give error, material not found, if thats the case, you need search for your texture in the nadeoimporterlib.txt and copy the materialname inside the brackets from DMaterial, here a example: Nadeoimporterlib.txt , CTRL F, search for your texture:

DMaterial(StadiumControlStands2)
DSurfaceId (Concrete)
DUvLayer (BaseMaterial , 0)
DUvLayer (Lightmap , 1)
DTexture( StadiumWarpStands2N.dds)
DTexture( StadiumControlO.dds)
DTexture( StadiumWarpStands2D.dds)
DTexture( StadiumWarpStands2S.dds)
DTexture( StadiumControlL.dds)

You need to name your material in blender StadiumControlStands2, because thats the name of the material from this texture. (nadeo defined)

The checkpoint bar looks flat, thats because we did not use a smooth shader, you can make your own mark sharps with CTRL E mark sharp, but autosmooth angle works fine in most cases. You will find autosmooth in the right window, same place as the uvmaps (triangle). To get it working, you need to make your object smooth, you can do it in object mode for the entire object, or in edit mode, to choose only a few and not all faces.

Auto Smooth does not work for imported objects. To get it working, you need to clean the custom split data before, the button for that is right below the uv maps.

9. Create Checkpoint equipments

Checkpoint, Start , Finish and Multilap objects

Checkpoints need two more objects, the _trigger_nameit and _socket_nameit. The trigger is the mesh, where you have to drive through to trigger the checkpoint. I suggest you to use a single plane here, thats enough. Secondary, the socket, thats the object, which defines the start position and rotation.

Lets name your object first, then name your trigger, if you have more than 100 blocks in one blendfile, its nice to know, which trigger and sockets are assigned to which object.

So, name your object SuperCoolCheckpoint, create a plane, in the object mode, and name it _trigger_SuperCoolCheckpoint.

Now create a empty, SHIFT A, empty, Arrows. Rotate it 90 degree in x axis, or you car will spawn on 2 wheels. The Z defines the direction, in this case, its perfect aligned, now name it_socket_SuperCoolCheckpoint. Checkpoint done.

10. Create icon

Icon for editor

So, here we create the icon for the block, which gets displayed in the editor. Since a few months, icon don't get embedded anymore, so they won't steal embed space. You can make them 256x256px if you want, i suggest 64 or 128px.

First, set the parameters for the icon in the right window: 64x64px /128/128px, shading: transparent, and export format: tga

Now, get your camera in right position, or create a camera, i use the normal viewport. Hide all objects except the checkpoint with H / ALT H
Click on the camera icon, go in the uv editor and choose Render result. With F3 you can save the image as tga, save it where the object will be exported, create a new folder called Icon, and save your image there with same same name as your object, SuperCoolCheckpoint.tga

11. Export

Finally, exporting the object's

There we are, the last step. Exporting as .fbx needs some configuration, otherwise your object will be 3200x3200x3200 instead of 32x32x32 meters.
Maxis Maniaplanet Addon for blender also has a function for exporting, but that way is only useful for normal blocks which don't have equipments like checkpoint trigger, sockets and lighs, only _Lod0 and _Lod1 will be combined to one object.

Lods are Level-of-Details objects, _Lod0 is the highpoly one and _Lod1 is the lowpoly one. This is useful for objects with high count of faces like a sphere with 4000 faces, the lowpoly version (_Lod1) should get 1000 or less. Put them behind your objecs. (SuperCoolCheckpoint_Lod0)

You should use the export selected for Checkpoints (addon, install from my collection)

So, select your trigger, socket and your checkpoint lastly, then go to the top left, FILE, EXPORT, Selected, FBX

Configure fbx exporter, choose selected objects, click on the scale button (dark grey is wrong), apply scalings; choose FBX ALL. Disable all other things like shown below is not needed, but saves space for the fbx file.
Since blender 2.79 uses a newer version of the fbx exporter, some things changed, things above should be correct.

Step 2: Converting

1. Download & Install Nadeoimporter & Convert Assistant

Download Nadeoimporter

The Nadeoimporter does the convert, not the convert assistant, download the current version here

https://doc.maniaplanet.com/nadeo-importer/getting-started

Install Nadeoimporter

Unzip the file in C:\Program Files (x86)\ManiaPlanet,

Download Convert Assistant

Download the convert assistant by maxi031 for the easy handle of the nadeoimporter here:

http://vinummusik.de/Maxi031/ConvertAssistant/Download.html

Install Convert Assistant

Unzip whereever you want, i have my one in Documents/Maniaplanet/ConvertAssistant3.41,

2. Configure Convert Assistant

Configure the assistant

Here we will configure the convert assistant!  

  1. First, open the ConvertAssistant.exe, choose the nadeoimporter location, which should be in C:\Program Files (x86)\ManiaPlanet,
  2. Second, we set the default author name, $Author-skyslide for me. Open Options, Custom variables, set your name
  3. Choose system default in Options, Settings, to open the xml files with your code editor like notepad ++
  4. Now we set the prefix for hack physic IDs, Objects, Settings, Hack physic id. Change it to _T
  5. Download my templates for Item and Mesh.xml here:
    https://vinummusik.de/Skyslide/3d-creation-and-import-tutorial/files/ConvertAssistant-Item-Mesh-Xml-Templates.zip
  6. Install the xml files from the meshxml folder in ConvertAssistant3.4.zip\meshParamTemplates
  7. Install the xml files from the itemxml folder in ConvertAssistant3.4.zip\xmlItemTemplates
  8. Now you should have some templates for the start, finish, multilap, checkpoint and normal placement, Also my stadium and rpg mesh.xml's.

3. Choose the correct settings

Collection, Hack PhysicID, Mesh & Item xml

So, we did set everything to get started. Now we need to set the individual settings for our object, in which environment should it be avaliable, what placement in the editor and which textures.

First, we select the collection, the base environment: Stadium, Canyon, Valley, Lagoon, Shootmania, Common for all.
Then we activate the physic hack if, if you want to use a different physicID for any nadeomaterial.
After that, we decide if we want to overwrite the object assigned xmls by every convert, i do it.
Now we select the Mesh and Item XML. Choose Y_32-8-Checkpoint.xml and Stadium.xml

4. Converting

Convert your object

Finally the last and best step of all steps, pressing a button.

If you get any red windows, well thats not good, thats a error, could be material name, uv layer name or object name/location.
Keep in mind that space is not allowed in filenames, use _ - and # instead. Also, your object need to be in \Documents\Maniaplanet\Work\Items\

Step 3: XML

1. Choose your editor

Edit xml files, why?

The convert assistant offers a few templates, but they are kinda empty. So, you could use my templates, for stadium. Download them in here.

Not everything is written in my xml templates, also only stadium is included in my template pack, you still need to edit the xml files to add your own materials, lights etc.

Which program should i use?

Any text editor should work, i prefer notepad ++
Download it here: https://notepad-plus-plus.org/

I suggest you to use a code editor, like notepad ++, it shows different parameters and symbols in different colors.
Change the default programm for xml files to your code editor, so the convert assistant will open them with the default editor.

2. Mesh-XML structure

The Mesh-XML stucture and parameters

The xml (Extensible Markup Language) is a text format, which includes parameters for programs. The parameters are defined, and we just change their values to the ones, we want to use. An example:

<Material Name="Logo_competition" Model="TDSNI" BaseTexture="/Items/COMP_Textures/Logos/Logo_COMPETITION" PhysicsId="Metal"/>

The parameters above give the infos about:

  • Materialname: the name of your material, all following parameters belongs to the materialname
  • Model: TDSNI, those 5 capital letters defines the texture model, T means Texture, D means Diffuse, S Specular, N Normalmap, I Illum/glow
  • Model: Custom textures need the model id behind their name, like Logo_D, Logo_S, Logo_N, Logo_I.
  • BaseTexture: only custom textures need a file path, no file extension like /Logo_competition.dds
  • BaseTexture: nadeo textures need only the DMaterial name from the nadeoimporterlib.txt in x86/ManiaPlanet/nadeoimporterlib.txt
  • PhysicsId: defines the physic of the material, like Grass, Dirt, TechMagnetic, Concrete and NotCollidable for no collision.

To hack the physicId of a nadeo material, use the _TDSN_materialnameyouwant_Dirt, this material will use the nadeo material you choosed with the physicsId you want, its used in rpg, since the same material can be used multiple times with different physics id. For example, the rpg titlepack blocks are based on StadiumSculpt2D, this texture includes the main textures, a collection of 20 textures on a single one, Wood, Metal, Concrete etc.
Since all those textures are on StadiumSculpt2D, you need to set the PhysicsId for StadiumSculpt2D twice, so you write for example:
_TDSN_StadiumSculpt2D_Concrete and _TDSN_StadiumSculpt2D_Wood as the material names, and define the parameters for each material.
It would look like this:

<Material Name="_TDSN_StadiumSculpt2_Metal" Model="TDSN" BaseTexture="StadiumSculpt2" PhysicsId="Metal"/>
<Material Name="_TDSN_StadiumSculpt2_Wood" Model="TDSN" BaseTexture="StadiumSculpt2" PhysicsId="Wood"/>

Light Materials

We set parameters for textures, but what about lights?
Textures which glow do not emit light. For that, we need to set a real light, a spot or a point. I use points mostly. So, to create a light in blender, press
SHIFT A, choose lamp, point.
Here is a material from a pointlight:

<Light Name="Blue" Type="Point" sRGB="0000FF" Intensity="1" Distance="32" PointEmissionRadius="0.6"/>

The parameters above give infos about:

  • Light Name: the actual name of the light in blender
  • Type: defines the type of the light, Point: creates light like a sphere - Spot: used for spotlights, create a spotlight in blender!
  • sRGB: color of the light in HEX, go to google and type #00ff00, you get a color table, choose your color.
  • Intensity: the intensity of your light, 0= no light, 1= 100% light
  • Distance: the distance/radius of your light light in meters (32meter = 1 stadiumblock unit)
  • PointEmissionRadius: well, get your knownledge from the image below! (the 4 lights are 4 meters above the surface)

For more information, visit the documentation from nadeo: https://doc.maniaplanet.com/nadeo-importer/import-a-mesh#lights

3. Item-XML structure

The Item-XML stucture and parameters

There is a second xml fot the convert which you need to understand, the item xml. The item xml includes the parameters for the placement in the editor, autorotaion, horizontal and vertical step (hstep /vstep), pivots and more.

So, here is the X_16-4.xml from my template pack:

<Item Type="$Object_Type" Collection="$Collection" AuthorName="$Author">
 <Phy>
   <MoveShape Type="mesh" File="$Name + .Shape.gbx" />
 </Phy>
 <Vis>
   <Mesh File="$Name + .Mesh.gbx"/>
 </Vis>
 <GridSnap HStep="16" VStep="4"/>
 <Levitation VStep="4" GhostMode="true"/>
 <Options AutoRotation="false" ManualPivotSwitch="true"/>
 <PivotSnap Distance="0"/>
 <Pivots>
<Pivot Pos="0 0 0"/>
<Pivot Pos="0 -1.345 0"/>
<Pivot Pos="0 -1 0"/>
 </Pivots>
</Item>

The parameters above give the infos about:

  • Item Type: choose in the convert assistant: static or dynamic
  • Collection: choose in the convert assistant: stadium, canyon, valley, lagoon, shootmania, common for all envis
  • AuthorName: choose in the convert assistant: options, custom variables, $author-yourname
  • Hstep: horizontal(x/y axis) steps in meters
  • Vstep: vertical(z) steps in meters
  • Levitation: well, if you set vstep to 4 and levitation to 1, you have to scroll 4 times to set your block 4 meters up(vstep)
  • GhostMode: surfaces defines ground, vstep and hstep are in use, but for example, grass is the bottom, you can not scroll down under the grass.
  • Autorotation: works only if Hstep and Vstep are set to 0, object is sticky and will rotate automatically on the choosen surface
  • Pivots: move object away from the origin, (0 -1 0 will set it 1m up) (use ingame with Q key

For more information, visit the documentation from nadeo: https://doc.maniaplanet.com/nadeo-importer/import-a-mesh#lights

Step 4: Testing

1. Lorem ipsum

Something

Something

2. Something

Some heading

Something