C# Класс FarseerPhysics.Controllers.BuoyancyController

Наследование: Controller
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
AngularDragCoefficient float
Density float
LinearDragCoefficient float
Velocity Microsoft.Xna.Framework.Vector2

Открытые методы

Метод Описание
BuoyancyController ( AABB container, float density, float linearDragCoefficient, float rotationalDragCoefficient, Vector2 gravity ) : System.Collections.Generic

Initializes a new instance of the BuoyancyController class.

Update ( float dt ) : void

Описание методов

BuoyancyController() публичный Метод

Initializes a new instance of the BuoyancyController class.
public BuoyancyController ( AABB container, float density, float linearDragCoefficient, float rotationalDragCoefficient, Vector2 gravity ) : System.Collections.Generic
container FarseerPhysics.Collision.AABB Only bodies inside this AABB will be influenced by the controller
density float Density of the fluid
linearDragCoefficient float Linear drag coefficient of the fluid
rotationalDragCoefficient float Rotational drag coefficient of the fluid
gravity Microsoft.Xna.Framework.Vector2 The direction gravity acts. Buoyancy force will act in opposite direction of gravity.
Результат System.Collections.Generic

Update() публичный Метод

public Update ( float dt ) : void
dt float
Результат void

Описание свойств

AngularDragCoefficient публичное свойство

Controls the rotational drag that the fluid exerts on the bodies within it. Use higher values will simulate thick fluid, like honey, lower values to simulate water-like fluids.
public float AngularDragCoefficient
Результат float

Density публичное свойство

Density of the fluid. Higher values will make things more buoyant, lower values will cause things to sink.
public float Density
Результат float

LinearDragCoefficient публичное свойство

Controls the linear drag that the fluid exerts on the bodies within it. Use higher values will simulate thick fluid, like honey, lower values to simulate water-like fluids.
public float LinearDragCoefficient
Результат float

Velocity публичное свойство

Acts like waterflow. Defaults to 0,0.
public Vector2,Microsoft.Xna.Framework Velocity
Результат Microsoft.Xna.Framework.Vector2