Is there any way to do a box/square trace in Blueprints? If there isn’t, is there something I can use instead of a box trace? Basically I am trying to create a click and drag selection feature. Like how you can click and drag in an RTS to select multiple units in an area.
What I would do is create a box component and resize it until you release mouse, at which time you check for collisions, delete box, ext.
You can do a box query (what objects are inside of this shape) using BoxOverlapActors or BoxOverlapComponents, which should work for your purposes, but there is no way to do a box trace (what objects does this shape hit as it travels down a trace vector). You can query spheres, capsules, and boxes; but you can only trace spheres, capsules, and points (the line trace effectively is a point shape).
If it’s a perspective camera, it’s actually a frustum you want to collide. It might be easier to calculate the screen space bounds of units and do the collision in 2D there.
Would you mind explaining exactly how I would go about doing this? It would be great if you could point me in the right direction or even give an example blueprint.