Select material in UMG and apply it on multiple actors

I just started using UE and I’m using it for ArchViz.

I want to create widget loaded with, let’s say, 50 materials,
press TAB to show the widget,
select one of the materials,
and while material is selected apply it on multiple actors in the scene with LEFT CLICK.

Then select other material and, in the same manner, apply it on other actors (furniture cabinets and fronts).

Thanks in advance,

Is there a question? An element that is not working for you?

Yes, I’m sorry, what is the blueprint logic for making this interaction possible (for the example described above)?

Yes, I’m sorry, what is the blueprint
logic for making this interaction
possible (for the example described

It’s just that you’re asking for a complete system and it’d take a couple of lengthy tutorials to cover it all while the Answer Hub is more suited to asking direct questions.

Just to give you a quick overview of how a system like this could be set up with a minimum number of moving parts:

  • a Materials Panel widget that holds user Material Slot widgets
  • a user Material Slot widget shows the material and holds its reference
  • have an array with materials, populate the Materials Panel with Material Slot user widgets in a ForEach loop, feeding each Material Slot widget appropriate array element
  • selecting a Material Slot sends its material reference to the Materials Panel (via an Event Dispatcher or directly, via an exposed ref) and sets it as Active Material

For communication:

  • get hit under cursor for objects (or line trace from camera)
  • if eligible object hit, check with the Material Panel for Active Material
  • apply active material to hit object

There’s probably half a dozen of gotchyas that I did not even think about but it could be a half-decent start. This should be an OK setup for a learning experience, not so good for anything commercial (kind of depends on the scope of what you’re trying to achieve).

When dealing with a great number of objects with various functionality, you’d want set up an Interface for communications. Especially when things get more complicated than [select object → apply material]. As in, the object has multiple parts, each having each own material and other interactivity elements - opening drawers, adjusting colour, scale and whatnot.