MotorJoint

Keeps the relative translation and rotation between 2 bodies constant. More...

Import Statement: import
Inherits:

Joint

Properties

Detailed Description

A motor joint is used to control the relative motion between two bodies. It is similar to DistanceJoint, with fixed rotation between the 2 bodies.

A typical usage is to control the movement of a dynamic body with respect to the ground.

Property Documentation

angularOffset : real

Defines the rotation from Joint::bodyA to Joint::bodyB, which will be fixed by this joint, in degrees.

If not set, the current rotation at the time of joint creation is used.


correctionFactor : real

Position correction factor between 0 and 1. Default value is 0.3.


linearOffset : point

Defines the direction from Joint::bodyA to Joint::bodyB, which will be fixed by this joint, in local coordinates, in pixels.

If not set, the current direction at the time of joint creation is used.


maxForce : real

The maximum force used to keep the joint's constraints, in kg*pixels/s^2.


maxTorque : real

The maximum torque used to keep the joint's constraints, in kg*pixels^2/s^2.


Videos

Voted #1 for:

  • Easiest to learn
  • Most time saving
  • Best support

Develop Cross-Platform Apps and Games 50% Faster!

  • Voted the best supported, most time-saving and easiest to learn cross-platform development tool
  • Based on the Qt framework, with native performance and appearance on all platforms including iOS and Android
  • Offers a variety of plugins to monetize, analyze and engage users
FREE!
create apps
create games
cross platform
native performance
3rd party services
game network
multiplayer
level editor
easiest to learn
biggest time saving
best support