Warband Mod Installer Script for Mod Authors (v2.3)

Users who are viewing this thread

Janus

*spicy* *camper*
Administrator
Download it from Here


This script is for mod authors. It is quite simple to use and will create a fairly robust standalone installer for your mod, which will automatically detect the Warband folder and be easy for the end user of your mod to install. Additionally, the created installer executable will tend to be quite a bit smaller than a ZIP file of the same mod.
This script uses the Nullsoft Scriptable Install System (NSIS).

Be sure to view the readme file (readme_installer.rtf) for very detailed instructions on how to use this.

Examples of a default unchanged copy of this installer script in action:

wbmodinstaller1.jpg
wbmodinstaller2.jpg




This installer script is based on my old installer script for the original M&B. Further spiel below:
-----------------------

You know the main Warband setup executable which installs the entire game? It steps you though the installation, asking for the install directory, installing, and creating an uninstaller.
Well, the installer they use was created with the Nullsoft Scriptable Install System (NSIS), which is a free open-source program that I myself have used in the past to create installers for a couple of programs.

Once you've created an installer executable for your mod (which is pretty easy), it will automatically detect where the person installing your mod has Warband itself installed (it gets this from their registry), and defaults to the proper directory.
For example, if your mod was titled "My Cool Mod" and the person had Warband installed to "D:\Games\Mount_Blade Warband 1112", it would default to "D:\Games\Mount_Blade Warband 1112\Modules\My Cool Mod" for the mod installation directory.
Also, when creating your new mod directory, it will actually first copy over all the files from the "Native" module folder before overwriting with your mod files. That way, you can choose to only include the files your mod changes if you want.
-----------------------

EDIT:
By the way, here's an interesting comparison of compression rates using the Native mod as an example.
uncompressed: 72.9 MB
"normal" ZIP: 25.2 MB
"ultra" ZIP: 24.4 MB
installer: 18.2 MB
Of course, RAR and 7Z files can generally do a little better than that, but... not bad.


Upgrade Instructions
If you are using an older version of this script and want to update to the latest version, that's pretty simple.
1. Download the newer version of the Mod Installer Script here, but only extract the Warband Mod Installer Script 2.3.nsi file.
2. Open your older installer script file and this new one you just extracted, and copy and paste the top section of the old file (all the way down to where you see "You probably shouldn't edit below this point") over the top section of the new one.
That's it.


Change List
v2.3:
  • Support for new Data folder.
v2.2:
  • Since some people were still having it not detect Steam versions (possibly they don't have Steam installed properly or similar?), I've added in extra explicit checks for the default Steam installation path rather than solely relying on getting Steam's installation path from the Registry.
  • When version detection failed, it could end up displaying the installed version as "1.[X]"; this has been changed to "(unknown)"
v2.1:
  • Steam release version and path detection were glitchy; they should work fine now.
v2.0:
  • Initial release, based completely off of my previous mod installer script for the original M&B.
 
It looks like the install detection isn't working 100%...not sure if this is due to the fact I'm running on a non-traditional drive letter (M:smile: or if steam changed their software around recently.

My actual install path to warband (including desired mod install folder) is

M:\Program Files\Steam\steamapps\common\mountblade warband\modules\Litus

But the installer once setup only shows

Modules\Litus

If it would be helpful to send you any registry information, let me know what information you need and I'll PM it to you.

 
Strange.

bunnyhop said:
If it would be helpful to send you any registry information, let me know what information you need and I'll PM it to you.
Yes, please, run Regedit.exe and find the following.
If you're running 32-bit Windows, could you give me the path located here:
HKEY_LOCAL_MACHINE\SOFTWARE\Valve\Steam->InstallPath
If you're on 64-bit Windows, it will be here instead:
HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Valve\Steam->InstallPath
 
In your case it should be "M:\Program Files\Steam".
 
Janus said:
Strange.

Yes, please, run Regedit.exe and find the following.
If you're running 32-bit Windows, could you give me the path located here:
HKEY_LOCAL_MACHINE\SOFTWARE\Valve\Steam->InstallPath
If you're on 64-bit Windows, it will be here instead:
HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Valve\Steam->InstallPath
 
In your case it should be "M:\Program Files\Steam".

It is

M:\program files\steam (don't know if the capitalization matters but this is how it is capitalized in the the registry)


Any other information I can provide?
 
OK, I've gone ahead and tested it more thoroughly on my end for the Steam release of WB (though I don't actually have one, I emulated one, so to speak). It was indeed glitched, but it should be fixed now.

Released v2.1:
  • Steam release version and path detection were glitchy; they should work fine now.

Download it here


EDIT:

Upgrade Instructions
If you are using an older version of this script and want to update to the latest version, that's pretty simple.
1. Download the newer version of the Mod Installer Script here, but only extract the Warband Mod Installer Script 2.1.nsi file.
2. Open your older installer script file and this new one you just extracted, and copy and paste the top section of the old file (all the way down to where you see "You probably shouldn't edit below this point") over the top section of the new one.
That's it.
 
Thanks Janus, I am sure this tool will get some good use.....although I completely missed this the first time you posted it.
Also, when does the "Amazing Stuff Mod" come out?.
 
Hey, various people are still having a bit of trouble with this in the hunt thread: http://forums.taleworlds.com/index.php/topic,99562.600.html

Still not sure its working 100% with steam.
 
OK, then.

Released v2.2:
  • Since some people were still having it not detect Steam versions (possibly they don't have Steam installed properly or similar?), I've added in extra explicit checks for the default Steam installation path rather than solely relying on getting Steam's installation path from the Registry.
  • When version detection failed, it could end up displaying the installed version as "1.[X]"; this has been changed to "(unknown)"
 
COGlory said:
So with the Data folder now in the Module Folder, and plans for an update?

Ah, I can do that, I hadn't noticed. It's working? I'll go ahead and release an update shortly here.
 
Released v2.3:
  • Support for new Data folder.


Upgrade Instructions
If you are using an older version of this script and want to update to the latest version, that's pretty simple.
1. Download the newer version of the Mod Installer Script here, but only extract the Warband Mod Installer Script 2.3.nsi file.
2. Open your older installer script file and this new one you just extracted, and copy and paste the top section of the old file (all the way down to where you see "You probably shouldn't edit below this point", which is about 35 lines) over the top section of the new one.
That's it.
 
I suppose something like that could be done, but it would be a pain to set up. What would you have to install which would work on both, anyway?
 
Back
Top Bottom