There are two BP functions that makes me wonder a bit
Get Overlapping Actors Get Overlapping Components
The “Get Overlapping Actors” works as I understand and expect it should, it returns an array of items, and the items in that array are Actors. So you basically get a list of Actors.
So far so good.
The problem I’m having is with the “Get Overlapping Components” function, it does something different from what I expect it to do.
The “Get Overlapping Components” returns a list of a single Component per found Actors, not every Components per found Actors.
So what I unexpectedly get is that the “Get Overlapping Components” returns an Array of Items where I expect it return an Array of Arrays.
To be more technical I expect a return of an Array of Actors each containing an Array of Components
In other simpler words I expect “Get Overlapping Components” return EVERY components that it finds on each found Actors.
Currently “Get Overlapping Components” returns for each found Actor only the first component which is usually the RenderComponent for me.
Is this a bug or have I misunderstood the whole thing about “Get Overlapping Components”?
The “workaround” for me is to use the Get Overlapping Actors instead and then from there iterate each Actor to get each respective components (2 nested for each loops)
The bottom line of what I am actually trying to do, I’m trying to find each overlapping sprites that my character overlaps when pressing E, that contains a special ActorComponent, which I have named PickupComponent. So that when pressing E next to that sprite it should pickup these pickup-able sprites and their behaviors.