HughPH.Box2D
Organised dotnet bindings for Box2D 3.1.0
Loading...
Searching...
No Matches
Public Member Functions | Properties | List of all members
Box2D.ChainShape Struct Reference

A chain shape is a series of connected line segments. More...

Inherits IEquatable< ChainShape >, and IComparable< ChainShape >.

Public Member Functions

 ChainShape (Body body, ChainDef def)
 Create a ChainShape on the specified body with the specified definition.
 
void Destroy ()
 Destroys this chain shape.
 

Properties

World World [get]
 Gets the world that owns this chain shape.
 
unsafe ReadOnlySpan< ShapeSegments [get]
 The chain segments.
 
float Friction [get, set]
 The chain friction.
 
float Restitution [get, set]
 The chain restitution (bounciness)
 
int Material [get, set]
 The chain material.
 
bool Valid [get]
 Checks if the chain shape is valid.
 

Detailed Description

A chain shape is a series of connected line segments.

Constructor & Destructor Documentation

◆ ChainShape()

Box2D.ChainShape.ChainShape ( Body  body,
ChainDef  def 
)
inline

Create a ChainShape on the specified body with the specified definition.

Parameters
bodyThe body on which to create the shape
defThe ChainDef definition

Member Function Documentation

◆ Destroy()

void Box2D.ChainShape.Destroy ( )
inline

Destroys this chain shape.

This will remove the chain shape from the world and destroy all contacts associated with this shape

Property Documentation

◆ Valid

bool Box2D.ChainShape.Valid
get

Checks if the chain shape is valid.

Returns
True if the chain shape is valid, false otherwise

◆ World

World Box2D.ChainShape.World
get

Gets the world that owns this chain shape.

Returns
The world that owns this chain shape

The documentation for this struct was generated from the following file: