NoMansSky:Tutorials/When AMUMSS Fails: Difference between revisions

From Step Mods | Change The Game
(Created page with "__NOTITLE__ {{NMSPage|contentTitle=When AMUMSS fails<small>(by Lo2k)</small>}} {{TOC_right}} == Introduction == AMUMSS stands for Auto Mod-builder Updater with Mod Script Syst...")
 
m (Text replacement - "\[\[Category:NMS-Index-.*\]\]" to "")
 
(30 intermediate revisions by 3 users not shown)
Line 1: Line 1:
__NOTITLE__
{{#set:
{{NMSPage|contentTitle=When AMUMSS fails<small>(by Lo2k)</small>}}
NMSIndex=AMUMSS
{{TOC_right}}
}}{{PageTitle|logo=nomanssky|title=When AMUMSS Fails|author=Lo2k}}
{{NMSPage}}
{{TOC}}[[Category:NoMansSky General Guides]]
== Introduction ==
== Introduction ==
AMUMSS stands for Auto Mod-builder Updater with Mod Script System and was created by Mjjstral before being now mostly maintained and extended by Wbertro.<br>
AMUMSS is a very robust piece of code and is very unlikely to fail per-say, but it has a weak point : it relies on MBINCompiler to decompile and recompile files.<br>
It was originaly developped to avoid mods to be broken at each update and allow some more flexibility in modding possibilities.<br>
MBINCompiler is indeed the only tool able to convert .MBIN files to .EXML and the reverse.<br>
Indeed, before AMUMSS, mods were just modified files. But each major update was changing file structure, adding new variables and values, exchanging some, or offsetting everything and all the mods released before the update needed to be completely recreated after each update.<br><br>
But as the game updates file structure regularly, it needs to constantly be updated to work properly.<br>
To prevent this chaos, AMUMSS offers to script mods.<br>
And this can take some time. Please remind here that MBINCompiler is the work of one man, Monkeyman192, and that he has a life, as everyone.<br>
Instead of modifying files and releasing the full files, AMUMSS lets you create scripts that are just saying which value for which variable in which file has to be changed. Then AMUMSS apply the script to the current game file and generate the mod.
<br>
It's a game changer.<br><br>
So here are the situations where AMUMSS could "fail".
Now, when a new game update is released, most of the mods can be regenerated in a few seconds, using the script to aim the correct values in the correct files and applying it to the new game file including any new change from the developper.<br>
So everything is perfect ? well, not exactly, there's still one bottleneck : MBINCompiler.
To Apply its changes, AMUMSS rely on MBINCompiler capacity to decompile and recompile files. But when a new game update is released, MBINCompiler needs to be updated to reflect the new changes. It's usually only a matter of a few days before MBINCompiler is updated and it's a few day were mods are actualy not working for the latest game version. But a few days is nothing, compare to the amount of time it would have taken to update all the mods manualy without AMUMSS!<br><br>
So AMUMSS is not perfect, but it's a great step ahead for mods sustainability. And it also brings a lot of other possibilities. Too much indeed to be listed in this tutorial.


== Using AMUMSS ==
== Game has been updated but MBINCompiler is not ==
We saw it, AMUMSS uses scripts that will generate final mods.
It's the most common case.<br>
Creating these script is a big topic but what will interest us here is how to use and merge them.
A new update has been released and some files can't be converted anymore.<br>
That's indeed another plus of using scripts : scripts can regenerate mods and can also be compared and merged a lot more easily than complete modified files.
AMUMSS can't do anything else than using the current but not up-to-date MBINCompiler version that will fail to decompile or recompile some files.<br>


== How to generate a mod from a script ==
in such case, you will result with lines like this one in AMUMSS' report:
If you downloaded a mod including a .lua script, you can either directly use the .pak in your MODS folder or regenerate the mod itself.<br><br>
[WARN]: MBINCompiler =[[WARN]: File not recognized. You may need to use an older version of MBINCompiler.]
Regenerating the mod will ensure the mod will use the very latest game file installed on your computer. It's usualy what the modder has done before you and released along the script, but sometimes, some mods are not maintained anymore and might need to be regenerated.
<br>
There's sadly not much you can do here but wait for an MBINCompiler update.
As AMUMSS is probing at each launch for an MBINCompiler update, as soon as a new MBINCompiler will be released, it will be downloaded and eventually the script or merge of scripts will work.<br>
Be aware anyhow that MBINCompiler is often updated in a few steps and the first few releases after a big update might fix some file conversion but not all of them.<br>
You might then need to wait a bit further for another MBINCompiler update to get your mod or merge of mods to be generated correctly.<br>
<br>
If you want to manualy check MBINCompiler status, you can also [https://github.com/monkeyman192/MBINCompiler/releases check this page] where you will get details on update progress too.


Here is how to regenerate a mod :
== MBINCompiler has been updated for experimental branch but you're on the public branch ==
* Place the .lua script in AMUMSS' ModScript folder
This is the second possible case.<br>
* Run BUILDMOD.bat
It's more uncommon but it can happen as the developpers sometime release a few experimental updates before pushing the result to the public and stable branch.<br>
* AMUMSS wil ask if you want to copy the final mod into your MODS folder : Choose Y(es) or N(o) depending if you want to install the mod immediately.
As described [https://stepmodifications.org/wiki/NoMansSky:Tutorials/NMSVersions#About_Branches in this page], No Man's Sky can be experienced via 2 branches : the public (default) branch and the experimental one (via a generic password).<br>
* Then it will ask if you want to check mods for conflicts : if you answer Y(es), AMUMSS will check all your existing mods (in the game MODS folder) and the one you're about to create and generate a report with the result. If you want to be sure you won't have any conflict, it could be wise to answer Yes. you will then be able [https://wiki.step-project.com/NMS:Tutorials/ToyingwithAMUMSS to detect conflicts] and resolve them.
The matter in this situation is that MBINCompiler has been updated for experimental files and can't compile or decompile anymore some of the public files correctly.<br>
* Eventualy the script is parsed and the mod is generated. You will find it in the CreatedModPAKs folder, ready to use, and in your game MODS folder if you choose so.
<br>
Note that once the mod is completed, a report is also generated about this new mod. it will report any error or warning inside this particular script and as for any report, you can read it carefully opening the REPORT.txt file in AMUMSS directory. Here again, if there is some conflict, you will be able [https://wiki.step-project.com/NMS:Tutorials/ToyingwithAMUMSS to detect them].
Hopefully, there's a workaround in this case. You just need to force AMUMSS to use the latest MBINCompiler made for the public version.<br>
 
<br>
== Merging .lua scripts ==
In practice, what you have to do is to follow "General Information for AMUMSS.txt" file and :
As they only point files, variables and values, AMUMSS' scipts are very easy to compare and merge. Much easier anyway than completely modified files.
* remove the x before your 'xOPT_CustomMBINCompiler.txt' in AMUMSS' folder
AMUMSS still only compare mods at a file level though.
* replace the MBINCOmpiler.exe file in MODBUILDER folder with the latest version made for the public branch. [https://github.com/monkeyman192/MBINCompiler/releases/tag/v3.02.0-pre1 Here is the link to MBINCompiler release page]
This means that it will warn if two mods alter the same file but it won't compare if variables changed are the same or different.
* generate your mod or merged mod as usual
It's a great feature though, as no player can really be aware of actual files existing in the 10, 20 or 50 mods they installed and just knowing which mods are in conflict could already solve great issues.
<br>
 
If you did as above, AMUMSS will use the specific version of MBINCompiler you downloaded and everything will work fine.<br>
Anyway AMUMSS can merge almost any mods, and any number of mods.<br>
Just don't forget to rename the OPT file again with a x as soon as a new public version will be released to let AMUMSS downloading latest MBINCompiler version the next time it will be launched, or you will end in the first case described in the section above, using an out of date MBINCompiler version compared to the game version !
All you have to do to merge mods is follow these steps :
* Place all your mods .lua scripts in AMUMSS ModScript folder
* Run BUILDMOD.bat
* 1st Question : Do you want to create a combined or individual mods : this question will either generate a merged mod or create one mod per script. Hit Y for the merged mod.
* 2nd Question : Do you want to use a composite name : this is just for the final name of the mod. When you only merge 2 mods, answering Y(es) will name it mod1+mod2.pak which is fine. But if you merge 5 mods, the name will be too long and it's better answering N(o)
* 3rd question if you answered N to not use a composite name : alternatively to a too long name, AMUMSS propose to add a suffix to the name, either a number or the current date. It's up to your tastes.
* Then it will ask if you want to copy the final mod inside the game MODS folder to be immediately ready for playing. It's up to you.
* And finaly it will offer to check for conflicts between all your current mods in the game MODS folder and the merged mod. If you want to be sure you won't have any conflict, answer Y(es)
* Script are now processed and AMUMSS will generate the final mod in ModScripts folder as usual and in your game MODS folder if you choose so.
A report is eventualy generated about this new merged mod. it will report any error or warning inside the scripts involved and as for any report, you can read it carefully opening the REPORT.txt file in AMUMSS directory. Here again, if there is some conflict, you will be able [https://wiki.step-project.com/NMS:Tutorials/ToyingwithAMUMSS to detect them].
 
 
== Merging one mod and any .lua scripts ==
As not all the mods have been declined in AMUMSS .lua script, you might sometimes end up with some .lua scripts you could merge and one particular mod without script.
Don't worry, you're not screwed as AMUMSS can also handle this case.<br>
 
All you have to do is using the exact same steps than for .lua scripts only, but this time, you will also place your mod with no script .pak file''' in AMUMSS ModScript folder.
You can then follow all the steps as before.
The only difference is at the end. In fact, if you chose to copy the mod into your game MODS folder, it will do the job for you, but if you chose to not do it, you have to be aware you will need 2 files. Indeed in this case, the .pak file generated in the Modscript folder is a patch to the mod .pak you placed in ModScript. So instead of copying one file, you will need to copy either your mod .pak AND the AMUMSS generated .pak file into your MODS folder to be sure effects of both mods will be applied and somewhat merged.
 
[[Category:No Man's Sky]][[Category:NMS-Tutorial]]
{{NMSPageClose}}

Latest revision as of 19:05, August 5, 2021

Nomanssky flare.png

When AMUMSS Fails

by: Lo2k

Introduction

AMUMSS is a very robust piece of code and is very unlikely to fail per-say, but it has a weak point : it relies on MBINCompiler to decompile and recompile files.
MBINCompiler is indeed the only tool able to convert .MBIN files to .EXML and the reverse.
But as the game updates file structure regularly, it needs to constantly be updated to work properly.
And this can take some time. Please remind here that MBINCompiler is the work of one man, Monkeyman192, and that he has a life, as everyone.

So here are the situations where AMUMSS could "fail".

Game has been updated but MBINCompiler is not

It's the most common case.
A new update has been released and some files can't be converted anymore.
AMUMSS can't do anything else than using the current but not up-to-date MBINCompiler version that will fail to decompile or recompile some files.

in such case, you will result with lines like this one in AMUMSS' report:

[WARN]: MBINCompiler =[[WARN]: File not recognized. You may need to use an older version of MBINCompiler.]


There's sadly not much you can do here but wait for an MBINCompiler update. As AMUMSS is probing at each launch for an MBINCompiler update, as soon as a new MBINCompiler will be released, it will be downloaded and eventually the script or merge of scripts will work.
Be aware anyhow that MBINCompiler is often updated in a few steps and the first few releases after a big update might fix some file conversion but not all of them.
You might then need to wait a bit further for another MBINCompiler update to get your mod or merge of mods to be generated correctly.

If you want to manualy check MBINCompiler status, you can also check this page where you will get details on update progress too.

MBINCompiler has been updated for experimental branch but you're on the public branch

This is the second possible case.
It's more uncommon but it can happen as the developpers sometime release a few experimental updates before pushing the result to the public and stable branch.
As described in this page, No Man's Sky can be experienced via 2 branches : the public (default) branch and the experimental one (via a generic password).
The matter in this situation is that MBINCompiler has been updated for experimental files and can't compile or decompile anymore some of the public files correctly.

Hopefully, there's a workaround in this case. You just need to force AMUMSS to use the latest MBINCompiler made for the public version.

In practice, what you have to do is to follow "General Information for AMUMSS.txt" file and :

  • remove the x before your 'xOPT_CustomMBINCompiler.txt' in AMUMSS' folder
  • replace the MBINCOmpiler.exe file in MODBUILDER folder with the latest version made for the public branch. Here is the link to MBINCompiler release page
  • generate your mod or merged mod as usual


If you did as above, AMUMSS will use the specific version of MBINCompiler you downloaded and everything will work fine.
Just don't forget to rename the OPT file again with a x as soon as a new public version will be released to let AMUMSS downloading latest MBINCompiler version the next time it will be launched, or you will end in the first case described in the section above, using an out of date MBINCompiler version compared to the game version !