I’ve been struggling with physics and still, after reading documentation, watching tutorials and searching on the answers page I can’t get my scene to work.
I have a light object (a fly), suspended in the air (use gravity=false) that gets hit by a moving heavier object (flyswatter). Purely based on physics I expect the light object to be swept away, so it should start moving in the same direction as the flyswatter. Well, it doesn’t. Most of the times it does not move at all, sometimes it moves in the opposite direction, but slowly. It also does not seem to matter if the flyswatter moves fast or slow.
i made a simple testscene where the fly is a sphere with scale (0.1,0.1,0.1) and the flyswatter a cylinder with scale (0.5,0.05,0.5). Both objects have rigidbodies, the fly with mass=0.1, the flyswatter with mass=10, both have colliders, a sphere collider for the fly, a convex mesh collider for the flyswatter (the cylinder has a default capsule collider, but that sticks out on the flat ends of the cylinder).
There is a collision detection script on the fly and I can see that the collision is detected. but the velocities at the collision are weird:
Collision detected with: Flyswatter
Flyswatter velocity:(0.0, 0.0, 0.0) Flyswatter angular velocity: (0.0, 0.0, 0.0)
Relative velocity: (0.0, 0.0, 0.0)
Collision detected with: Flyswatter
Flyswatter velocity:(0.0, 0.0, 0.0) Flyswatter angular velocity: (0.0, 0.0, 0.0)
Relative velocity: (0.1, 0.0, 0.0)
I had the collision detection settings to continuous, but also changing it to discrete or continuous dynamic does not make a diifference (the collision is detected in all cases, but the velocities are wrong).
I also tried changing the Use gravity settings, to see if that might help, but it also does not make a difference.
So I hope someone can point me in the right direction.