Class PinJoint
Definition
- Assembly:
- Tizen.NUI.Physics2D.dll
PinJoint links shapes with a solid bar or pin. Keeps the anchor points at a set distance from one another.
public class PinJoint : Constraint
- Inheritance
Constructors
View SourcePinJoint(Body, Body, Vect, Vect)
The distance between the two anchor points is measured when the joint is created. If you want to set a specific distance, use the setter function to override it.
Declaration
public PinJoint(Body bodyA, Body bodyB, Vect anchorA, Vect anchorB)
Parameters
Type | Name | Description |
---|---|---|
Body | bodyA | One of the two bodies to connect. |
Body | bodyB | One of the two bodies to connect. |
Vect | anchorA | The anchor point for |
Vect | anchorB | The anchor point for |
Properties
View SourceAnchorA
The location of the first anchor relative to the first body.
Declaration
public Vect AnchorA { get; set; }
Property Value
Type | Description |
---|---|
Vect |
AnchorB
The location of the second anchor relative to the second body.
Declaration
public Vect AnchorB { get; set; }
Property Value
Type | Description |
---|---|
Vect |
Distance
The distance the joint will maintain between the two anchors.
Declaration
public double Distance { get; set; }
Property Value
Type | Description |
---|---|
double |
Methods
View SourceIsPinJoint(Constraint)
Check if a constraint is a PinJoint.
Declaration
public static bool IsPinJoint(Constraint constraint)
Parameters
Type | Name | Description |
---|---|---|
Constraint | constraint |
Returns
Type | Description |
---|---|
bool |