NoMansSky:Understanding EXML Files

From Step Mods | Change The Game
Revision as of 13:39, August 15, 2020 by Lo2k (talk | contribs)

Template:TOC right

Introduction

.EXML files are the final result after decompressing .pak files and decompiling .MBIN files via MBINCompiler. But what are these files ?
.EXML files are a human-readable expression of an .MBIN File.
Where .MBIN files are a list of flags and values, .EXML files expose all the values in a structured manner, with names and labels.

For example in the image below, the same data are described in the selected lines.
On the left, the 8 raw encoded values in the .MBIN file. On the right, the same 8 values exposed with their name and structure. Mbin-exml.png

To get this readable structure, MBINCompiler applies the data stucture as stored in the game executable and format it in a .txt file we all could read.

Structures and Properties

The structure of each .EXML file is basicaly a database and as any database, data are sorted.
Here we have a list of properties. Each property has a name and an associated content. This content could be a value, with a defined type, but this can also be another structure storing more content.

In the example above, we can see that SunLightIntensity has for content a single value, 3.
That's the simplest content but we can have more complex ones, like this color property:
Colortype.png
here, we can see that the ScanColour property has for content a file named Colour.xml. This file is a template. It basicaly says : the 4 next values are named R,G,B and A and have for values floating point values. So when reading the .MBIN file values, MBINCompiler wrote the 4 values with these informations, creating a nested layout.

All in all, any nested structure always ends with values. And each value as a type. this could be :

  • A boolean : "true" or "false"
  • An integer : a rounded value like "1124"
  • A decimal aka floating point value : a non rounded value like "0.793". Note that "3.0" is valid as is "3". So beware to not confuse a decimal and an integer value.
  • A string : a text like "Medium" or "High"

This Colour. xml template is just one amongst a thousand ones, store in the game executable. So even if you search in all the game content, you will never find a file named Colour.xml.
But these templates has been extracted and referenced and you have at least two ways to consult them :

  • Monkeyman192's extracted libMBIN structures lists all the existing structures, sorted in 5 categories.
  • AMUMSS and more specifically the NMS PAK Explorer-Unpacker tool associated with it, gives access to the same libMBIN structure list but in an interactive way, allowing to click on any property content to discover its content and the type of its values as nested as they are.

So you now know everything you have to know about .EXML files. It's up to you to edit them and create a mod.

Template:NMSPageClose