Tsetso Posted August 28, 2018 Share Posted August 28, 2018 We need to make two objects, made of different material and with different mass and shape, to move alongside each other with the exact same speed. What is the best (or recommended) way to achieve this? We have tried setting the speed of the first object with addForce and applying the addImpulse method in flush() for the second object. Unfortunately, this does not yield satisfactory results and the speed of the second object changes with change in mass or other parameters. Link to comment
andrey-kozlov Posted August 29, 2018 Share Posted August 29, 2018 Hello, Tsetso Speed can be set directly through BodyRigid::setLinearVelocity. Does it work for you? Link to comment
Tsetso Posted August 29, 2018 Author Share Posted August 29, 2018 Hey Andrey, thanks for the tip! We ended up with a combination of addForce() and setLinearVelocity(). Just add to increase the forces magnitudes so they can leak into the final result. Link to comment
Recommended Posts