How to create a dynamic material instance for multiple objects having the same material?

Hello,

I am trying to make a blueprint class where a lot of objects share the same material. I want these objects to glow when the player reaches a certain point in the level. So, I am controlling the emissive color value using a vector parameter which I plant to change by creating a dynamic material instance. However, I found out that for every object, I have to create a dynamic material instance and promote that to a variable which has resulted in a big list of variables.

So, is there a way to create a dynamic material instance whose values I can change and the change will be directly applied to all objects having the same material?

Thanks

Hi DNADrone!

Assuming I understand your conundrum correctly, what you want is not dynamic material instances, but rather use something like a MaterialParameterCollection. You can read about those here: Material Parameter Collections | Unreal Engine Documentation

That approach will let you change a value in a single place, and the result will be applied immediately to all objects using the material hooked up to one of those parameters.

Thanks a lot Xenome, I’ll check it out and let you know.

Whoa… I tried out and it works. Thanks a lot man. :smiley:

great!

it’s perfect!