Sorry if this question has already been answered but i’m still stuck after reading lots of thing on this.
Basically i have created a new blueprint “actor” and setted a variable in it named “CompassDirection” (the purpose is to do a compass), i’d like to show it on my screen through an UMG widget (which is already showing few things).
Here is the content of my “CompassBP” (which is added to the world of course), pretty simple :
Next i’ve created my “text” object in my HUD widget, and created a binder.
I have also added a “cast to” node to my CompassClass in the event constructor, to be able to get my “CompassDirection” variable, but the casting fail each time and i don’t know why
Event construct : the “Cast to FirstPersonCharacter” is here for others things showed in my HUD (which are working perfectly without the failing cast) :
Binder : Nothing special here, the goal is to get the variable from the compassBP, the editor find it easily in context sensitive mode… :
I’m sure i’m close to the solution, i think it may be related to the “Object” in the “Cast To” node, but the only thing i found to put here is the CompassBP blueprint itself… I’ve also tried to put the “Get Player character” output but it doesn’t work either… I think i need a new explanation on this Cast To node, i’m missing something
I hope my problem is easy to understand !
Thanks for your help !