Phaser API Documentation

  Version: 
<static> TriangleToTriangle(triangleA, triangleB)

Description:

Checks if two Triangles intersect.

A Triangle intersects another Triangle if any pair of their lines intersects or if any point of one Triangle is within the other Triangle. Thus, the Triangles are considered "solid".

Parameters:

name type description
triangleA Phaser.Geom.Triangle

The first Triangle to check for intersection.

triangleB Phaser.Geom.Triangle

The second Triangle to check for intersection.

Returns:
Description:

true if the Triangles intersect, otherwise false.

Type:
  • boolean
Examples:
Since: 3.0.0