Table of Contents

Class BepuPhysicsSetup

Namespace
Stride.CommunityToolkit.Bepu
Assembly
Stride.CommunityToolkit.Bepu.dll

Bepu as the physics engine of a SceneSetup: CreatePrimitive gives its entities a BodyComponent (a Body2DComponent for a flat shape) with the collider fitted to the shape, and the grounds a StaticComponent. Chosen with UseBepu<T>(T).

public sealed class BepuPhysicsSetup : PhysicsSetupBase
Inheritance
BepuPhysicsSetup
Inherited Members

Remarks

Methods

AddBody(Entity, Primitive2D, Primitive2DEntityOptions?)

Attaches a dynamic body with the collider that matches shape.

public override void AddBody(Entity entity, Primitive2D shape, Primitive2DEntityOptions? options)

Parameters

entity Entity

The entity with the shape's model.

shape Primitive2D

The shape the model was built from.

options Primitive2DEntityOptions

The options the entity was created with; a package reads its own derived options back from them.

AddBody(Entity, Primitive3D, Primitive3DEntityOptions?)

Attaches a dynamic body with the collider that matches shape.

public override void AddBody(Entity entity, Primitive3D shape, Primitive3DEntityOptions? options)

Parameters

entity Entity

The entity with the shape's model.

shape Primitive3D

The shape the model was built from.

options Primitive3DEntityOptions

The options the entity was created with; a package reads its own derived options back from them.

AddStatic(Entity, Primitive2D, Primitive2DEntityOptions?)

Attaches a static collider that matches shape: a ground, a wall.

public override void AddStatic(Entity entity, Primitive2D shape, Primitive2DEntityOptions? options)

Parameters

entity Entity

The entity with the shape's model.

shape Primitive2D

The shape the model was built from.

options Primitive2DEntityOptions

The options the entity was created with; a package reads its own derived options back from them.

AddStatic(Entity, Primitive3D, Primitive3DEntityOptions?)

Attaches a static collider that matches shape: a ground, a wall.

public override void AddStatic(Entity entity, Primitive3D shape, Primitive3DEntityOptions? options)

Parameters

entity Entity

The entity with the shape's model.

shape Primitive3D

The shape the model was built from.

options Primitive3DEntityOptions

The options the entity was created with; a package reads its own derived options back from them.