For a shader, I think you need to pass a uniform to tell the shader to change the colors. I would expose a few uniforms for the different colors and an integer for the index, so the shader knows that if the integer is a certain value to map the colors to one of the uniforms.
Do you have a shader for changing the colors? I think I wrote one at one point, so if you do not have a color changing shader let me know and I’ll see if I can find it.