HaArLiNsH / TextureReplacerReplaced

The continuation of TextureReplacer, a plugin for replacing original textures in Kerbal Space Program.
8 stars 4 forks source link

New syntax #29

Closed Sigma88 closed 7 years ago

Sigma88 commented 7 years ago

This is not complete yet, DO NOT MERGE THIS PULL REQUEST

So, this is the first attempt to define a better syntax.

For now I have changed how the paths to "Default" and "EnvMap" folders are defined

here you can find a simple mod example NewSyntaxMMTest.zip

how does the new syntax work:

Old Syntax

This 3 cfgs would have defined 6 custom folders to be considered as "Default" TR folders No custom "EnvMap" folders were allowed

TextureReplacer
{
    paths = folder1/ folder2/
}
TextureReplacer
{
    paths = folder3/ folder4/ folder5/
}
TextureReplacer
{
    paths = folder6/
}

New Syntax

This 3 cfgs will define 6 custom folders to be considered as "Default" TRR folders Custom "EnvMap" folders are now allowed (2 are added in this example)

TextureReplacer
{
    Folders
    {
        Default = folder1/
        Default = folder2/
        EnvMap = CustomEnvMap1/
    }
}
TextureReplacer
{
    Folders
    {
        Default = folder3/
        Default = folder4/
        Default = folder5/
    }
}
TextureReplacer
{
    Folders
    {
        Default = folder6/
        EnvMap = CustomEnvMap2/
    }
}