How to call a function from another class in a widget blueprint?
I'm trying to call a function from the player controller blueprint by pressing a button in a widget, but I have no idea how to do this. I have a OnClicked function in the widget blueprint where I want to call the function "LineUp" from the player controller:
Thanks for any help:)
asked Aug 20 '17 at 02:54 PM in Blueprint Scripting
On your widget you would need a reference to the Player Controller. This is usually achieved by using Get Player Controller node.
Then cast the Player Controller to your custom class. After the cast you can call the Line Up function.
answered Aug 20 '17 at 04:09 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here