Game Development Reference
In-Depth Information
Getting ready
There are various ways of joining two physics bodies together. They vary based on the
places and the location of the bodies that are joined. Joints are divided into the following
types based on the ways they connect bodies with each other:
Pin Joint : This type of joint joins/pins two physics together such that they both
can independently rotate around their anchor point. The joint will look something
similar to following diagram:
Limit Joint : In this type of joints the bodies always maintain the fix maximum dis-
tance from each other. This is something like the bodies are connected to each oth-
er with a rote with a fixed maximum distance which is the length of the rope.
Spring Joint : This type of joint attaches two bodies as if they were connected to
each other with a spring. This makes them behave in a perfectly elastic manner.
The length of the spring can be defined by the initial distance between two bodies.
Sliding Joint : This type of joint allows to bodies to slide with respect to each oth-
er. The sliding axis can be explicitly defined by the user.
Fixed Joint : This type of joint fuses the two physics bodies with each other
through a provided reference point. These joints can be used to create complex ob-
jects, which can be broken into pieces later.
Search WWH ::




Custom Search