I’m trying to interact with certain components in a bluepint made up of several components.
I am using a raycast, which also use it to interact with actors.
My question is:
can I differentiate a particular element of the bluepint via raycast, and thereby interact with it?
For example i want to interact with only 3 buttons of a blueprint made by a lot of other components.
share the example:
FHitResult Hit(ForceInit);
if (GetWorld()->LineTraceSingle(Hit, StartTrace, EndTrace, ECC_WorldStatic, TraceParams))
{
interactiveLastItem = Cast<AInteractive>(Hit.GetActor());
//BP//////////////////////////////////////////
interactiveLastItem->InteractInBP();
///////////////////////////////////////////////
}
and the BP:
note that BPInteract event is called from cpp
(With this example i am getting the blueprint name, not a particular component in it)
Thanks!