Class PivotJoint
Definition
- Assembly:
- Tizen.NUI.Physics2D.dll
PivotJoint acts like a swivel, allowing two objects to pivot about a single point.
public class PivotJoint : Constraint
- Inheritance
Constructors
View SourcePivotJoint(Body, Body, Vect, Vect)
Initialize a pivot joint with two anchors. Since the anchors are provided in world coordinates, the bodies must already be correctly positioned. The joint is fixed as soon as the containing space is simulated.
Declaration
public PivotJoint(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 location of one of the anchors, specified in world coordinates. |
Vect | anchorB | The location of one of the anchors, specified in world coordinates. |
PivotJoint(Body, Body, Vect)
Initialize a pivot joint with one anchor. Since the pivot is provided in world coordinates, the bodies must already be correctly positioned.
Declaration
public PivotJoint(Body bodyA, Body bodyB, Vect anchor)
Parameters
Type | Name | Description |
---|---|---|
Body | bodyA | One of the two bodies to connect. |
Body | bodyB | One of the two bodies to connect. |
Vect | anchor | The location of the pivot, specified in world coordinates. |
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 |
Methods
View SourceIsPivotJoint(Constraint)
Check if a constraint is a PinJoint.
Declaration
public static bool IsPivotJoint(Constraint constraint)
Parameters
Type | Name | Description |
---|---|---|
Constraint | constraint |
Returns
Type | Description |
---|---|
bool |