TESPCD
The Elder Scrolls - Morrowind
Plugin Conflict Detector
by Ely VanReen Soto


***This software is not created by the designers of Morrowind, Bethesda Softworks***

This software is provided "as is" with no expressed or implied warranty.
The author accepts no liability for any damage/loss of business/enjoyment that
this product may cause.


Download Latest Version 0.31 Here

Download Version 0.30

Send Suggestions/Bugs to [ elyvsoto@hotmail.com ] or Write them in the Comment Book
Read Comments

Download the Source Code for Version 0.31
It is a Microsoft Visual C++ 6.0 SP5 Project using MFC.


---How to Use---

There are two modes of Checking Available: Single Versus All and Full Check.

Single Versus All Mode is used to check 1 plugin against another group of plugins. Only Conflicts between your Chosen plugin and the other plugins will be reported. This may assist a plugin maker to verify compatibility with another group of plugins. To select your single plugin select the File menu and then select 'Choose Master'. You may then Select the rest of the plugins by selecting 'Choose Plugins'.

Full Check Mode reports conflicts between all the plugins.

After Selecting your plugins you may begin the Check Operation by selecting 'Check Conflicts' under the Operations menu or by clicking the Red Right Arrow button on the toolbar.

The 'Extract Data' option under the Operations menu can be used to select and load a few groups of plugins at a time before actually running the conflict check.

The Options Dialog allows you to choose which Conflict types you want reported when you run the Check. This dialog can be reached from the Operations menu under 'Options' or by clicking the yellow 'OP' button on the toolbar.

Once your check has been run you can view the conflicting entries in more detail by Double Left Clicking either of the FileNames in either Grid. This can allow you to compare what changes have been made to those entries and let you make a decision of whether to delete it or attempt to merge them.

There are two modes the Viewer can take, Hex View and Grid View.

The Hex Viewer is a Hex Dump of the entry with the 'conflicting' differences highlighted in red. It is a Read Only Viewer.

The Grid Viewer is a formatted Viewer that displays the data in three modes, Hex, Decimal, and Ascii. You may uncheck the read only check box to enable Write mode so that you can edit the entry and save it to your ESP. This can allow you to copy changes from the other conflicting entry in an attempt to make them not conflict. Once your Changes are finished you can click 'Write to Esp' to save your changes. A backup is created with the extension .OLD or a user defined one if it already exists. Note: If you make changes to a field, the data must match the type field in format or unpredictable results will occur. For example:
'Ascii' Mode must contain data in ascii (letters, numbers, and a few other characters)
'Hex' Mode must be in Hexadecimal notation with two characters in the range of 0 to 9 or A to F corresponding to a Byte.
'Dec' Mode must be numeric and must fall within the range of the Byte field. Ex: Byte = 1, then Max Data Number is 255.
'Fixed' Mode is simply Ascii that has a fixed Size. You may not enter more characters than the Byte Count.
'Mixed' Mode contains both Decimal and Ascii Data separated by a '-' character.
The program will do validity checking in all of these cases to try and make sure your data is valid and appropriate.

If you decide to delete a particular entry you simply select the filename and press DELETE on your keyboard or click the 'Delete Entry' button within the pop-up. A backup will be created with the extension .OLD by default. If this backup already exists it will prompt you to overwrite or to save a new backup.

When you run a conflict check you can occasionally encounter 'Marked as Deleted' Entries in the Warning Grid. These are often mistakes left in an unclean plugin. If you look at the entry and decide that this was not supposed to be deleted then you can Delete the 'Marked as Deleted' Entry.

TESPCD may also report Unclean entries in the Warning Grid. These are safe to delete and will minimize conflicts with other plugins. The AutoClean Feature simply automatically deletes all the Unclean Entries that you could delete manually.


Example of Use:

Plugins:
Sris_Alchemy_Trib.esp
Morrowind Additions.esp

Conflict from TESPCD:
CREA , Creature Entry, ogrim, Morrowind Additions.esp, Sris_Alchemy_Trib.esp

Let me state the Objective:
To Get Only 1 Entry that has all the data you want, or Multiple Entries that are Identical, or have the plugin with the entry you want used to be Overriding the Other.

(The last case is done by simply loading up the plugin that you want to be overriding in the TES Construction Set and Saving. This Makes this Plugin have the most recent Save Date.) I will address the other two objectives now.
First I can scan the Sub-Entries and find that Sris_Alchemy has added a new item (random_ogrim_flesh_SA) to the ogrim's loot.
This conflict seems to be easy to correct because this is the only difference between the two entries.

I have few options on what I can do now.

1. I can delete the Morrowind Additions.esp Entry because the Sris_Alchemy_Trib Entry has everything in the other Entry and More. I can then go about my merry way.

2. I can Copy the New Line to the Morrowind Additions.esp Entry and then Click 'Write to ESP'

Let me go into more detail

1. For the first Option: I can open up the Morrowind Additions Entry and click 'Delete Entry'. I can do this and be comfortable because I know that the Sris_Alchemy_Trib Entry is Identical to the Morrowind Additions Entry with the exception of adding a new loot item. (Most cases will likely have additions and differences in each one. You would then have to choose which changes to piece together and keep. Ex. If NPDT was changed in Morrowind Additions that would mean that some of the Ogrim's strengths, HP, etc were changed. If you wanted to keep that change you would want to copy over the NPDT, Data Section over to the Sris_Alchemy_Trib Entry and overwrite its NPDT, Data. One case of this happening is if you had MW_Adv_pass_wildlife.esp which changes the orgrim's strengths, and thus its NPDT Data)

2. For the second Option: I can copy the new NPCO line over to the Morrowind Additions Entry. First I select the row right after the Existing NPCO line and click 'Insert Row' to add a new Blank Row below the Existing NPCO row. Next I go to the Sris_Alchemy Entry and Copy the New NPCO entry (The bottom-most NPCO entry in this case) by selecting the entire line and Hitting Ctrl+C. I then go Back to the Morrowind Additions Entry and Select the entire new blank Row and press Ctrl+V. My two entries now look absolutely Identical. I now can Click the 'Write to Esp' in the Morrowind Additions to save my change.

(Note: In most cases, you have to keep the order of the Sub Entries the way the Construction Set adds them.)


---Frequently Asked Questions---

Q. How do I know which entry is being used in game now?
A. The Overriding Entry Filename is displayed in the Column named 'Overriding Esp File'. This file has the latest Last Modified Date.

Q. I have some great monster plugins but not all the monsters are showing up. What do I do?
A. Download and run the the Leveled List Merger Program by 'Horatio'. If you run it every time you add a new plugin you can ignore all your LEVI and LEVC conflicts.

Q. I keep getting these Dialog warning messages. How do I fix them?
A. One solution is locating the two plugins which have the conflicting Dialogs and combining them using the TES Construction Set. It would also be a good idea to delete and/or merge any conflicting entries before combining them.

Q. How do I safely merge two plugins?
A. Check for Conflicts using the detector and delete any entries that you deem unnecessary. Then combine any entries that you think are important by choosing a master plugin and adding the changes to its entries from the other plugin. Once you are done there, select the two plugins in the TES Construction Set and make sure the master plugin with your changes is the Active one. Once loaded you can select 'Combine Plugins' from the TES Construction Set's menu.

Q. Example: I have two files dog.esp and cat.esp, with dog.esp overriding, that show a conflict because they each reference Animal_chest_02. I decide to keep Animal_chest_02 from Dog.esp and delete the reference from Cat.esp. Does Cat.esp then use Animal_chest_02 from Dog.esp or does that item no longer exist in the Cat.esp plugin? Further If I instead leave Dog.esp as overriding and delete Animal_chest_02 from it will it use Animal_chest_02 from Cat.esp or does Cat.esp need to be set as the overriding plugin?

A. Morrowind loads each and every plugin into memory, discarding entries, which have been overridden. After it has done that, it begins to 'Initialize the Data' and locate all the entries that are referenced. If Animal_chest_02 has been deleted from either of the plugins then it will use the instance loaded from the other plugin or from the Master *.esm files if it exists there. You can run into problems deleting entries if you start to change your mind about what plugins you want loaded. For example, If you decide to not use the plugin dog.esp that contains Animal_chest_02 and decide to keep cat.esp loaded which has had Animal_chest_02 deleted, and the main game files *.esm don't have that entry, you will have an error. It is marginally 'safer' to delete entries that also have an instance in the default game files because it can default back to them.

Q. A couple plugins show some dialogs as being marked as deleted but this area does not seem to indicate why this happens. Is there anyway to tell why this happens as to correct it?

A. Some plugin makers accidentally delete entries from the default game files. I can detect when this happens and report it to you. These occurrences are almost always mistakes but they can also be intentional. Take for example the WeaponsandArmorBalancing.esp plugin that renames many of the standard game weapons to other strange names.

Ex. Dai-Katana to Nodachi or something like that.

Within the esp the original is marked as Deleted and a new weapon entry is created in its place. In this case the Deletion was intended, but I must warn you that in this particular case many problems can arise from renaming the standard weapon entries because there is no telling what will happen when, inevitably, a plugin tries to reference the default weapons.

Q. How do I know which plugin deleted/added/moved a particular object I see in game.

A. While in game, press ~ to get to the console and then move the mouse over the object that you wish to identify. The console title should change to that object's name. Write down that name and insert it into the TESPCD Search Feature with all your active plugins loaded. If the object is not there, Unload the plugins before you start the game to get the Object ID.

Q. I want to view all the data in a file like TESAME

A. First Load up the file you want to view or all the files you want to view. Next Select, View File in the Editor Menu and select your File.

Q. How do I remove An Object that was added or deleted by a plugin?

A. First find out the Cell you are in and run a search for it or locate it in View File. Next Look in that Cell and Locate a NAME with an ID that matches your object. You can verify that it is an Object Edited from a Master File by looking at its FRMR. The last two Hex digits will be 01 if it was originally in another file. If you want to delete the Changes to that Object, Delete the Rows from and including the FRMR prior to the NAME and all the Rows until the next FRMR.

Q. I keep running the conflict check and find LAND - Landscape conflicts. Does this mean I cannot run these two plugins together?

A. A Landscape conflict occurs when two plugins modify the Landscape of a particular Cell. One may only paint a different texture on the ground, while the other may make a mountain or a lake in that Cell. Only one change will occur which may leave objects stuck under ground or under water. It may be almost harmless if they both just paint new textures in that cell.

Q. How do I resolve LAND - Landscape conflicts?

A. It takes some skill to carefully delete Landscape changes and then repairing edges in the Construction Set. If you just delete Landscape changes you may encounter bad Cell Landscape edges. Furthermore, you may have to move some of the objects around to compensate for the changes. You can check this with the Landscape Error Checker in the Construction Set.

Q. I deleted a bunch of entries why doesn't my plugin work anymore?
A. Before you delete an entry look at its details within the viewer and/or the TES Construction Set to make sure its not a vital entry or change.

Q. I have a good idea about how this program could work better. What do I do?
A. Email Me at elyvsoto@hotmail.com.


---Features---

Morrowind plugin (ESP) files contain entries of new or changed objects that the plugin adds to the game. These entries are identified by an 'ID' and a 'Name' by Morrowind. If any two plugins are loaded that contain the same ID-Name combination then Morrowind will only use the plugin file with the most recent 'Last Modified' date. Those entries that are omitted can cause problems for the plugin they were intended for. These problems can be minor, such as a weapon doing less or more damage than it intended, or it can be major, such as a Script not running when intended.

This program 'TESPCD' detects these conflicting ID-Name combinations and reports them to the user. The user can then see the entries that conflict by double-left clicking the filenames in the graph in both a Hex and Grid type format.

With this information plugin makers/users can either modify their plugins to avoid the conflicts or the users can manually choose to delete or combine the entries to allow the plugins to function together.

Occasionally Plugins have entries that are identical to entries present in the original game. While it may not hurt this particular plugin, there may be another plugin that is overridden because of these unnecessary entries. This program can detect these unnecessary entries and let you delete them. The program can also AutoClean the plugin for you.

1. Locates Conflicting entries for the following Objects:

 ACTI - Activators
 ALCH - Alchemy/Potions
 APPA - Apparatus
 ARMO - Armors
 BODY - Body Parts
 BOOK - Books
 BSGN - Birth signs
 CLAS - Classes
 CLOT - Clothes
 CONT - Containers
 CREA - Creatures
 DOOR - Doors
 ENCH - Enchantments
 FACT - Factions
 GLOB - Globals
 GMST - Game play Settings
 INFO - Dialog Text
 INGR - Ingredients
 LAND - Landscape
 LEVC - Creature Leveled Lists
 LEVI - Item Leveled Lists
 LIGH - Light Types
 LOCK - Lock picks
 MGEF - Magic Effects
 MISC - Miscellaneous Items
 NPC_ - NPCs
 PGRD - Path grids
 PROB - Probes
 RACE - Races
 REGN - Region Settings
 REPA - Repair Tools
 SCPT - Scripts
 SKIL - Skills
 SNDG - Sound Gen
 SOUN - Sounds
 SPEL - Spells
 STAT - Static Objects
 WEAP - Weapons

2. In addition to those above, Allows you to view the following Entries:

 CELL - Interior/Exterior Cells
 DIAL - Dialog Topics

3.  Ability to View Conflicting Entry Data if you double click on the filenames in the Grid.

4.  Reports Entries that are marked as Deleted in a separate Grid. These should be monitored closely since these are often mistakes.

5.  Ability to Delete Reported Entries if you select a particular filename and press DELETE. It will Backup your esp with the extension .OLD or your own specified filename if .OLD filename already exists.

6.  Ability to edit and modify entries.

7.  Detection of Unclean Entries and an Automatic Plugin Cleaner

8.  Search tool so you can locate any object in any plugin or Master File

9.  View Changes made to Master Esm Files



---Proposed Features---

1. Viewing and modifying an entire Esp File
2. Optional Reporting of Cell Object Deletions.
 (Someone puts a house and decides to delete a NPC that was standing there)
3. Highlighting Differences in Entry Views
4. Conflict Resolver Wizard
5. Save Game Cleaner



---Version Details---

V0.31
 Added ability to add ESM Master Files to conflict Check.
 Added option to report 'Unclean Dialog Text'

V0.30
 Moved Out of Beta
 Added a Search Function for Loaded Esp and Esm Files
 Added ability to detect Dialog Text Conflicts
 Added ability to detect Landscape Conflicts
 Added ability to detect Path Grid Conflicts
 Added ability to View all Changes made to Original Esm Files
 Added Ability to View A Single File's Data similar to TESAME
 Added better View Management
 Fixed Overflowed Buffer Bug while Writing to Entries
 Fixed Major Bug while Updating Entries
 Fixed Various Misc. Bug Fixes
 Added additional Error Checking

V0.26 Beta
 Fixed Bugs with AutoCleaner

V0.25 Beta
 Added Unclean Entry Detection
 Added an Unclean Entry AutoCleaner (You can manually inspect and delete as well)
 Added Viewing of Original Entries to allow you to compare to original data
 Added Viewing of Item and Spell Data in Ascii Mode for Creatures and NPCs
 Fixed Printing and Clipboard Commands on Warning Grid
 Fixed Memory Leak while Deleting

V0.201 Beta
 (Common)Fixed Writing Entry Data Under Windows 95/98/ME
 Reenabled Clipboard commands on Main Grid
 (Rare)Fixed a Major Bug where Plugin Data would not Extract Correctly and not all Conflicts would be reported.

V0.20 Beta
 All New Entry Dialog to Ease Entry Viewing
 Ability to Edit Entries and Save them to your Plugin
 (This allows you to Copy and Paste Across Plugins to Ease Plugin Compatibility)
 Updated Backup Code to be less annoying
 Option Settings Now Saved in INI File
 Various Minor Bug Fixes

V0.19 Beta
 The Plugin Entry that is Overriding will be displayed in the First Column with the name 'Overriding Esp File'
 Entry Deletion Reporting in a Warning Grid.
 Deletion of any Reported Entry - Press Delete while a particular Filename in a grid entry is selected
 Backup Code for Deletion Sanity
 GUI Touches
 Misc. Bug Fixes

V0.181 Alpha
 Quick Addition to Hex Viewer showing changes between the entries in Red

V0.18 Alpha
 Added Options Dialog to choose which Conflicts to Display
 Added Hex Viewer to see Entries if you Double-Left-Click on the Conflicting Filenames
 Added Right-Click Context Menus to Tree File View to Remove and Add Plugins more easily
 Added Ability to do new checks without restarting the application
 Fixed a bug that froze the Operations
 Fixed other misc. bugs

V0.17 Alpha
 Improved Accuracy of Conflict Detection *Much More Accurate Now*
 This is done by a byte by byte comparison of all the data
 in the conflicting entries
 Added Detection for a few more entries

V0.16 Alpha
 Optimized Data Extraction Functions
 Added Detection for many more entries
 Added Single Versus All Mode of Detection for Plugin Makers
 Fixed Could not select more than 1000 characters in filenames in Open Dialog

V0.15 Alpha
 -Reworked GUI-
 Enabled Print/Print Preview
 Added Ability to Sort GRID (Click on Fixed Grid Row to Sort)
 Added Easier File Addition
 Added Progress Bar

V0.10 Alpha
 Initial Release



---Issues---

1. No Known Issues



---Not Supported in Near Future---

1. Ability to Check Overlapping Objects on the Map