Construct an Edge by providing the following information.
The first endpoint of the edge
The second endpoint of the edge
Optional
options: { Additional options which describe the edge
A string used to uniquely identify this edge
A PlaceableObject that is responsible for this edge, if any
The type of edge
How this edge restricts light
How this edge restricts movement
How this edge restricts sight
How this edge restricts sound
A direction of effect for the edge
Configuration of threshold data for this edge
The first endpoint of the edge.
The second endpoint of the edge.
A string used to uniquely identify this edge.
The direction of effect for the edge.
How this edge restricts light.
How this edge restricts movement.
How this edge restricts sight.
How this edge restricts sound.
Specialized threshold data for this edge.
The endpoint of the edge which is oriented towards the top-left.
The endpoint of the edge which is oriented towards the bottom-right.
The rectangular bounds of the edge. Used by the quadtree.
Record other edges which this one intersects with.
A PolygonVertex instance. Used as part of ClockwiseSweepPolygon computation.
A PolygonVertex instance. Used as part of ClockwiseSweepPolygon computation.
Get an intersection point between this Edge and another.
Test whether to apply a proximity threshold to this edge. If the proximity threshold is met, this edge excluded from perception calculations.
Sense type for the source
The origin or position of the source on the canvas
Optional
externalRadius: number = 0The external radius of the source
True if the edge has a threshold greater than 0 for the source type, and the source type is within that distance.
Determine the orientation of this Edge with respect to a reference point.
Some reference point, relative to which orientation is determined
An orientation in CONST.WALL_DIRECTIONS which indicates whether the Point is left, right, or collinear (both) with the Edge
Record the intersections between two edges.
Another edge to test and record
Static
identifyIdentify intersections between a provided iterable of edges.
An iterable of edges
A data structure used to represent potential edges used by the ClockwiseSweepPolygon. Edges are not polygon-specific, meaning they can be reused across many polygon instances.