hannojg / react-native-box2d

JSI port of the Box2D physics engine for React Native.
MIT License
61 stars 3 forks source link

Add restitution (elasticity) #3

Closed tomekzaw closed 1 year ago

tomekzaw commented 1 year ago

This PR exposes restitution (elasticity) parameter.

Example usage:

const fixtureDef = Box2d.b2FixtureDef();
fixtureDef.restitution = 0.5;