class CP::Constraint::RatchetJoint
- CP::Constraint::RatchetJoint
- CP::Constraint
- Reference
- Object
Overview
Works like a socket wrench.
Defined in:
chipmunk/constraint.crConstructors
-
.new(a : Body, b : Body, phase : Number, ratchet : Number)
ratchet is the distance between "clicks", phase is the initial offset to use when deciding where the ratchet angles are.
Instance Method Summary
-
#angle : Float64
The angle of the current ratchet tooth.
- #angle=(angle : Number)
-
#phase : Float64
The phase offset of the ratchet.
- #phase=(phase : Number)
-
#ratchet : Float64
The angular distance of each ratchet.
- #ratchet=(ratchet : Number)
Instance methods inherited from class CP::Constraint
bodies : Tuple(Body, Body)
bodies,
body_a : Body
body_a,
body_b : Body
body_b,
collide_bodies=(collide_bodies : Bool)
collide_bodies=,
collide_bodies? : Bool
collide_bodies?,
error_bias : Float64
error_bias,
error_bias=(error_bias : Number)
error_bias=,
impulse : Float64
impulse,
max_bias : Float64
max_bias,
max_bias=(max_bias : Number)
max_bias=,
max_force : Float64
max_force,
max_force=(max_force : Number)
max_force=,
post_solve(space : Space)
post_solve,
pre_solve(space : Space)
pre_solve,
space : Space | Nil
space
Constructor Detail
ratchet is the distance between "clicks", phase is the initial offset to use when deciding where the ratchet angles are.