I'm posting here a version of my Testing Guide tailored for More Naval AI. I wasn't sure about the bits about Assert errors (in ExtraModMod I have been released beta versions with asserts enabled) but I left them in for this first version. The log filenames it mentions are the ones from the improved logging patches I submitted so I think this guide should be meant for 2.53.
I added the guide as a concept page ingame in ExtraModMod. Once that the offline version reaches a definitive version it should be easy to code this for More Naval AI too if there is interest for it.
--------------
Testing Guide
This guide is meant for anyone who is interested on being able to provide more information along with bug reports, in order to help with improving More Naval AI.
Configuration
Civilization IV allows to enable the generation of different files that can be very helpful in order to check why a certain bug happened. To enable them, you need to modify your CivilizationIV.ini file (usually found in the "C:\Users\(USERNAME)\Documents\My Games\Beyond the Sword" folder). The following values should be set from 0 to 1:
GenerateCrashDumps: Generates a dmp file when the game crashes to desktop. These dumps are very useful for debugging crash to desktop (CtD) errors.
LoggingEnabled: Allows the game to create logs. This is essential for reporting all kind of bugs.
SynchLog: Enables synchronization logging. These logs are specially important for checking errors in multiplayer games.
OverwriteLogs: Logs are overwritten each time the game is restarted. This allows to discard old logs easily, but bear in mind that you should copy any logs related to an issue before you restart the game or they will be lost.
RandLog: Enables random event logging. These logs are specially important for checking errors in multiplayer games.
Additionally, the following values should be set from 1 to 0:
HidePythonExceptions: Disabling this will allow to show python errors ingame.
When playing with beta builds, it is strongly advised to set the following option to 0:
FullScreen: Controls if the game will be shown on fullscreen or not. When playing with a build that will display Asserts (like beta versions), it is better to put the game in a window as sometimes Assert windows will lock the game if it is in fullscren.
When a player enables logging and logs into a multiplayer game, other players will get a message saying "Player X has logging enabled. Verify that this is a trusted player". I don't know why the game throws this warning (logging seems harmless to me) but if you are playing with more people they should be aware of why this message is being shown. Bear in mind that in order to debug OOS issues properly all players should enable logging.
Logs appear in the "C:\Users\(USERNAME)\Documents\My Games\Beyond the Sword\Logs" folder.
Reporting bugs
Bugs can be reported in either the
Bug Tracker by creating a new issue and uploading all pertinent information, or directly at More Naval AI's
bug reports thread. OOS errors should be reported in the bug tracker or in the
OOS discussion thread. In the following sections of this document you can find more information on how to report each kind of issue.
If you are unsure about which kind of issue you are experiencing (or it just does not fit into any of the types described below), just make a report including a description of the issue explaining what you think that went wrong along with any information you think that is relevant. Keep a backup of the "C:\Users\(USERNAME)\Documents\My Games\Beyond the Sword\Logs" folder just in case any of them is relevant of the issue (you will be asked for specific files in that case).
Assert errors
Asserts are warnings that may be the cause of bugs. They are only shown when playing with beta versions. Assert errors can appear either when the game is being initialized or during a game, and they appear on popup windows that look like this:
It is possible for MapScripts to cause assert errors. These errors will happen during map generation or, in the case of using MapScriptTools, while the game is being initialized. In these cases, you can safely ignore the assert. In all other cases, assert errors should always be reported. It is usually enough information to copy the text inside of the assert error window and paste it on the bug report. If the error happened right after something specific was done, it is also helpful to know about it.
Python errors
When
HidePythonExceptions is disabled, python errors are shown ingame in a popup like the one shown below:
It is possible to get multiple popups on top of each other instead of a single one. In the case of a python error, it is better to provide the log files PythonDbg.log and specially PythonErr.log in the bug report than a screenshot of the error.
AI errors
You may notice the AI doing something weird or just wrong. In this case, the bug report should include a description of what you consider wrong, what you expected, a screenshot showing the problem (or even better, a savegame) and the "BBAILog - (PLAYERNAME).log" file.
Crash to Desktop
When the whole game crashes, every log (the entire contents of "C:\Users\(USERNAME)\Documents\My Games\Beyond the Sword\Logs") should be included in the bug report. If the game allows you to generate a crash dmp file, always select "generate a full dump" and attach it to the bug report too. dmp files appear after a CtD in the folder in which Civ4BeyondSword.exe is in. For complete editions of Civilization IV, this folder is: "C:\Program Files (x86)\2K Games\Firaxis Games\Sid Meier's Civilization 4 Complete\Beyond the Sword".
OOS errors
OOS errors happen only in multiplayer games. They are the hardest ones to reproduce and fix, and therefore any information about them is very welcome. OOS errors are very noticeable when they happen; all players will see a big notice announcing the OOS in red letters in the bottom part of their screen. To report an issue of this type, the SynchLog and the OOSLog of **EACH PLAYER** (called "SynchLog - (PLAYERNAME)" and "OOSLog - (PLAYERNAME) - Turn N.txt" respectively) are required. The "BBAILog - (PLAYERNAME).log" file should also be sent, if present, as OOS errors may sometimes be caused by errors in the logic of the AI code. An autosave from a few turns before is also very useful.