[Rseding91] [1.1.57] changing dependency order may cause "corrupt map - bad load statistics size"
Posted: Mon Apr 25, 2022 10:07 pm
When dependency order of mods is the only thing that changes from before and after a save, AND prototypes are only added, then the 'corrupt map' message happens.
Example: A has a procedural function to create prototypes. B adds a prototype. A does not create a prototype because it is ordered before B.
Expected Solution: Change the "dependencies" : ["base"] in A to "dependencies": ["base", "dependency_order_map_corruption_B"]
Restart Factorio, load the save. Message:
*IF* a prototype goes missing, the game pops up the dialog that XYZ has been removed.
Expected result: No error, additional prototypes work as expected (even if a manual reset_technology_effects() etc is needed)
Example: A has a procedural function to create prototypes. B adds a prototype. A does not create a prototype because it is ordered before B.
Expected Solution: Change the "dependencies" : ["base"] in A to "dependencies": ["base", "dependency_order_map_corruption_B"]
Restart Factorio, load the save. Message:
Code: Select all
8.912 Warning Map.cpp:346: Map loading failed: corrupt map - bad loaded statistics size: 531 != 532
8.963 Error AppManagerStates.cpp:1599: corrupt map - bad loaded statistics size: 531 != 532
Expected result: No error, additional prototypes work as expected (even if a manual reset_technology_effects() etc is needed)