-- Defines without properties of variable materials (those which come with multiple shades).

use_script("uniformMaterials.lua");

variable_materials = {
    iron = {
        {
            color = WHITE,
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
        {
            color = color_from_rgb(191, 191, 191),
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
        {
            color = color_from_rgb(164, 164, 164),
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
        {
            color = color_from_rgb(96, 96, 96),
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
    },

    copper = {
        {
            color = color_from_rgb(255, 191, 127),
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
        {
            color = color_from_rgb(255, 127, 0),
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
        {
            color = color_from_rgb(127, 63, 0),
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
        {
            color = color_from_rgb(127, 63, 0),
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
    },

    lead = {
        {
            color = color_from_rgb(15, 24, 48),
            lightspec = color_from_rgba(0, 0, 0, 13),
        },
        {
            color = color_from_rgb(15, 24, 48),
            lightspec = color_from_rgba(0, 0, 0, 13),
        },
        {
            color = color_from_rgb(9, 14, 39),
            lightspec = color_from_rgba(0, 0, 0, 13),
        },
        {
            color = color_from_rgb(9, 14, 39),
            lightspec = color_from_rgba(0, 0, 0, 13),
        },
    },

    tin = {
        {
            color = WHITE,
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
        {
            color = WHITE,
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
        {
            color = color_from_rgb(191, 191, 191),
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
        {
            color = color_from_rgb(191, 191, 191),
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
    },

    silver = {
        {
            color = color_from_rgb(204, 254, 254),
            lightspec = color_from_rgba(0, 0, 0, 255),
        },
        {
            color = color_from_rgb(192, 240, 244),
            lightspec = color_from_rgba(0, 0, 0, 255),
        },
        {
            color = color_from_rgb(154, 192, 210),
            lightspec = color_from_rgba(0, 0, 0, 255),
        },
        {
            color = color_from_rgb(154, 192, 210),
            lightspec = color_from_rgba(0, 0, 0, 255),
        },
    },

    uranium = {
        {
            color = color_from_rgb(0, 255, 38),
            lightspec = color_from_rgba(26, 26, 26, 0),
        },
        {
            color = color_from_rgb(0, 255, 38),
            lightspec = color_from_rgba(26, 26, 26, 0),
        },
        {
            color = color_from_rgb(0, 201, 38),
            lightspec = color_from_rgba(26, 26, 26, 0),
        },
        {
            color = color_from_rgb(0, 201, 38),
            lightspec = color_from_rgba(26, 26, 26, 0),
        },
    },

    nickel = {
        {
            color = color_from_rgb(242, 243, 245),
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
        {
            color = color_from_rgb(214, 225, 226),
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
        {
            color = color_from_rgb(94, 109, 119),
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
        {
            color = color_from_rgb(94, 109, 119),
            lightspec = color_from_rgba(0, 0, 0, 55),
        },
    },

    diamond = {
        {
            color = color_from_rgb(0, 255, 255),
            lightspec = color_from_rgba(0, 0, 0, 255),
        },
        {
            color = WHITE,
            lightspec = color_from_rgba(0, 0, 0, 255),
        },
        {
            color = color_from_rgb(0, 127, 127),
            lightspec = color_from_rgba(0, 0, 0, 255),
        },
    },

    gold = {
        {
            color = WHITE,
            lightspec = color_from_rgb(0, 0, 0, 255),
        },
        {
            color = color_from_rgb(255, 255, 0),
            lightspec = color_from_rgb(0, 0, 0, 255),
        },
        {
            color = color_from_rgb(255, 191, 127),
            lightspec = color_from_rgb(0, 0, 0, 255),
        },
        {
            color = color_from_rgb(255, 191, 127),
            lightspec = color_from_rgb(0, 0, 0, 255),
        },
    },

    silicon = {
        {
            color = color_from_rgb(145, 128, 108),
            lightspec = color_from_rgba(0, 0, 0, 255),
            bias = color_from_rgb(10, 5, 0),
        },
        {
            color = color_from_rgb(115, 122, 130),
            lightspec = color_from_rgba(0, 0, 0, 255),
            bias = color_from_rgb(10, 5, 0),
        },
        {
            color = color_from_rgb(135, 123, 86),
            lightspec = color_from_rgba(0, 0, 0, 255),
            bias = color_from_rgb(10, 5, 0),
        },
        {
            color = color_from_rgb(135, 123, 86),
            lightspec = color_from_rgba(0, 0, 0, 255),
            bias = color_from_rgb(10, 5, 0),
        },
    },
};

-- All uniform materials are also variable materials, with all variants the same.
for key, props in pairs(uniform_materials) do
    variable_materials[key] = {props, props, props, props};
end