Download

What is blueprint equivalent of StaticMeshComponent->OnClicked.AddDynamic(this, AMyActor::OnClick);

Anyone know the blueprint equivalent of StaticMeshComponent->OnClicked.AddDynamic(this, AMyActor::OnClick); ?

I need to add an onclicked event to a staticmeshcomponent created at runtime that points to a function.

I guess you can call “Assign On Clicked” on a newly created StaticMeshComponent.

http://puu.sh/lkZ3c/75639973eb.png

Black belt, thanks man :slight_smile:

If eXi got what you wanted, these are called Event Dispatchers in BP, and you can make your own. Inside the BP where you define it, you can call it as if you’re calling a function. Outside of the BP, you can assign it as eXi shows.
I don’t know if this is relevant or not, but figured this would be useful to know anyhow.

a75b6036c49fa528b250977691003a87e6910860.gif
883e175657eeb321165592619e22629820eaf4b7.gif
dd19e5cc8e03d9159a26f10df07d3d0a8cae1b83.gif