Can't cast to Dynamic Material Instance

Hi!

I’m using Unreal Engine 5.2.1.

I have a mesh with a material instance as its material:

The material:

I’m trying to set a vector parameter with this code:

But the cast never works.

What am I doing wrong?

Thanks!

You have to make it a dynamic material first. That’s different from a material/material instance- it has to be done at runtime.

Here’s a video going over them: