AStarCollisionMap.Collision.CollisionMap.IsCollisionBetween C# (CSharp) Method

IsCollisionBetween() public method

Checks whether there is collision between two points.
public IsCollisionBetween ( Point p1, Point p2 ) : System.Boolean
p1 Point The first point.
p2 Point The second point.
return System.Boolean
        public Boolean IsCollisionBetween(Point p1, Point p2)
        {
            Point[] pixelsBetween = PixelsBetweenPoints(p1, p2, 4);
            foreach (Point p in pixelsBetween)
            {
                if (CollisionAt(p)) return true;
            }
            return false;
        }