Closed benjamin-cates closed 1 month ago
It's probably linked to #288 If you add a RigidBody to the entity, the collider is scaling with the entity, otherwise all transforms on the entity won't be applied to the collider.
It's not only scale, but position and rotation as well.
A workaround for me was to add a static RigidBody to the entity.
Hmmm this does not fix the issue for me. I added RigidBody::Static
to the parent element and it still did not scale appropriately. However the example does work if I change Keyframes::Scale
to Keyframes::Translation
, whether a RigidBody is present on the parent or not. So this seems to only affect scale and it does not depend on the RigidBody of the parent. So due to this experimentation, I don't think the issues are linked.
Can confirm that the reported workaround does not work for me either
@Jondolf I'm pretty sure you fixed this a while ago, sans the case for negative scales, but those have an own issue.
Hello! Just wanted to say I think this repository is really cool but I have found a bug.
Basically, colliders are not effected by the scale transformation of a parent object, even though meshes and everything else are.
Here is a minimal, but still long, example
Cargo.toml
:src/main.rs
:If you run the example, there is a plane in the middle of the screen that initially starts with a mesh and a collider having the same size. The empty parent of this plane then does a scale animation. The mesh of the child changes in size, but the collider of the child does not.
Photo of the debug render:
I originally experienced this when I had a box with an open top made of 5 colliders that were children of an empty entity. When I scaled the parent, the positions of the colliders changed so that they were still in line with the walls, but their size did not grow to fill the edges.
I'm willing to submit a pull request to fix this but if someone could give me some guidance on where to look that would be nice. Or if someone knows how to fix it already.