RedChiken
(RedChiken)
1
Excuse me, I’m looking forward to add event to pawn.
I want to make event when pawn clicked.
I already use “Actor on Clicked” and check weather it clicked or not, but nothing happen.
This is my project’s view.
Player Start is Z= 1500, Pawns(cubes) is Z = 110.
Is it right that use “Actor on Clicked” node to add event when it clicked?
If it’s right, what should I do more?
If it’s not, How can i add event?
Everynone
(Everynone)
2
I can’t see a Pawn in your screenshot but if it has a mesh, you’d need to ensure that the collision settings are at least set up like this:
Note the Visibility channel.
Your PlayerController will need to have ClickEvents enabled, too and be set to the same TraceChannel.
RedChiken
(RedChiken)
3
That gray cubes are each pawns. It has mesh, so I set as your reply.
But it still not work. This issue is such a different.
Everynone
(Everynone)
4
Could you test it without your macro? Just drop one of you pawns in the level, hook up a print node to onClick, launch and see if it works.
RedChiken
(RedChiken)
5
Sorry. It still not work.
Everynone
(Everynone)
6
The setup I provided works in an empty project. It’s difficult to pinpoint where in your project things go wrong.
Perhaps you have a blocking volume or something else that intercepts the mouse click.
edit: In the last image you posted, you have the default trace channel set to Pawn, it should be set to Visibility.
RedChiken
(RedChiken)
8
I’ve tried little bit more and now it work.
But I think it’s not work well so I ask you about this.
Pawn class in first picture, pawn_rktp, is a super class of all pawns.
When I set printing log in pawn_rktp, it doesn’t work.
But when I set it in sub class, it work.
Should I set all click event to each class?
there is no collision tab when I check my mesh