Many mods at the moment distribute entire files instead of patching, I'm sure that those who have tried to distribute multiple mods will agree that this is not the best way to go about things.
I'd like to focus on
flevel.lgp as it's directly related to most of what I've worked on in the past, although I'm sure the following ideas can be applied to most of the other game files if necessary.
Most of you will already know this, but the field files inside flevel.lgp can be simply split into logical sections, and each section can be split again depending on the data inside. Splitting the files down into manageable chunks will allow modders to include only the data they need to change, instead of overwriting everything wholesale. This won't eliminate conflicts entirely, but it's a start and at worst it would make mods smaller and easier to distribute.
As an example, the first section of a field file can be broken down into individual scripts, text, and akao blocks. I'm mostly concerned with the first two so as a test I made a small app that does precisely this, for example
gldelev is split up as follows:
├───0_dic
│ 0
│
├───1_cloud
│ 0
│ 1
│ 2
│
├───2_esto
│ 0
│ 1
│ 2
│
├───3_ele
│ 0
│ 1
│ 2
│
├───4_shade1
│ 0
│
└───text
0
1
2
The scripts for each entity are added to their own folder, and the text to a separate folder. Note that the app automatically removes unused scripts and text to reduce clutter.
Making changes to the scripts and text for a mod could be performed in a number of different ways, but the most obvious would be to use Makou Reactor to make the necessary changes, dump only the relevant parts, and distribute the files along with the app that will reinject them into the target flevel during installation of the mod. Even the script and text from the entire game could be included if necessary, they only occupy about 2 megs uncompressed.
So far the tool only splits the first section (minus akao blocks), but it could be easily extended for the other sections too.
If you'd like to see what the structure looks like, download
this, and run it specifying the location of the flevel (e.g. "flevel_dump.exe foo/bar/flevel.lgp"), it creates a root flevel directory in the dir where it is run. There is zero error checking right now, but as long as you specify a valid flevel and the current directory has write permissions you should be good to go. Note that it dumps a lot of files (about 60,000) so depending on your hardware it might take some time.
This probably ties in with kaldarasha's community flevel project somewhat, and perhaps other projects besides, and I'm open to any feedback at all.
* I may have overthought this, the field files themselves could work fine as a patching format, unused parts can be marked with zeroed out offsets. This means far less file clutter compared to above.