Dynamically Spawn static meshes and print their data on hover

This is the component you touched:

You need to associate data with it. That’s why I suggested exposing data on the components. So it’s the component that holds everything, no need to ask the DT for anything. It’s just used to pipe stuff into the component.


Alternatively, pack them into a map.


Here’s a more complete setup:

  • extend an SMC as suggested above:

image

  • inside this component:

You could just print the data here. Or you could add a custom event dispatcher should you wish to access this data elsewhere without casting.

  • when you instantiate, bind to the custom dispatcher (or to the native one and cast):

This way you end up with a component that can not only show a mesh but also hold other data and dispatch it when asked to.