MotorJoint

Available since LÖVE 0.9.0
This type is not supported in earlier versions.

Controls the relative motion between two Bodies. Position and rotation offsets can be specified, as well as the maximum motor force and torque that will be applied to reach the target offsets.

Constructors

love.physics.newMotorJoint Creates a joint between two bodies which controls the relative motion between them. Added since 0.9.0

Functions

Joint:destroy Explicitly destroys the Joint.
Joint:getAnchors Get the anchor points of the joint.
Joint:getBodies Gets the bodies that the Joint is attached to. Added since 0.9.2
Joint:getCollideConnected Gets whether the connected Bodies collide.
Joint:getReactionForce Returns the reaction force on the second body.
Joint:getReactionTorque Returns the reaction torque on the second body.
Joint:getType Gets a string representing the type.
Joint:getUserData Returns the Lua value associated with this Joint. Added since 0.9.2
Joint:isDestroyed Gets whether the Joint is destroyed. Added since 0.9.2
Joint:setCollideConnected Sets whether the connected Bodies should collide with each other. Removed in 0.8.0
Joint:setUserData Associates a Lua value with the Joint. Added since 0.9.2
MotorJoint:getAngularOffset Gets the target angular offset between the two Bodies the Joint is attached to. Added since 0.9.0
MotorJoint:getLinearOffset Gets the target linear offset between the two Bodies the Joint is attached to. Added since 0.9.0
MotorJoint:setAngularOffset Sets the target angular offset between the two Bodies the Joint is attached to. Added since 0.9.0
MotorJoint:setLinearOffset Sets the target linear offset between the two Bodies the Joint is attached to. Added since 0.9.0

Supertypes

See Also

Other Languages