kripken / ammo.js

Direct port of the Bullet physics engine to JavaScript using Emscripten
Other
4.15k stars 558 forks source link

Open new slider constraint functions #395

Closed fabienrohrer closed 2 years ago

fabienrohrer commented 2 years ago

This PR aims to open useful functions used to motorize the slider constraint.

As a reference, the bullet forklift demo use them here: https://github.com/bulletphysics/bullet3/blob/master/examples/ForkLift/ForkLiftDemo.cpp#L803-L805

Thanks to these functions I expect to introduce motorized prismatic joints into BabylonJS: https://doc.babylonjs.com/divingDeeper/physics/joints#motors (I have a working sample in my private project).