NoMansSky:Understanding EXML Files

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

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. Of course, these are simple examples, and you can have some much more intricated structures, but it gives an idea of how the file is generated and strutured.

Values

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"




Template:NMSPageClose