Table of Contents

Class CircleCollider

Namespace
MonoEight.Core.Physics
Assembly
MonoEight.Template.dll

A circular Collider.

public class CircleCollider : Collider, IDisposable
Inheritance
CircleCollider
Implements
Inherited Members

Constructors

CircleCollider(int)

Initializes a new instance of the CircleCollider with the given radius.

public CircleCollider(int radius)

Parameters

radius int

The radius of the collider.

Properties

Radius

Gets or sets the radius.

public int Radius { get; set; }

Property Value

int

Methods

Draw(SpriteBatch)

Called once per frame to render the component.

protected override void Draw(SpriteBatch spriteBatch)

Parameters

spriteBatch SpriteBatch

Microsoft.Xna.Framework.Graphics.SpriteBatch

Intersects(Point)

Whether this collider intersects with the given Microsoft.Xna.Framework.Point.

public override bool Intersects(Point point)

Parameters

point Point

The Microsoft.Xna.Framework.Point to check against.

Returns

bool

true if the collider intersect with the given Microsoft.Xna.Framework.Point.

Intersects(BoxCollider)

Whether this collider intersects with the given BoxCollider.

public override bool Intersects(BoxCollider other)

Parameters

other BoxCollider

The BoxCollider to check against.

Returns

bool

true if the collider intersect with the given BoxCollider.

Intersects(CircleCollider)

Whether this collider intersects with the given CircleCollider.

public override bool Intersects(CircleCollider other)

Parameters

other CircleCollider

The CircleCollider to check against.

Returns

bool

true if the collider intersect with the given CircleCollider.

Intersects(Collider)

Whether this collider intersects with the other given collider.

public override bool Intersects(Collider other)

Parameters

other Collider

The other collider used to check intersection.

Returns

bool

true if the colliders intersect.