When i drop items from my inventory, i want to place them on ground. So i do a Line Trace down and set its location to hit location. It works fine, but different items have different pivot points - which causes ‘sinking’ into the ground. How to place an actor on his bottom bound? Like that:
I’ve tried to “Get Local Bounds”, divide max value by 2 and add it as local position offset. It kinda worked, but some items have different pivot points and it causes them to, for example, float in air after applying this offset.
An important parameter for me was to set the first to true so it would only pick colliding components. Like the OP I was doing some offset hacks on the CollisionVolume which worked inconsistently. Ideally the spawning box should already be on the floor so the hit test may be unnecessary in my case.
Here is a full example. The ASpawnVolume actor has a spawning UBoxComponent to define the volume.