Im trying to create a mobile RTS game, with selecting a character with touch begin and moving it (animated) with drag and drop to the location of the** touch end**. But my cast to Character seems not to work. Its not failing, instead if I touch the character, nothing is happening (If I click somewhere else the Cast at least is failing). The character`s mesh has the collision preset “overlap only pawn”. Can someone help?
Add line trace by chanell ther and trace from caera to touch location (or just from touch up for 200units or so), turn on debug display.
You will see that you are not touching correct actor (most probably). You need to debug this stuff.
To make sure that this touch interface works you need to search for all actors of class (in your cast character).
Find if any of them is in some small radius around touch location.
you can always print class of actor you touched, this may help find faster what is going on.