public void Rectangles_Seperate() { Assert.False(CollisionChecking.Rectangles(context.RectangleBase.X, context.RectangleBase.Y, context.RectangleBase.Width, context.RectangleBase.Height, context.RectangleSeperate.X, context.RectangleSeperate.Y, context.RectangleSeperate.Width, context.RectangleSeperate.Height)); }
public void Circles_Collide(Circle circle1, Circle circle2) { Assert.True( CollisionChecking.Circles( circle1.X, circle1.Y, circle1.Radius, circle2.X, circle2.Y, circle2.Radius ) ); }
public void Circles_Seperate(Circle circle1, Circle circle2) { Assert.False( CollisionChecking.Circles( circle1.X, circle1.Y, circle1.Radius, circle2.X, circle2.Y, circle2.Radius ) ); }
public void Rectangles_Collide(Rectangle rectangle1, Rectangle rectangle2) { Assert.True( CollisionChecking.Rectangles( rectangle1.X, rectangle1.Y, rectangle1.Width, rectangle1.Height, rectangle2.X, rectangle2.Y, rectangle2.Width, rectangle2.Height ) ); }
public void Rectangles_Seperate(Rectangle rectangle1, Rectangle rectangle2) { Assert.False( CollisionChecking.Rectangles( rectangle1.X, rectangle1.Y, rectangle1.Width, rectangle1.Height, rectangle2.X, rectangle2.Y, rectangle2.Width, rectangle2.Height ) ); }
public void Rectangles_Collide() { Assert.True( CollisionChecking.Rectangles( rectangleBase.X, rectangleBase.Y, rectangleBase.Width, rectangleBase.Height, rectangleCollide.X, rectangleCollide.Y, rectangleCollide.Width, rectangleCollide.Height ) ); }
public void RectangleToCircle_Collide(Rectangle rectangle, Circle circle) { Assert.True(CollisionChecking.RectangleToCircle(rectangle.X, rectangle.Y, rectangle.Width, rectangle.Height, circle.X, circle.Y, circle.Radius)); Assert.True(CollisionChecking.CircleToRectangle(circle.X, circle.Y, circle.Radius, rectangle.X, rectangle.Y, rectangle.Width, rectangle.Height)); }
public void PointsCollide(Vector2 point1, Vector2 point2) { Assert.True(CollisionChecking.Points(point1.X, point1.Y, point2.X, point2.Y)); }
public void PointsSeperate(Vector2 point1, Vector2 point2) { Assert.False(CollisionChecking.Points(point1.X, point1.Y, point2.X, point2.Y)); }
public void LineToPoint_Collide(Line line, Vector2 point) { Assert.True(CollisionChecking.LineToPoint(line.BeginX, line.BeginY, line.EndX, line.EndY, point.X, point.Y)); Assert.True(CollisionChecking.PointToLine(point.X, point.Y, line.BeginX, line.BeginY, line.EndX, line.EndY)); }
public void Lines_Seperate(Line line1, Line line2) { Assert.False(CollisionChecking.Lines(line1.BeginX, line1.BeginY, line1.EndX, line1.EndY, line2.BeginX, line2.BeginY, line2.EndX, line2.EndY)); }
public void CircleToPoint_Collide(Circle circle, Vector2 point) { Assert.True(CollisionChecking.CircleToPoint(circle.X, circle.Y, circle.Radius, point.X, point.Y)); Assert.True(CollisionChecking.PointToCircle(point.X, point.Y, circle.X, circle.Y, circle.Radius)); }
public void CircleToLine_Collide(Circle circle, Line line) { Assert.True(CollisionChecking.CircleToLine(circle.X, circle.Y, circle.Radius, line.BeginX, line.BeginY, line.EndX, line.EndY)); Assert.True(CollisionChecking.LineToCircle(line.BeginX, line.BeginY, line.EndX, line.EndY, circle.X, circle.Y, circle.Radius)); }
public void RectangleToPoint_Collide(Rectangle rectangle, Vector2 point) { Assert.True(CollisionChecking.RectangleToPoint(rectangle.X, rectangle.Y, rectangle.Width, rectangle.Height, point.X, point.Y)); Assert.True(CollisionChecking.PointToRectangle(point.X, point.Y, rectangle.X, rectangle.Y, rectangle.Width, rectangle.Height)); }
public void RectangleToLine_Collide(Rectangle rectangle, Line line) { Assert.True(CollisionChecking.RectangleToLine(rectangle.X, rectangle.Y, rectangle.Width, rectangle.Height, line.BeginX, line.BeginY, line.EndX, line.EndY)); Assert.True(CollisionChecking.LineToRectangle(line.BeginX, line.BeginY, line.EndX, line.EndY, rectangle.X, rectangle.Y, rectangle.Width, rectangle.Height)); }
public void Circles() { Assert.True(CollisionChecking.Circles(10, 10, 5, 17, 10, 5)); Assert.False(CollisionChecking.Circles(10, 10, 5, 20, 10, 5)); }
public void Lines_Collide(Line line1, Line line2) { Assert.True(CollisionChecking.Lines(line1.BeginX, line1.BeginY, line1.EndX, line1.EndY, line2.BeginX, line2.BeginY, line2.EndX, line2.EndY)); }