INTRODUCTION (why I posted this, skip if bored)
Since I didn't see that info readily available and helps avoiding some crashes, I thought about posting this. Other info is mentioned in dev journal, but it would be convenient to have in this subforum, too. Also maybe others wish to give additional info regarding those issues or answer some of the questions presented to help the community. If this saves 5 mins from somene elses time I'll be happy .
CRASH ISSUES:
- Subfolders in "C:\Users\*username*\Documents\My Games\Elemental\" aren't allowed except for the new "Mods" folder
I was using subfolders before as a way of saving backups or old versions of modded files, that's why I had problems.
- Subfolders in "C:\Users\*username*\Documents\My Games\Elemental\Mods" are limited to one level AFAIK (more will crash the game, at least if they have files inside, empty folders shouldn't cause crashes, but why have them )
This is problematic if you wanted to do a subfolder containing all your mods in subfolders, so you didn't have other folders in the way.
Actually all of these things works, maybe they moved a conflicting file away and that's why it solved issues for me, sorry for the wrong alarm. The Notes section will still have some interest.
NOTES:
- If you have the means of searching using Regular Expressions (AKA RegEx), you can use those to organize your files. I use Total Commander embedded search, in case you wonder. Feel free to recommend other ways of doing it.
[^0-9].xml
Will list filenames not containing numbers right before ".xml", useful to move out all non-unit/sovereign xmls from the Units folder
[0-9]+-[0-9]+.xml
Will list files with a digit or more followed with a "-" followed with more digits then xml. Basically to find units/sovereign xmls
- Modded xmls will still be readed in Units folder, I recommend to use a subfolder in "C:\Users\*username*\Documents\My Games\Elemental\Mods" to keep things more organized
You could prefix those subfolders with zMOD in their name, to keep them appart from the normal folders if sorted by Name. You can also put all mods in a new subfolder all together.
- Sometimes (maybe related to a crash) you cannot modify the name of a mod subfolder (or erase it) after the game reads it, even when it's closed. The workaround I found is to move the files inside to somewhere else, start game, close game, THEN rename the folder. This should be rare enough to not happen to anyone else, though
- You can reference icons in the old way, just writing down the filename or you can reference the exact path. (from dev journal)
E.g: <Texture_Hair>CPELF_hair1.png</Texture_Hair>
or using the new structure:
<Texture_Hair>MODS/GFX/CPELF/CPELF_hair1.png</Texture_Hair>
<Texture_Hair>GFX/CPELF/CPELF_hair1.png</Texture_Hair>
All ways will reference the modded file.
Boogiebac confirmed that ONLY the gfx folders (and subfolders) are scanned for graphical assets like - game models, pngs, dds. However, this is unlikely to be accurate, considering Shadows for tiles and Medallions (icons) for units are placed elsewhere.(comment by Heavenfall)
It hasn't been clarified entirely what happens if you have several files with same name in different folders and only use the filename as reference, actually see next entry for some tests in this. I advise to use only the name to link files and making sure there aren't duplicates, just in case (so don't use the original name from core files if you modded something, to make sure it works fine now and in the future)
- Icon references without path work in the Units/Icons dir, but not in Mods/Icons (Related to previous point, new entry to reduce clutter)
- There are reports of crashes when loading tactical maps in the editor, allegedly this has been already fixed since a long time ago. (from dev journal)
- Using the mod folder in the gamedir, is problematic in some cases for non xml files (from dev journal, by Robert Hentschke)
G:\Game\Elemental\Mods\Gfx\Terrain\Grid0001.png - does not work.
G:\Game\Elemental\Mods\Gfx\Grid0001.png - does not work.
G:\Game\Elemental\Mods\Grid0001.png - does not work.
D:\Data\My Games\Elemental\Mods\Gfx\Terrain\Grid0001.png - works.
The whole gamedir/Mods folder seems completely inoperable.
- Tiles placed in "C:\Users\*username*\Documents\My Games\Elemental\Tiles" will show at the top when you load designs. Tiles placed elsewhere will follow the stablished alphabetical (reversed?) order. This is useful, if you have lots of tiles and want to concentrate on some or to not show downloaded tiles on top, so you put those elsewhere.
- Boogiebac also mentioned that you should not use space in your folder names. Presumably this applies to filenames as well. Use _ instead.
- Heavenfall comment on mod folder in installdir:
It is my understanding that the mod folder in the installdir no longer has any functionality. All mods should be placed in the user/username/documents/mygames folder. However, GFX assets inside the installdir may still be accessed like normal. Unsure if the installdir gfx folder is scanned for assets like the new mods/gfx is.
- Heavenfall comment on additional subfolders and the type of file which gets scanned there:
From the debug.err
DebugMessage: No string tables in C:\Users\Heavenfall\Documents\My Games\Elemental\Mods/Data/*.str
DebugMessage: No files found matching mask C:\Users\Heavenfall\Documents\My Games\Elemental\Mods\Movies\*.bik
DebugMessage: No files found matching mask C:\Users\Heavenfall\Documents\My Games\Elemental\Mods\Screens\*.dxpack
DebugMessage: No files found matching mask C:\Users\Heavenfall\Documents\My Games\Elemental\Mods\sfx\*.wav
DebugMessage: No files found matching mask C:\Users\Heavenfall\Documents\My Games\Elemental\Mods\Music\*.mp3
DebugMessage: No files found matching mask C:\Users\Heavenfall\Documents\My Games\Elemental\Mods\Event Music\*.mp3
DebugMessage: No files found matching mask C:\Users\Heavenfall\Documents\My Games\Elemental\Mods\Layered Music\*.mp3
DebugMessage: No files found matching mask C:\Users\Heavenfall\Documents\My Games\Elemental\Mods\Ambient SFX\*.mp3
QUESTIONS:
- What is the purpose of the Data subfolder in Mods? Will files there overwrite corefiles properly? I would like feedback from those modders that did rebuild their data.zip before and are more knowledgeable about which files do need this (keeping them listed, would be amazing)
- Anyone has tried referencing an image found in multiple places and only using the filename? (you can place it in the icons from gamedir, icons from Units, icons from gamedir/mods/icons, icons in Mods/icons)
Does this cause crashes or there is some kind of precedence system? Maybe some of those folders require direct references?