Neverwinter Nights Installer Tool (NIT)


#21

@Shadooow
I am not sure how I would be able to detect what components belong to specific Mods (such as CEP2), so at the moment, I can’t see how to automatically create Mods from already installed components.

You can share Mods by exporting the Mod on one PC and then Importing the exported Mods on another PC. I have not tried this approach between different users logging onto the same machine, so I am not sure how that might work (assuming each user has different NWN and NIT installations). You can also have multiple Profiles and export and import Mods between the Profiles. Each Profile can specify a different NWN installation (for Beamdog’s EE, you can also specify a different User Files folder).

Instead of using Add to include already installed files, you might want to Create a Restorer and then copy the files for each Mod to NIT’s Mod Folder. This is described in the Help (Deal with existing installed Mods and Create NIT Mods from Restorers).

Another approach you could use is to create Mods from installed content is to Create a Restorer, then delete the files you want for your Mod from the Restorer’s Mod Installer folder. Having done this, use Create Restorer again to create a Restorer that has the files you want to include in your Mod (ie the one you deleted from the previous Restorer’s Mod Installer folder).

Add should default to the folder you specified on the Locations page in Settings. The default should be your browser’s default download folder (usually C:\users\UserName\Downloads). If it starts at C, it probably means that NIT could not determine your Downloads folder location. Use Settings to specify where it should start.

Add is intended to always start at the folder specified in Settings (because, usually, this where you download files from the Internet).

Hope this helps.


#22

@Shadooow
Just for the record, why do you want to create Mod Installers for your installed Mods?

My approach would be…

  1. Create a Restorer to backup all relevant files.
  2. Create Mods only when I want to play specific games (and only copy the .mod or .nwm files to the Mod Installer).
  3. Use NIT to create Installers for new mods that I download.

#23

btw would be NIT able to install packages that needs to add haks/tlk such as PRC (Lite) into modules/campaigns?

Override version of such project has many side issues so I didn’t make it an override. But not everyone is able to install it and use it then…


#24

@Shadooow
NIT can certainly build an Installer that would place the files in the correct folders (you would need to define DLL in the Extension Map as described in the Help).

NIT can also deal with making the hak into a patch hak and automatically insert the required entries into the relevant ini file.

I am not sure if I have answered the question or whether there is more that would be required.

Does this help?


#25

What PRC (Lite) and other mods needs is to add the hak files +tlk into module’s properties. That means opening the module in toolset, adding haks/tlk and saving it. And it is much more complicated with official campaigns.


#26

@Shadooow
Currently, NIT is not able to perform this type of operation. It might be possible if there was a way to duplicate what the toolset does. I don’t know whether the toolset (or any other utility) has a command line interface that could perform these operations or not (I don’t think it does).

I am open to suggestions as to how this could be automated, but I don’t have the knowledge to figure out how this could be achieved.


#27

moneo can do that


#28

@Shadooow
Thanks for that. Only issue is that, if I understand correctly, every mod would need to be updated for PRC Lite to work. Not sure whether this should be enabled or not (also, would need help with Moneo if I decided to proceed),

Interested to hear what you think.


#29

my though was that NIT would gave option to the player to which module he wants to install it or something like that

though in fact only TLK is a problem here, PRC can be used as patch-hak but there is no such functionality for TLK…


#30

Thanks @Shadooow, will think about this one. If/when I start on this, will need help with Moneo.


#31

Download Automation Progress

The purpose of sharing the progress I have made so far is to encourage feedback and comments during the development phase.

You start the process by selecting Download Project from the File menu and specify the Project’s page URL The file attachments and required project files are established by processing the Project page. The result of this processing looks like this…

The Download button will create the necessary NIT Mod Folders, download the files directly into the Downloads sub-folder and create a Mod Installer.

The Install button performs the Download first and then Installs the Mod.

I have also created a Download Rules file that helps NIT establish which files should be downloaded. The intention is to upload this file to a web site so that it can be updated on a regular basis (hopefully, with community contributions). The purpose of the rules is to try and reduce user input as much as possible. The Preferences page in Settings will allow users will to disable some or all Rules.

This is what the Rules file looks like so far…

' Increment the Revision Number each time you upload the DownloadRules.txt file.
RevisionNumber = 1

' ============================================================
' Rules that apply to all projects
' ============================================================

' Defines Project Urls that should be redirected to improved or updated Projects
Redirects

  ' Recommended version for CEP v1.x compatibility
  OldUrl = https://neverwintervault.org/project/nwn1/hakpak/combined/cep-v1x-installer
  NewUrl = https://neverwintervault.org/project/nwn1/hakpak/cep1-complete
  
  ' Improved and fixed version of the Abyss Tileset
  OldUrl = https://neverwintervault.org/project/nwn1/hakpak/tileset/abyss-tileset
  NewUrl = https://neverwintervault.org/project/nwn1/hakpak/tileset/abyss-tileset-redux

End Redirects

' Defines rules that will be used to exclude files from all Projects.
ExcludeRules

  ' Any file description that contains one of the specified strings will be excluded
  ' from the Project Download list.
  ' Use the double quote character (") to specify strings that contain spaces.
  
  Contains
    outdated
    " old "
    "(old "
    " old)"
    obsolete
  End Contains
  
  ' Any file description that starts with one of the specified strings will be excluded
  ' from the Project Download list.
  ' Use the double quote character (") to specify strings that contain spaces.
  
  StartsWith
    "old "
  End StartsWith
  
  ' Any file name that has one of the extensions specified below will be excluded
  ' from the Project Download list.
  '
  ' Note:
  ' You must include the leading period (eg .txt).
  ' Use the comma (,) to delineate multiple extensions.
  
  Extensions = .txt
  
  ' List of file names that will be excluded from the Project Download list.
  
  Filenames
  
    ' This ensures that shipinteriortga.rar is downloaded.
    shipinteriordds.rar
  End Filenames
  
End ExcludeRules

' ============================================================
' Common Projects
' ============================================================

' Added 28 Aug 2018 by Surazal
Project = CEP 2.65 (Community Expansion Pack)
    ModFolder = CEP v2.65
    Group = 100.  Community Packs
    Downloads
      cep_2_65_full.7z
      cep2_2_65_quickfix.7z
    End Downloads
End Project

' Added 29 Aug 2018 by Surazal
Project = CEP1 Complete (Pre-Release)
  ModFolder = CEP v1.x Complete
  Group = 100.  Community Packs
  Downloads
      cep1complete.7z
    End Downloads
End Project

' Added 28 Aug 2018 by Surazal
Project = Project Q
    ModFolder = Project Q
    Group = 140.  Common Resources
    Downloads
      q2.2_full.7z
      qv2.2.2_patch.7z
    End Downloads
End Project

' ============================================================
' Playable Mods
' ============================================================

' Added 28 Aug 2018 by Surazal
Project = The Accursed Tower
  ModFolder = The Accursed Tower
  Group = 810.  Evaluating
  Downloads
    at_music_1b.rar
    at_music_2.rar
    at_music_3.zip
    at_music_4.zip
    tat_hak_2.9.rar
    tat_heads_2.4.rar
    tat_wms_crts_2.2.rar
    tat_wthrough_5.6.rar
    the_accursed_tower_q_8.4.rar
    End Downloads
  RequiredFiles From Wild Woods [v0.7] & Wild Lands Tilesets
    winterwildlands055.7z
  End RequiredFiles
End Project

' Added 29 Aug 2018 by Surazal
Project = The Icemaiden - Prelude
  ModFolder = The Icemaiden
  Group = 810.  Evaluating
  Downloads
    the_icemaiden_prelude_v2._1.7z
  End Downloads
End Project

Your comments and feedback will be very welcome and much appreciated.


#32

Download Automation Progress 11 Sep 2018

Biggest issue so far is that the Vault’s file download count is not incremented when the file is downloaded programmatically. This is making me doubt whether the Download Project feature should be released.

Does anyone know how I can increment the Vault’s download count programmatically?

Some screenshots

Enter the Project’s URL and click Retrieve.

Change or accept the files marked for downloading and click Download.

The marked files are downloaded.

Here is the latest version of the Download Rules file.
’ ============================================================
’ Configuration Information
’ ============================================================

' Increment the Revision Number each time you upload the DownloadRules.txt file.
RevisionNumber = 1

' URL validation definitions.
VaultDomain = //neverwintervault.org/project/nwn1
OldVaultDomain = //neverwintervault.net/project/nwn1

' String appended to Project Title.
VaultTitleId = " | The Neverwinter Vault"

' ============================================================
' Rules that apply to all projects
' ============================================================

' Defines Project Urls that should be redirected to improved or updated Projects
Redirects

  ' Recommended version for CEP v1.x compatibility
  From = https://neverwintervault.org/project/nwn1/hakpak/combined/cep-v1x-installer
  To   = https://neverwintervault.org/project/nwn1/hakpak/cep1-complete
  
  ' Latest version of CEP is compatible with previous versions starting with v2.1
  From = https://neverwintervault.org/project/nwn1/hakpak/combined/cep-23-cep-24
  To   = https://neverwintervault.org/cep
  
  ' Improved and fixed version of the Abyss Tileset
  From = https://neverwintervault.org/project/nwn1/hakpak/tileset/abyss-tileset
  To   = https://neverwintervault.org/project/nwn1/hakpak/tileset/abyss-tileset-redux

End Redirects

' Defines rules that will be used to exclude files from all Projects.
ExcludeRules

  ' Any file description that contains one of the specified strings will be excluded
  ' from the Project Download list.
  ' Use the double quote character (") to specify strings that contain spaces.
  
  Contains
    outdated
    obsolete
  End Contains
  
  ' Any file description that starts with one of the specified strings will be excluded
  ' from the Project Download list.
  ' Use the double quote character (") to specify strings that contain spaces.
  
  StartsWith
    "old "
  End StartsWith
  
  ' Any file description that ends with one of the specified strings will be excluded
  ' from the Project Download list.
  ' Use the double quote character (") to specify strings that contain spaces.
  
  EndsWith
    " old"
    " old."
  End EndsWith
  
  ' Any file name that has one of the extensions specified below will be excluded
  ' from the Project Download list.
  '
  ' Note:
  ' You must include the leading period (eg .txt).
  ' Use the comma (,) to delineate multiple extensions.
  
  Extensions = .txt
  
  ' List of file names that will be excluded from the Project Download list.
  
  ' This ensures that shipinteriortga.rar is downloaded.
  ExcludeFiles From Ship Interior Tileset
    shipinteriordds.rar
  End ExcludeFiles
  
End ExcludeRules

' Filenames specified in this list will be be prefixed by the Project Title
' to ensure that the downloaded filenames are unique.
' Extension names should not be included.
PrefixFilenames
  WalkThrough
  Walk Through
  ReadMe
  Manual
  Guide
  Hints
End PrefixFilenames

' ============================================================
' Common Projects
' ============================================================

Project = CEP 2.65 (Community Expansion Pack)
    ModFolder = CEP v2.65
    Group = 100.  Community Packs
    Downloads
      cep_2_65_full.7z
      cep2_2_65_quickfix.7z
    End Downloads
End Project

Project = CEP1 Complete (Pre-Release)
  ModFolder = CEP v1.x Complete
  Group = 100.  Community Packs
  Downloads
      cep1complete.7z
    End Downloads
End Project

Project = Project Q
    ModFolder = Project Q
    Group = 140.  Common Resources
    Downloads
      q2.2_full.7z
    qv2.2.2_patch.7z
    End Downloads
End Project

Project = Community Music Pack
  ModFolder = CMP Community Music Pack
    Group = 100.  Community Packs
    Downloads
    cmp_v1.0.full_.zip
    mus_cmp143.bmu
    mus_cmp266.bmu
    End Downloads
  If 1.69 Downloads
      cmp_hak_169.zip
  End If
  If 1.68 Downloads
      cmp_hak.zip
  End If
End Project

Project = D20 Modern Haks Version 2.1
  ModFolder = D20 Modern Haks v2.1
    Group = 140.  Common Resources
End Project

Project = D20 Modern Haks Version 2.2
  ModFolder = D20 Modern Haks v2.2
    Group = 140.  Common Resources
  
  ' These commands must follow any Downloads rules.
  
  ' Include ERF files when the user has disabled the
  ' "Exclude non-Texturepacks ERF files" on the Preferences page in Settings.
  If ERF Downloads
    d20_modern_update_erf.rar
  End If
End Project

Project = D20 Modern 1.3/1.4 Classic (IGN Vault Backup)
  ModFolder = D20 Modern v1.3, v1.4
  Downloads
    d20_modern_classic_-_aio.7z
  End Downloads
End Project

' ============================================================
' Playable Mods
' ============================================================

Project = The Accursed Tower
  ModFolder = The Accursed Tower
  RequiredFiles From Wild Woods [v0.7] & Wild Lands Tilesets
    winterwildlands055.7z
  End RequiredFiles
End Project

Project = The Icemaiden - Prelude
  ModFolder = The Icemaiden
  Downloads
    the_icemaiden_prelude_v2._1.7z
    End Downloads
End Project

Project = Rogue Trader - Legends and Lies (A D20 Modern Campaign)
  ModFolder = Rogue Trader - Legends and Lies
  RequiredFiles From Lord of Worms Tilesets and Arbor Falls PW Server Haks
    wrm_seasonalv10.7z
  End RequiredFiles
End Project

Project = Rogue Trader - Whispers on the Storm (A D20 Modern Campaign)
  ModFolder = Rogue Trader - Whispers on the Storm
  RequiredFiles From Lord of Worms Tilesets and Arbor Falls PW Server Haks
    wrm_seasonalv10.7z
  End RequiredFiles
End Project

' ============================================================
' Required Projects
' ============================================================

Project = The World of Avlis
  Downloads
    avlis_allinone_201809.7z
  End Downloads
End Project

Feedback, suggestions and comments are welcome.


#33

Solved the download count problem - simply needed to use the https://neverwintervault.org/sites/all/modules/pubdlcnt/pubdlcnt.php?file= and the file Id (Nid).

It is all working now - just need to update the Help file and finalise the code.


A simple vault installer proposal
#34

I have completed the changes to support downloading and installing from the Neverwinter Vault’s Project pages.

I would very much appreciate any contributions to the Project Download Rules File available from NIT’s Project page.

You can either post corrections, suggestions or new Project Definitions here, or use PM to provide me with the information.

Many thanks for any help.


#35

Revision 2 of the Project Download Rules File is available for download from NIT’s Project page.

Revision 2 supports new Project definition statements and includes additional Project definitions, which are now sorted alphabetically. Revision 2 also documents available statements that can be used to define Project Rules.

I do hope you have the time to review the Rules and provide me with any corrections, suggestions and recommendations.

If all goes well, I hope to release NIT v5.2 on 21 September.

The Rules file is stored on a personal web site and revisions to the Rules file will be independent of NIT releases and will not require users to perform any downloads. In its current form, changes would have to be submitted to me for inclusion in the Rules file used by NIT. However, I am open to any alternative suggestions.

Many thanks for any help.


#36

The Neverwinter Nights Installer Tool version 5.2 has been released and is available for download from the Project page.

The key feature of this release is the ability to download and install mods and required files directly from The Neverwinter Vault site’s Project pages as well as an updated Installation Analyser Tool, which can be used to view and delete Extended Edition crash information. The release also contains a number of bug fixes.

Features

  • Download and/or install Neverwinter Vault Projects and associated required Project files.
  • New Preferences added to control which rules are applied when downloading Neverwinter Vault Projects.

Improvements

  • The Installation Analyser Tool can be used to view and delete Extended Edition crash information.

Miscellaneous

  • Help updated to reflect the changes made to the Installation Analyser.
  • Help updated to provide information on downloading Neverwinter Vault Projects.
  • Help updated to reflect other changes that have been made since the last release.

Bug Fixes

  • Prevent rare crash when closing NIT.
  • Prevent crash when recording time played and the game has not been saved.
  • Correct erroneous display of list tooltip.
  • Prevent random crash after Publishing a Mod.
  • Ignore Update Downloads requests for Group items.
  • Fixed the Mod Explorer displaying the wrong Notes text when typing rapidly into the Mod Filter.
  • Hide the Properties Panel when the Details Panel does not have any items listed.

#37

Here are some screenshots that illustrate my current thinking on providing a simpler way to use NIT (as per @pscythe’s original comment). I would very much appreciate any feedback and suggestions.


#38

I hope to release v5.3 tomorrow.

Here is some information about the changed interface - any feedback is very welcome.

The Ribbon interface is intended to make it easier to find and perform key operations. The functions on each tab are arranged in the sequence you are most likely to follow when performing a set of tasks.

Play Tab
This contains functions you are likely to use the most.

Work with Mods
Use this tab when you want to create and manage a Mod manually. Typically, you would use these functions when downloading Mods from a non-Neverwinter Vault site.

Diagnose
Use the functions on this tab to view information that may help resolve an issue you are experiencing. For example, when a Mod fails to load, you can view the Neverwinter Nights Log File to identify which file is missing.

Backup and Recovery
Use this tab to Create Restorers, Export your Settings and Backup or Restore the Installer Tool’s database files. If you have added Mods or made changes to Ratings, Notes, etc, perform a backup before your close the Tool.

Customise
This tab provides access to functions you can use to change the Installer Tool’s behaviour and user interface.

The Change Behaviour… button opens a new Basic Settings dialogue.
image

The Change Text… button opens a new simplified dialogue
image


#39

The Neverwinter Nights Installer Tool version 5.3 has been released and is available for download from the Project page.

The key feature of this release is the Ribbon interface, which is intended to make it easier to find and perform key operations. Other changes include a Basic Settings dialogue, a simplified Font and Colour Editor, new Download Rules statements, improved Download Project error handling as well as the resolution of various issues.

Features

  • A ribbon-like interface has been implemented to make it easier to find the functions most commonly performed.
  • The Font and Colour Editor has been simplified to make it easier to make changes to the text size and switch to monochrome colours. The advanced editor is still available from the new one.
  • The Basic Settings dialogue has been implemented to make it easier to customise key preferences and user interface configuration options.

Improvements

  • Download Project includes refined error handling for Required Project web address issues.
  • Download Project status line includes a time estimate for the files marked for download.
  • New Download Rules statements implemented.
  • Extensions to Download Rules condition statements implemented.
  • Eliminated an unnecessary prompt for a Game Save’s Mod name when certain criteria are met.

Miscellaneous

  • Help updated to reflect the new features.
  • Map exceptions updated to accommodate Streamlined User Interface Fog Removal file.

Bug Fixes

  • Correct URL validation to reject addresses that do not start with https.
  • Ensure downloaded Mods are always selected and visible in the Mod list.
  • Installers are not created when one or more download errors have been detected.
  • Prevent migration from unsupported versions of NIT (ie pre-v4.0.6).
  • Additional changes to prevent crash when closing NIT caused by timing problem.
  • Prevent crash creating an Installer when a specific combination of directory and extension names are met.
  • Addressed an issue that caused the wrong font sample text to be displayed when opening the Advanced Font and Colour Editor.
  • Prevent crash when creating a Restorer for a Mod Folder that does not have an existing Mod Installer folder.

#40

I have uploaded a Notepad++ User Defined Language for viewing NIT’s Download Rules File, which is available for download from the Project page.