How Raycast on component in blueprint?

Hello people. Me need help. When im interact with object via “Single line trace by channel”, How i can make what the Component in inside my Blueprint Actor (whom have many differents mesh object like a combination lock keyboard). Me need. When im interact with component begin Custom events.

Hello,
Use the “hit component” output from “break hit result”, the one under “hit actor” like :

https://docs.unrealengine.com/latest/images/Gameplay/HowTo/UseRaycasts/Blueprints/GHT2B_10.jpg

from https://docs.unrealengine.com/latest/INT/Gameplay/HowTo/UseRaycasts/Blueprints/index.html

This is not exactly what i need. Me need Begin special event on each component inside in Blueprint. Example: 1 button for start engine, 2 button for turn light on and etc.

Here is the working bp : Do a cast to your blueprint (from hit actor output) and from it set your events by comparing your result with your components by or branches or an array.
382c574401810ab1cd7818ed188ad286f683adfa.jpeg

need something like Dropbox - Скриншот 2015-01-31 18.54.12.png - Simplify your life

With same system you can call events from your blueprint and even use event dispatchers or set bool variables used as conditions in your bp.

Edit : Instead of a loop, set an array with your components and use “contains” to have the index and use it to a switch where you can set your events.

You mean enum struct? And how use event dispatcher?

If you want activation on hit, why don’t you use event hit and the “my comp” output to activate the event you want or directly use the on component hit ? Can you hit a mesh without pointing at it ?
If you really want a line trace, do a custom event in blueprint with primitive mesh as input and add it from “cast to” at the end of your linetrace, then use it in your blueprint to activate the event you want.
You can for example, use a “find” to save index and use actor on click with a switch on int using the index and activating what you want.

Edit : About event dispatchers if you stay on first proposal : Actor Communication | Unreal Engine Documentation