Class: Box2D::PrismaticJoint
Constant Summary
Constants inherited
from Joint
Joint::ID_CLASS
Instance Attribute Summary
Attributes inherited from Joint
#body_a, #body_b
Attributes inherited from Handle
#id, #world
Instance Method Summary
collapse
Methods inherited from Joint
#collide_connected=, #collide_connected?, #constraint_force, #constraint_torque, #destroy, #initialize, #invalidate_from_body!, #user_data, #user_data=
Methods inherited from Handle
#destroyed?, #eql?, #hash, #initialize, #valid?
Constructor Details
This class inherits a constructor from Box2D::Joint
Instance Method Details
#motor_speed ⇒ Object
126
127
128
129
|
# File 'lib/box2d/joint.rb', line 126
def motor_speed
ensure_valid!
Native.b2PrismaticJoint_GetMotorSpeed(@id)
end
|
#motor_speed=(value) ⇒ Object
131
132
133
134
|
# File 'lib/box2d/joint.rb', line 131
def motor_speed=(value)
ensure_valid!
Native.b2PrismaticJoint_SetMotorSpeed(@id, ValueConversion.finite_float(value, label: "motor_speed"))
end
|
#speed ⇒ Object
121
122
123
124
|
# File 'lib/box2d/joint.rb', line 121
def speed
ensure_valid!
Native.b2PrismaticJoint_GetSpeed(@id)
end
|
#translation ⇒ Object
116
117
118
119
|
# File 'lib/box2d/joint.rb', line 116
def translation
ensure_valid!
Native.b2PrismaticJoint_GetTranslation(@id)
end
|