Hello

How do I calculate the vec_dist from the origin of an entity to the bounding-box of the same entity. It needs to work for the x/y size of the entity...z is not important.

Thanks for any advise (preferably code...cause I'm bad in math)