*In Patch 8, Larian seems to have changed the editor to add semicolons to the ends of conditions that determine (among other things) what spells can target and if various features are active. These semicolons don't belong there, by convention both from programming languages and from how most BG3 conditions still look, and all did prior to Patch 8. The game accepts and ignores them, but they provide no benefit.
What they do is mess things up for mods.
Some mods (including several of mine) need to modify conditions elsewhere in the game. Now they all have to handle these semicolons when making their changes, or the modified condition may not work correctly.
My mods do this, but there are others that don't, and I keep getting questions and "reports" about the warnings that my mods print when they encounter problems caused by other mods. So...*
The primary purpose of this mod is to serve as a place where I can document the situation and tell you to update your mods!, but failing that it can work around some issues with rogue semicolons in conditions, to stop outdated mods breaking current ones.
It removes all trailing semicolons from conditions, so they don't trip up mods that don't expect them.
It repairs any damage already caused by some of the most obvious naive modifications applied to trailing semicolons.
- If you are only using well-made, up-to-date mods, you don't need this.
- If you are using mods that modify conditions and haven't been updated since Patch 8, it should help with any related issues.
- Outdated mods may have other issues than stumbling over unexpected semicolons in conditions. This mod can't help with that.
- Some mods are just poorly made and contain syntax errors from the start. This mod can't help with that.
Details
A typical spell's TargetConditions may be something like
Character() and not Dead()
A mod may then end up patching the condition to something like
Character() and not Dead() and ExampleMod_TargetCondition()
Before Patch 8, it would be enough to simply append " and ExampleMod_TargetCondition()".
With Patch 8's trailing semicolons, the original condition may be
Character() and not Dead();
Naively appending then produces
Character() and not Dead(); and ExampleMod_TargetCondition()
That semicolon now in the middle of the condition is a problem.
Ideally, conditions shouldn't contain trailing semicolons, and mods that modify conditions should remove them if found.
(Some mods handle this by *pre-*pending the extra condition instead. That's generally not a good solution, as the condition order determines which error message is displayed.)
Embedding
Modders have my permission to include an unmodified copy of the file DWE_ConditionFixer.lua (contained in this mod) for use in any mod not sold for money (accepting donations is allowed.)
Embedded usage strips semicolons, provides some resilience against conditions already broken by other mods, and directs users to this page for more information in case problems were encountered.
There's some minimal documentation in the file, and you can look at any of my mods already embedding it for more examples.
Compatibility
Requires Script Extender
Should be placed early in the load order, before any mods that modify conditions
Can safely be uninstalled at any time
来源与文件
文件说明
Requires Script Extender
Place early in the load order
来源列出的依赖与关系
前往 N 网打开所选文件。安装与下载要求以原作者及平台说明为准。
<!-- aoe-mods-source:nexusmods:baldursgate3:18904 -->