X-Git-Url: https://harrygodden.com/git/?a=blobdiff_plain;f=rigidbody.h;h=92419991f7b0e6f21c5659a63a2db9f5bfb9700c;hb=7eba38b8178c82040618a518634d8ff4813e2ff2;hp=8489dbccf830ed1a527d1b17906e27bbe5a63f6d;hpb=73adac381b2c72f08293416a960942dc40db3c7f;p=carveJwlIkooP6JGAAIwe30JlM.git diff --git a/rigidbody.h b/rigidbody.h index 8489dbc..9241999 100644 --- a/rigidbody.h +++ b/rigidbody.h @@ -191,10 +191,9 @@ VG_STATIC void rb_object_debug( rb_object *obj, u32 colour ){ /* * Update world space bounding box based on local one */ -VG_STATIC void rb_update_bounds( rigidbody *rb ) -{ - box_copy( rb->bbx, rb->bbx_world ); - m4x3_transform_aabb( rb->to_world, rb->bbx_world ); +VG_STATIC void rb_update_bounds( rigidbody *rb ){ + box_init_inf( rb->bbx_world ); + m4x3_expand_aabb_aabb( rb->to_world, rb->bbx_world, rb->bbx ); } /*