C# Class Protogame.DefaultPlatforming

The default platforming.
Inheritance: IPlatforming
Exibir arquivo Open project: RedpointGames/Protogame

Public Methods

Method Description
ApplyActionUntil ( IBoundingBox entity, Action action, bool>.Func check, int maximum ) : void

The apply action until.

ApplyGravity ( IHasVelocity entity, float xGravity, float yGravity ) : void

The apply gravity.

ApplyMovement ( IBoundingBox entity, int xAmount, int yAmount, IEnumerable entities, bool>.Func ground ) : bool

The apply movement.

ApplyOverheadCheck ( IBoundingBox entity, IEnumerable entities, bool>.Func ground, float yGravity, bool bounce ) : bool
ClampSpeed ( IHasVelocity entity, float maximumXSpeed, float maximumYSpeed ) : void

The clamp speed.

DefaultPlatforming ( ITransformUtilities transformUtilities, IBoundingBoxUtilities boundingBoxUtilities ) : Microsoft.Xna.Framework

Initializes a new instance of the DefaultPlatforming class.

IsAtCeiling ( IBoundingBox entity, IEnumerable entities, bool>.Func ground ) : bool

The is on ground.

IsOnGround ( IBoundingBox entity, IEnumerable entities, bool>.Func ground ) : bool

The is on ground.

PerformHorizontalAlignment ( IBoundingBox entity, int cellWidth, int cellAlignment, int maxAdjust, System.Action simulateLeft, System.Action simulateRight ) : void

The perform horizontal alignment.

Method Details

ApplyActionUntil() public method

The apply action until.
public ApplyActionUntil ( IBoundingBox entity, Action action, bool>.Func check, int maximum ) : void
entity IBoundingBox /// The entity. ///
action Action /// The action. ///
check bool>.Func /// The check. ///
maximum int /// The maximum. ///
return void

ApplyGravity() public method

The apply gravity.
public ApplyGravity ( IHasVelocity entity, float xGravity, float yGravity ) : void
entity IHasVelocity /// The entity. ///
xGravity float /// The x gravity. ///
yGravity float /// The y gravity. ///
return void

ApplyMovement() public method

The apply movement.
public ApplyMovement ( IBoundingBox entity, int xAmount, int yAmount, IEnumerable entities, bool>.Func ground ) : bool
entity IBoundingBox /// The entity. ///
xAmount int /// The x amount. ///
yAmount int /// The y amount. ///
entities IEnumerable /// The entities. ///
ground bool>.Func /// The ground. ///
return bool

ApplyOverheadCheck() public method

public ApplyOverheadCheck ( IBoundingBox entity, IEnumerable entities, bool>.Func ground, float yGravity, bool bounce ) : bool
entity IBoundingBox
entities IEnumerable
ground bool>.Func
yGravity float
bounce bool
return bool

ClampSpeed() public method

The clamp speed.
public ClampSpeed ( IHasVelocity entity, float maximumXSpeed, float maximumYSpeed ) : void
entity IHasVelocity /// The entity. ///
maximumXSpeed float /// The maximum x speed. ///
maximumYSpeed float /// The maximum y speed. ///
return void

DefaultPlatforming() public method

Initializes a new instance of the DefaultPlatforming class.
public DefaultPlatforming ( ITransformUtilities transformUtilities, IBoundingBoxUtilities boundingBoxUtilities ) : Microsoft.Xna.Framework
transformUtilities ITransformUtilities /// The transform utilities. ///
boundingBoxUtilities IBoundingBoxUtilities /// The bounding box utilities. ///
return Microsoft.Xna.Framework

IsAtCeiling() public method

The is on ground.
public IsAtCeiling ( IBoundingBox entity, IEnumerable entities, bool>.Func ground ) : bool
entity IBoundingBox /// The entity. ///
entities IEnumerable /// The entities. ///
ground bool>.Func /// The ground. ///
return bool

IsOnGround() public method

The is on ground.
public IsOnGround ( IBoundingBox entity, IEnumerable entities, bool>.Func ground ) : bool
entity IBoundingBox /// The entity. ///
entities IEnumerable /// The entities. ///
ground bool>.Func /// The ground. ///
return bool

PerformHorizontalAlignment() public method

The perform horizontal alignment.
public PerformHorizontalAlignment ( IBoundingBox entity, int cellWidth, int cellAlignment, int maxAdjust, System.Action simulateLeft, System.Action simulateRight ) : void
entity IBoundingBox /// The entity. ///
cellWidth int /// The cell width. ///
cellAlignment int /// The cell alignment. ///
maxAdjust int /// The max adjust. ///
simulateLeft System.Action /// The simulate left. ///
simulateRight System.Action /// The simulate right. ///
return void