C# Class Box2DX.Dynamics.Controllers.Controller

Base class for controllers. Controllers are a convience for encapsulating common per-step functionality.
Inheritance: IDisposable
Show file Open project: danielpcox/Crisis-at-Swiss-Station Class Usage Examples

Protected Properties

Property Type Description
_bodyCount int
_bodyList ControllerEdge

Public Methods

Method Description
AddBody ( Body body ) : void

Adds a body to the controller list.

Controller ( ) : System
Controller ( World world ) : System
Dispose ( ) : void
Draw ( DebugDraw debugDraw ) : void

Controllers override this to provide debug drawing.

RemoveBody ( Body body ) : void

Removes a body from the controller list.

Step ( TimeStep step ) : void

Controllers override this to implement per-step functionality.

Private Methods

Method Description
GetBodyList ( ) : ControllerEdge

Get the attached body list

GetNext ( ) : Controller

Get the next body in the world's body list.

GetWorld ( ) : World

Get the parent world of this body.

Method Details

AddBody() public method

Adds a body to the controller list.
public AddBody ( Body body ) : void
body Body
return void

Controller() public method

public Controller ( ) : System
return System

Controller() public method

public Controller ( World world ) : System
world World
return System

Dispose() public method

public Dispose ( ) : void
return void

Draw() public method

Controllers override this to provide debug drawing.
public Draw ( DebugDraw debugDraw ) : void
debugDraw DebugDraw
return void

RemoveBody() public method

Removes a body from the controller list.
public RemoveBody ( Body body ) : void
body Body
return void

Step() public abstract method

Controllers override this to implement per-step functionality.
public abstract Step ( TimeStep step ) : void
step TimeStep
return void

Property Details

_bodyCount protected property

protected int _bodyCount
return int

_bodyList protected property

protected ControllerEdge,Box2DX.Dynamics.Controllers _bodyList
return ControllerEdge