Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


Get

Returns this world in a form that can be written through.
Read time 4 minutesLast updated 14 days ago

Definition

  • Type: Method
  • Namespace: Unity.U2D.Physics
  • Assembly: UnityEngine.PhysicsCore2DModule

Get(PhysicsWorld)

Returns this world in a form that can be written through.
public static PhysicsWorld Get(this PhysicsWorld physicsWorld)

Parameters

physicsWorld

The world to return.

Returns

Type

Description

PhysicsWorldThe same world.

Remarks

See PhysicsHandleExtensions for why this is needed. Use world.Get().gravity = gravity in place of world.gravity = gravity.

Get(PhysicsBody)

Returns this body in a form that can be written through.
public static PhysicsBody Get(this PhysicsBody physicsBody)

Parameters

physicsBody

The body to return.

Returns

Type

Description

PhysicsBodyThe same body.

Remarks

See PhysicsHandleExtensions for why this is needed. Use body.Get().linearVelocity = velocity in place of body.linearVelocity = velocity.

Get(PhysicsShape)

Returns this shape in a form that can be written through.
public static PhysicsShape Get(this PhysicsShape physicsShape)

Parameters

physicsShape

The shape to return.

Returns

Type

Description

PhysicsShapeThe same shape.

Remarks

See PhysicsHandleExtensions for why this is needed. Use shape.Get().property = value in place of shape.property = value.

Get(PhysicsComposer)

Returns this composer in a form that can be written through.
public static PhysicsComposer Get(this PhysicsComposer physicsComposer)

Parameters

physicsComposer

The composer to return.

Returns

Type

Description

PhysicsComposerThe same composer.

Remarks

See PhysicsHandleExtensions for why this is needed. Use composer.Get().useDelaunay = useDelaunay in place of composer.useDelaunay = useDelaunay.

Get(PhysicsChain)

Returns this chain in a form that can be written through.
public static PhysicsChain Get(this PhysicsChain physicsChain)

Parameters

physicsChain

The chain to return.

Returns

Type

Description

PhysicsChainThe same chain.

Remarks

See PhysicsHandleExtensions for why this is needed. Use chain.Get().friction = friction in place of chain.friction = friction.

Get(PhysicsJoint)

Returns this joint in a form that can be written through.
public static PhysicsJoint Get(this PhysicsJoint physicsJoint)

Parameters

physicsJoint

The joint to return.

Returns

Type

Description

PhysicsJointThe same joint.

Remarks

See PhysicsHandleExtensions for why this is needed. Use joint.Get().property = value in place of joint.property = value.

Get(PhysicsDistanceJoint)

Returns this distance joint in a form that can be written through.
public static PhysicsDistanceJoint Get(this PhysicsDistanceJoint physicsDistanceJoint)

Parameters

physicsDistanceJoint

The distance joint to return.

Returns

Type

Description

PhysicsDistanceJointThe same distance joint.

Remarks

See PhysicsHandleExtensions for why this is needed. Use joint.Get().property = value in place of joint.property = value.

Get(PhysicsFixedJoint)

Returns this fixed joint in a form that can be written through.
public static PhysicsFixedJoint Get(this PhysicsFixedJoint physicsFixedJoint)

Parameters

physicsFixedJoint

The fixed joint to return.

Returns

Type

Description

PhysicsFixedJointThe same fixed joint.

Remarks

See PhysicsHandleExtensions for why this is needed. Use joint.Get().property = value in place of joint.property = value.

Get(PhysicsHingeJoint)

Returns this hinge joint in a form that can be written through.
public static PhysicsHingeJoint Get(this PhysicsHingeJoint physicsHingeJoint)

Parameters

physicsHingeJoint

The hinge joint to return.

Returns

Type

Description

PhysicsHingeJointThe same hinge joint.

Remarks

See PhysicsHandleExtensions for why this is needed. Use joint.Get().property = value in place of joint.property = value.

Get(PhysicsIgnoreJoint)

Returns this ignore joint in a form that can be written through.
public static PhysicsIgnoreJoint Get(this PhysicsIgnoreJoint physicsIgnoreJoint)

Parameters

physicsIgnoreJoint

The ignore joint to return.

Returns

Type

Description

PhysicsIgnoreJointThe same ignore joint.

Remarks

See PhysicsHandleExtensions for why this is needed. Use joint.Get().property = value in place of joint.property = value.

Get(PhysicsRelativeJoint)

Returns this relative joint in a form that can be written through.
public static PhysicsRelativeJoint Get(this PhysicsRelativeJoint physicsRelativeJoint)

Parameters

physicsRelativeJoint

The relative joint to return.

Returns

Type

Description

PhysicsRelativeJointThe same relative joint.

Remarks

See PhysicsHandleExtensions for why this is needed. Use joint.Get().property = value in place of joint.property = value.

Get(PhysicsSliderJoint)

Returns this slider joint in a form that can be written through.
public static PhysicsSliderJoint Get(this PhysicsSliderJoint physicsSliderJoint)

Parameters

physicsSliderJoint

The slider joint to return.

Returns

Type

Description

PhysicsSliderJointThe same slider joint.

Remarks

See PhysicsHandleExtensions for why this is needed. Use joint.Get().property = value in place of joint.property = value.

Get(PhysicsWheelJoint)

Returns this wheel joint in a form that can be written through.
public static PhysicsWheelJoint Get(this PhysicsWheelJoint physicsWheelJoint)

Parameters

physicsWheelJoint

The wheel joint to return.

Returns

Type

Description

PhysicsWheelJointThe same wheel joint.

Remarks

See PhysicsHandleExtensions for why this is needed. Use joint.Get().property = value in place of joint.property = value.