"Get actors in selection rectangle" doesn't work?

Would it be possible to have this as a node in blueprint ?

Yes, I had a problem overlapping, here is the solution:

  • now you can use the function outside the DrawHUD()

    //...
    bool ValidProjected = true;
    FBox2D ActorBox2D(ForceInit);
    for (uint8 BoundsPointItr = 0; BoundsPointItr < 8; BoundsPointItr++)
    {
        FVector2D ScreenLocation(ForceInit);
        ValidProjected = GetOwningPlayerController()->ProjectWorldLocationToScreen((BoxCenter + (BoundsPointMapping[BoundsPointItr] * BoxExtents)), ScreenLocation);
        if (!ValidProjected) { break; }
        ActorBox2D += ScreenLocation;
    }
    if (ValidProjected)
    {
        //...

Were you able to solve this problem? I’m facing exactly the same one, the actor is selected before the box touches it :confused:

Any help would be appreciated!

Thanks in advance!

This still seems to be an issue in 5.3 that it selects things before the box touches it. If you see the attached image, that die to the right gets included if I let go. The die has no collisions or things off it, I’ve shown collisions at runtime and checked the object, nothing extends beyond the die we can see yet getting that close is enough to somehow have it included.