During runtime in Unreal I want to be able to apply opacity fades to any Actor in the map. Each actor can have one or more material slots on the mesh (static or skeletal).
Is there a way during runtime to edit each material slot on a mesh and create a parent material of the current material being used?
For example, I might have a humanoid character with multiple material slots I want to fade in/out. For each material slot I’ll wrap the current material as a child of a custom parent material and then set the opacity on the parent material. The existing child material is still being applied, but the opacity is being overridden by the parent material.
All this has to be done at runtime. Doing it ahead of time in the editor or maya is not an option.
What would be the best approach?