Fixing Billboarded Sprites Clipping into 3D Geometry

The box can be invisible and only used to provide collision data with your environment.

You’d basically just make sure the units are on a grid or use the 3d box to keep them far enough off the walls.

I honestly don’t see a solution that would not require hard coding a limit to the vertical billboard. I would apply a horizontal billboard and then find out the maximum value of your vertical billboard and never let that angle go above that amount.

Doing that will ensure the sprite stays outside of the wall