19.10.1
Damped Rotary Spring
spring = physics.DampedRotarySpring(a, b, restAngle,
stiffness, damping)
Parameter |
Type |
Description |
---|---|---|
a |
in physics.Body |
First Body |
b |
in physics.Body |
Second Body |
restAngle |
in number |
Relative angle in radians that the Bodies want to maintain |
stiffness |
in number |
The spring constant |
damping |
in numbe |
How soft to make the damping of the spring |
spring |
out physics.DampedRotarySpring |
New DampedRotarySpring |
Like a damped spring, but works in an angular fashion. restAngle is the relative angle in radians that the Bodies want to have, stiffness and damping work basically the same as on a damped spring.
Accessors |
Type |
---|---|
setRestAngle, restAngle |
number |
setStiffness, stiffness |
number |
setDamping, damping |
number |
Introduced in platform.apiLevel = '2.0'