Download

Delegates in Blueprints and dynamic event binding.

Hello everyone i meet a snag when trying to make some events fire outside the blueprint.
So i dont know what am doing wrong but.

I created a new Costume Event in my “Inventory Slot Widget” i then call the function for that event when apropriate.
I have the event in the Event graph but it will never be used there, its meant to be picked up in a difrent class/ blueprint.

So i created a Event Dispatcher and added that event.
Then i assigned that event in the second class/ Blueprint.

But no event fires am i doing something wrong?

What am trying to do is have a event called in a child widget.
And pickup that event in the Parent Widget.

basically, the blueprint event node takes priority.
If you have a event you want to bind to, don’t create the event node.

(Following is assuming if I read your question right.)
Instead, use the bind/delegate so that in your child widget there are no events nodes but the dispatcher listed in variable list.
And in your parent widget, you bind to the dispatcher, and have delegated events run with in parent.
So who ever calls that dispatcher(doesn’t matter if parent/child or anyone that calls it), it will run the delegate that last bind to it.

Yes thank you i got it working i had my logic backwards.
And it turns out i was a bit to hessitant to use Widget Refrences after some crashes.
While using them in other Blueprints.
Cheers!