Skip to content

Class: AllCollideAlgorithm

AllCollideAlgorithm provides an algorithm that always detects all collisions between all shapes, used in testing or as a placeholder algorithm

Implements

Table of contents

Constructors

Methods

Constructors

constructor

+ new AllCollideAlgorithm(): AllCollideAlgorithm

Returns: AllCollideAlgorithm

Methods

CalculateCollisions

CalculateCollisions(shapes: IShape[]): CollisionInfo[]

CalculateCollisions calculates all collisions between the shapes provided, returning a list of CollisionInfos, each representing a Collision.

Parameters:

Name Type
shapes IShape[]

Returns: CollisionInfo[]

Implementation of: ICollisionAlgorithm