I need help in casting
I am trying to mak a small Hexagon strategy game but I have a problem. I am using the 2d sidescroller setup and created a widget where when you clicked on a button the sprite of the 2D Object should change.
But I have no clue how to cast to an object. I tried it but I failed.
I hope you guys could help me somehow.
asked Feb 02 '18 at 08:20 PM in Blueprint Scripting
In order to cast to something you need an Object to cast from. Your Object input is empty, that won't work. What is P1? Your player class? Then use the Get Player Pawn (or Get Player Character) node and feed the output into to Object input of Cast to P1 node. In that way you should be able to work with it.
answered Feb 02 '18 at 08:25 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here