class

CP::Constraint::DampedRotarySpring

Inherits CP::Constraint / Reference / Object

Like a damped spring, but works in an angular fashion

Constructors

new(a : Body, b : Body, rest_angle : Number, stiffness : Number, damping : Number)
Source

Instance methods

damping

How soft to make the damping of the spring.

Source
damping=(damping : Number)
Source
rest_angle

The relative angle in radians that the bodies want to have

Source
rest_angle=(rest_angle : Number)
Source
spring_torque(relative_angle : Float64) : Number

(can be overridden in a subclass)

Source
stiffness

The stiffness of the spring in force/distance.

Source
stiffness=(stiffness : Number)
Source