In Progress Scene Editor Settlement Position Scripts

Currently viewing this thread:

Version number
I am working in a custom worldmap. Since updating to e.1.6.0 the game crashes on load without a valid SettlementsDistance cache. While the settlements_scripts entity in my worldmap automatically runs the settlement scripts on saving the worldmap in the scene editor, they fail. Accordingly, they need to be run manually within the scene editor.
Running the CheckPositions and SavePositions scripts updates mymod/ModuleData/Settlements.xml for its correct worldmap coordinates and saves it as Sandbox/ModuleData/Settlements.xml.
Running the ComputeAndSaveSettlementsDistanceCache saves the correct cache for my worldmap in Sandbox/ModuleData.
Currently, the xml and cache are saved in Sandbox/ModuleData, which is where the game needs them to avoid crashing on loading, but they are overwritten by any game update or when verifying local steam files as they are not Native Sandbox files.
For modders this halfway house is confusing and error prone. I hope a correction is already scheduled in Taleworlds Development lists, but note it here to ensure it isn't missed and to emphasis its priority.
For modded Worldmaps the game needs to load settlements.xml and distance cache from that mod's ModuleData.
The settlements_scripts need to save files to the relevant worldmap's ModuleData.
The bug that disables the automatic running and saving of settlements scripts on saving a modded worldmap also needs to be fixed to allow modders to build new worldmaps without having to understand any of this - as was clearly Taleworlds original design intention.

MArdA TaleWorlds

Community Support & Localization
Community Support
Forwarded to the QA team for further investigation. We will reach out again if we need more information. Thanks for reporting and sorry for any inconvenience!
Correction.I'm not sure why I had problems with the auto-running of settlement scripts on saving worldmaps from the editor, but that appears to be working fine now. Accordingly, my remaining concern is saving the distance cache and settlements.xml in Native locations where they are overwritten by updates etc and can't be published in a self-contained mod.
Top Bottom