# Can I dynamically update the parameters of an animated material in the event graph of an actor that uses it?

**URL:** <https://forums.unrealengine.com/t/can-i-dynamically-update-the-parameters-of-an-animated-material-in-the-event-graph-of-an-actor-that-uses-it/1183446>\
**Category:** Blueprint\
**Tags:** unreal-engine, question, Blueprint\
**Created:** [May 30, 2023, 2:10pm UTC](https://forums.unrealengine.com/t/can-i-dynamically-update-the-parameters-of-an-animated-material-in-the-event-graph-of-an-actor-that-uses-it/1183446 "2023-05-30T14:10:14Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ecksdeeeee](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ecksdeeeee](https://forums.unrealengine.com/u/ecksdeeeee)\
**Post date:** [May 30, 2023, 2:10pm UTC](https://forums.unrealengine.com/t/can-i-dynamically-update-the-parameters-of-an-animated-material-in-the-event-graph-of-an-actor-that-uses-it/1183446/1 "2023-05-30T14:10:14Z")

</div>

I have made placing zones, which consist of a decal that uses an oscillating, emissive material.

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/3/c/8/3c8fea9276d2174228f0aa891e9f6a4d1c0daff0.jpeg)

All it does is take time as an input, make it periodically oscillate up and down using a sine function and then gets multiplied with a bunch of factors. One of those factors is the Brightness, which is a float that is multiplied with the emissive colour.

What I would like to achieve is to make the brightness instance editable in my decal actor, the aforementioned placing zone.

I am trying to access the parameters of the material in the construction script of the decal actor like so:

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/c/d/a/cda7beaccaf3e00ea5388f4b369bc3ba810de5f3.png)

Then I would have a brightness variable in the decal actor blueprint, which I would make instance editable and thus I could regulate the brightness of the decal inside the editor to my preferences.

The problem is that I do not see my material parameters in the construction script if I do:

- Get Decal Component =\> Get Material =\> Set…

In cases like these, I suspect you would cast to the specific material that actually has these specific, manually created parameters, that the agnostic Get Material Node would not know about.

But there is no Cast to my specific material. And now I am slowly realising that this is probably not possible in Unreal or done entirely differently.

Can I achieve what that? Set the Parameters of my custom Material in the construction script of an actor that uses that material?

I looked for interfaces that could be implemented in the “Event Graph” of the Material, but I don’t see any class settings or anything that would allow me to send information from my actor to my material.

---

<div class="post-metadata">

**Author:** ![Extrone](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/extrone/32/906554_2.png) [@Extrone](https://forums.unrealengine.com/u/Extrone)\
**Post date:** [May 30, 2023, 2:17pm UTC](https://forums.unrealengine.com/t/can-i-dynamically-update-the-parameters-of-an-animated-material-in-the-event-graph-of-an-actor-that-uses-it/1183446/2 "2023-05-30T14:17:56Z")

</div>

Here’s a similar thread I found with a solution :

> [@How To Change A Material Instance Parameter On A Blueprint Object?](https://forums.unrealengine.com/t/how-to-change-a-material-instance-parameter-on-a-blueprint-object/287208):
>
> So I want to basically push a button and have the thruster material on the back of my ship change to a bright glow. I was able to follow the blueprint material video’s from Epic, but their method is an on or off material value change. I want to gradual change over time these values and that is why I am trying to use a matinee. I have my material set up, set up parameters for all the parts that I want to change over time. I have created my matinee and even tested it on a static mesh (changed to…

tldr : you need to create a Dynamic Material Instance and then use Set Scalar/Vector Parameter Value.

* * *

[EDIT] If the above solution doesn’t work for some reason, another option is to use Material Parameter Collections :

> **[Material Parameter Collections](https://docs.unrealengine.com/5.0/en-US/using-material-parameter-collections-in-unreal-engine/)**
>
> Assets that store an arbitrary set of Scalar and Vector Parameters which can be referenced in any Material.
