No Man's Sky Modding Wiki
Tags: Visual edit apiedit
Tags: Visual edit apiedit
Line 32: Line 32:
 
If you copied the directory into another folder such as "MY MOD", your directory will be / MYMOD / METADATA / SIMULATION / WHATEVERNAME / and so on.
 
If you copied the directory into another folder such as "MY MOD", your directory will be / MYMOD / METADATA / SIMULATION / WHATEVERNAME / and so on.
   
To create your own PSARC archive, simply drag all ''immediate child folders'' under "MY MOD" into the PSARCTool. It will create a new file called psarc.pak. Feel free to name this say you like, but the prefered convention is _MOD.MYNAME.MYMOD.pak.
+
To create your own PSARC archive, simply drag all ''immediate child folders'' under "MY MOD" into the PSARCTool. It will create a new file called psarc.pak. Feel free to name this file anything you like, but the prefered convention is _MOD.MYNAME.MYMOD.pak.
   
 
As of the Foundation Update, all mods are now run from a new MODS folder found in your default PCBANKS directory. Simply place your PAK file inside and run the game to check for your mod! It is important to note that mods are run in alphanumerical order. Mods that use the same files will be overwritten by the last mod to be loaded.
 
As of the Foundation Update, all mods are now run from a new MODS folder found in your default PCBANKS directory. Simply place your PAK file inside and run the game to check for your mod! It is important to note that mods are run in alphanumerical order. Mods that use the same files will be overwritten by the last mod to be loaded.

Revision as of 02:05, 9 June 2017

This quick guide has the goal of quickly introducing fundamental aspects to modding No Man's Sky without going into many specifics, starting with setting up your game client for the possibility of making your own mods and get you familiar with some core tools involved with modding.

You will be using three tools for the time being:

  • PSARCTool
  • MBINCompiler
  • Any text editor of your choice

PSARCTool and MBINCompiler are linked in the tutorial below.

Accessing Game Assets

No Man's Sky stores all of its assets, from textures to models, shader code to entity behaviors, in the PSARC archive format used in general for Playstation games. All these archives can be found under your /PCBANKS/ folder, the general directory you also install mods into and have the extension *.pak.

In order to extract assets from the archives, you will depend on using the PSARCTool. The PSARCTool is mostly command line based for now but is very easy to use. Download the tool and place this into your PCBANKS folder for now.

Different PAK files host different files for the game. While some modders who wish to save disk space will simply unpack specific files, it is preferable to unpack your entire game's archives for now. Reserve at least up to 7GB of space on your game install directory. (As of the 1.1 Foundation Update, about 6.5GB of space is used when unpacked)

In order to begin unpacking, drag all of the .PAK files inside your /PCBANKS/ folder into PSARCTool. The extraction process usually takes anywhere between 15-25 minutes on a standard HDD.

After Unpacking: The MBIN Format

After PSARCTool has finished unpacking, your directory should now expose completely new folders where all the files of the game are sorted into. It is preferable you move these folders to a new directory such as "/PCBANKS_extracted/" preferably in the same folder as the original /PCBANKS/.

The most common filetype you will see are *.MBIN files. These are basically serialized XML files. These files contain the bulk of configurations the game reads such as controls for procedural generation, the behaviors of in-game objects, and so on.

Since MBIN files are encrypted, you will still need to decompile these files into a more human-readable form with the use of the MBINCompiler. Download the MBINCompiler and preferably place this on another directory as you will come back to this tool very frequently.

Much like the PSARCTool, you can simply drag an .MBIN file into the MBINCompiler executable. You will get a completely human-readable EXML file that can be opened with any text editor of your choice. Dragging an EXML file back into MBINCompiler does the reverse, and recompiles into an MBIN file.

Compiling a Fully Releasable Mod and Playing It

Assuming you have modified several EXML files and succesfully recompiled them back into MBINCompiler, you will need to remember that the files you modified must have the same exact directory structure as you found them originally.

For example, if you modified an MBIN file inside a directory called / METADATA / SIMULATION / WHATEVERNAME /, you must preserve the same directory structure. You do not need to copy other files in the same directories if you did not modify them so you don't need to accidentally reship vanilla game assets.

If you copied the directory into another folder such as "MY MOD", your directory will be / MYMOD / METADATA / SIMULATION / WHATEVERNAME / and so on.

To create your own PSARC archive, simply drag all immediate child folders under "MY MOD" into the PSARCTool. It will create a new file called psarc.pak. Feel free to name this file anything you like, but the prefered convention is _MOD.MYNAME.MYMOD.pak.

As of the Foundation Update, all mods are now run from a new MODS folder found in your default PCBANKS directory. Simply place your PAK file inside and run the game to check for your mod! It is important to note that mods are run in alphanumerical order. Mods that use the same files will be overwritten by the last mod to be loaded.