#Why can't I register fluids????

2 messages · Page 1 of 1 (latest)

pallid dagger
#
StartupEvents.registry('fluid', toddy => {
    function nameD(name) {
        return name
        .split('_').map(word => word.charAt(0).toUpperCase() + word.slice(1)).join(' ');   
    };

    function fluid(name, color) {
        toddy.create(name).thickTexture(color).bucketColor(color).displayName(nameD(name));
    }

    const fluidColor = [
        ["white", 0xd6d6d6],
        ["light_gray", 0xadadad],
        ["gray", 0x5e5e5e],
        ["black", 0x1c1c1c],
        ["brown", 0x4d3a1f],
        ["red", 0xbd3228],
        ["orange", 0xbd7028],
        ["yellow", 0xbfb224],
        ["lime", 0x53bf24],
        ["green", 0x22520d],
        ["cyan", 0x21b883],
        ["light_blue", 0x239fba],
        ["blue", 0x2231ba],
        ["purple", 0x6721b8],
        ["magenta", 0xa91fb5],
        ["pink", 0xdb16b4]
    ]; 
    
    fluidColor.forEach(color =>{
        fluid(color[0] + "_pigment", color[1]);
    });

});
``
pale pendantBOT
#

Once your ticket has been resolved, please close it with </ticket close:1054771505520717835> command!