You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 4, 2023. It is now read-only.
Every file associated with a capital letter leeds to the modloader not recognising it.
Tested mods: Halloween Ornaments Pack By Ricky and me, and Industrialized low tier productions by lordys.
File structure with vanilla downloaded mods:
With low tier productions mod, there are several texture files named with file extension .DDS instead of .dds
This leads to invisibility of the corresponding parts of the buildings in game:
The cfg et al. files of the advanced sausages factory is named "sausages_II.*" with two capital Is. This leads to the typical warning in game "cannot be build" whcih happens when the ifo file is missing.
After renaming the Sausage Factory and re-exporting the dds files from gimp, everything worked as expected:
Same issue with the Halloween pack. The marketplace skin is stored in a folder named "halloween_MARKETPLACE" with capital letters. This leads to invisibility after changing the skin from the normal marketplace to halloween skin:
After renaming to "halloween_marketplace" everything worked as expected. So image above for reference.
This issue only effects v0.9.1!!! I tested everything with v0.9.0 and the capital letters were no problem at all.
Capital letters seam to be no problem in the Title of the mod-folder inside "Anno 1800/mods".
I dug around the code a bit, and I think there are only two options where the file itself is accessed in some way.
Either in external-file-loader.cc when the Files get opened with CreateFileW (Either in ReadGameFile or ReadFileFromContainer), or while they are discovered with fs::recursive_directory_iterator in mod.cc
Now, there are some more options where the file loading could fail:
fs::recursive_directory_iterator doesn't find the file (HIGHLY unlikely)
The "game_path" of the file is stored with the uppercase letters, the game requests the file with lowercase letters (either by default or because the path from eg. the .cfg or asset or so is lowercase) and the check if a modded file of that name exists (also during ReadGameFile or ReadFileFromContainer) then is case sensitive and doesn't find anything.
the file path was turned to lowercase during discovery or during parsing to canonical form, and CreateFileW is case sensitive and doesn't find the file anymore.
Personally I guess it's either 2 or 3, but what's confusing for me is that the corresponding code hasn't been changed since 0.9.0... so IF it's actually from one of those, the issue is a regression introduced eg. with dependency updates. And that could actually be, as https://github.com/microsoft/wil got updated, and there were changes to filesystem.h. in there. And those changes actually affect path stuff since an import for pathcch.h got removed there. EDIT: The import got moved, not removed. Oops.
Every file associated with a capital letter leeds to the modloader not recognising it.
Tested mods: Halloween Ornaments Pack By Ricky and me, and Industrialized low tier productions by lordys.
File structure with vanilla downloaded mods:
![capital letters iltp](https://user-images.githubusercontent.com/64583643/199483232-fcfb4c82-4a66-4909-823a-3c75fbb2c51a.png)
![bug industiraliezed low tier](https://user-images.githubusercontent.com/64583643/199483370-9cffd761-678f-404b-af13-d45bc262cb87.png)
With low tier productions mod, there are several texture files named with file extension .DDS instead of .dds
This leads to invisibility of the corresponding parts of the buildings in game:
The cfg et al. files of the advanced sausages factory is named "sausages_II.*" with two capital Is. This leads to the typical warning in game "cannot be build" whcih happens when the ifo file is missing.
After renaming the Sausage Factory and re-exporting the dds files from gimp, everything worked as expected:
![after renaming everything to small letters](https://user-images.githubusercontent.com/64583643/199483773-35917b14-b6cd-4b22-a89a-eeb5583e18d8.png)
Same issue with the Halloween pack. The marketplace skin is stored in a folder named "halloween_MARKETPLACE" with capital letters. This leads to invisibility after changing the skin from the normal marketplace to halloween skin:
![bug market](https://user-images.githubusercontent.com/64583643/199484009-3f65e6e8-8cf1-4844-b973-07ec97850762.png)
After renaming to "halloween_marketplace" everything worked as expected. So image above for reference.
This issue only effects v0.9.1!!! I tested everything with v0.9.0 and the capital letters were no problem at all.
Capital letters seam to be no problem in the Title of the mod-folder inside "Anno 1800/mods".
This is the fixed version of the two mods for reference.
[Ornamental] Halloween Decorations_fixed.zip
[Gameplay] Industrialized Low Tier Production_fixed.zip
The text was updated successfully, but these errors were encountered: