NWN2 Inventory Sorter 1.0.0 By Ratanak Lun, Feb 2012 Contents ======== I. Overview II. Installation II.a. Requirements II.b. Instructions III. Usage III.a. Important III.b. Sorting III.c. Configuration III.d. Criteria IV. Customization IV.a. Order Table IV.b. Scripting V. Technical Information V.a. Implementation V.b. Limitations I. Overview =========== Neverwinter Nights 2 is a great game with many interesting features, but one thing it lacks is control over inventory sorting. As it stands, the sort ordering is predefined and although it offers ordering with some frequently used items occurring first, it is not suitable for all players. The NWN2 Inventory Sorter (NWN2IS) is an engine that attempts to address this issue by allowing players more control over sort ordering. It also features the ability to sort containers in the inventory such as magic bags. Through an in-game interface, players are given a choice of which criteria they would like to use to sort each of their characters' inventories. Each character is given their own personal settings. If the available criteria are not enough, with a little scripting knowledge, it is possible to add additional criteria. Customization by way of table editing is also available for those who would rather not do scripting. II. Installation ================ Requirements ============ NWN2IS was developed and tested with the English version of Neverwinter Nights 2 Platinum (which includes the Mask of the Betrayer and Storm of Zehir expansions). However, theoretically, it should work with any version of Neverwinter Nights 2 updated to the latest version. In terms of system requirements, they are the same as the requirements for Neverwinter Nights 2. If you can run NWN2, you should be able to run the NWN2IS. NWN2IS has not been tested with multiplayer. Instructions ============ Copy the contents of the zip file into one of your Neverwinter Nights 2 ‘override’ folders. It is highly recommended that you use the ‘override’ folder in your user path (e.g. My Documents). Once copied to your 'override' folder, unless you have a custom inventory screen, you are ready to use the NWN2IS (see Usage). NWN2IS comes with a modified inventory screen file (inventoryscreen.xml) based on the one included with the original Neverwinter Nights 2 campaign. If you are using a mod or playing a module that has its own custom inventory screen, then you will have to make the following adjustments to get things working: 1. Make sure the inventory screen file of your choice is the only one in your override folder. 2. Open the inventory screen file in a text editor. 3. Make the file available to scripting functions. You do this by adding the ‘scriptloadable’ attribute to the UIScene element in the file. You will usually find the UIScene element near the top of the file. The other attributes should be left untouched. In this example, I've added the attribute at the end: 4. Find the sort button. The location of the button depends on your inventory screen file. For the original campaign inventory screen file, you can find the appropriate button by doing a search for 'SORT_INVENTORY'. Searching for just 'sort' may also work with your custom screen file. If you can't find it, check with the author of the file. 5. Once you find the button, you need to modify the 'OnLeftClick' and 'OnRightClick' callbacks so that they call the NWN2IS scripts (see below). The following example uses the original campaign inventory screen file: Original Button ---------------