Event dispatcher from UMG to Actor BP?
I have my UMG widget (my_menu3) and I want my button to start my custom event located in an Actor Blueprint.
So : 1 - I created a Event dispatcher (changemesados) in my widget for when I'm pressing this button.
2 - In my Actor blueprint I create a Cast to my_menu3 node and Bind my event dispatcher to it. (I convert it to pure cast, if not, it gives me an error when compiling)
3 - I link the event dispatcher to my Custom Event (phonecall) and set my event dispatcher to Event Begin Play. So this way is always enabled when I play the level.
Sadly it doesnt work. It compiles fine, but it does nothing. Am I missing something? Ive been trying to figure out this issue by changing my methods, but no luck.
Thanks in advance!
asked Apr 15 '15 at 12:10 PM in Blueprint Scripting
This should work if you just use your widget variable to access the dispatcher rather than that cast node. So once you do Create Widget, I'm guessing you are then saving the result as My Menu 3?
Right after Create Widget, you would use that resulting output or that new variable (same thing) and establish the dispatch connection in your actor BP. So, you wouldn't do this on Begin Play, but rather wait until the widget is created so you can reference its instance.
Casting to widgets seems to be weird. But using the variable you get from creating them works just fine.
Follow this question
Once you sign in you will be able to subscribe for any updates here