Hey there! I've got a quick question about material handling... Our game has very flat materials with no textures, so we end up getting tons of materials that are only meant for colors. It was getting a little difficult to manage so many colors so I ended up writing a little script where you can set diferent colors with a material property block like:
rend.GetPropertyBlock(s_block,i);
s_block.SetColor(s_color, _colorInfos[i].MatColor);
s_block.SetFloat(s_max, _colorInfos[i].MaxFloat);
rend.SetPropertyBlock(s_block,i);
Now we only have one base material, and we can change the color freely for each object.
My question is... Can this affect badly the render pipeline? I have also activated GPU Instancing as they are all using the same shader/material now. I have done some testing and it seems fine 🤔 But maybe I'm missing some deep knowledge ahaha
Thank you for your time!