Action OnClick not working (UE4-27)

Aye, interface is what you need:

  • tracing:

In short, when we LMB, a line is shot into the world following the direction of where the camera is currently looking. If we hit something, we’ll know what it was.

Now that you know that you’ve hit something (door, bell, monster, wall, collision volume) you can send that entity a message.

Do look up Interfaces on YT. They will allow you to send a generic message to the hit actor and that actor can interpret that message any way you need.

If you hit a bell, it will ring. If you hit a door it will open…


A quick and dirty example:

1 Like