Engines/FlatRedBallXNA/FlatRedBall/Math/Geometry/AxisAlignedRectangle.cs
/// <summary>
/// Returns whether this instance collides against the argument AxisAlignedRectangle.
/// </summary>
/// <param name="rectangle">The AxisAlignedRectangle to test collision against.</param>
/// <returns>Whether collision has occurred.</returns>
Returns whether this instance collides against the argument AxisAlignedRectangle.
Returns whether this instance collides against the argument AxisAlignedRectangle .
public bool CollideAgainst(AxisAlignedRectangle rectangle)
        {
            UpdateDependencies(TimeManager.CurrentTime);
            rectangle.UpdateDependencies(TimeManager.CurrentTime);
            return (X - mScaleX < rectangle.X + rectangle.mScaleX &&
                X + mScaleX > rectangle.X - rectangle.mScaleX &&
                Y - mScaleY < rectangle.Y + rectangle.mScaleY &&
                Y + mScaleY > rectangle.Y - rectangle.mScaleY);
        }
public bool CollideAgainst ( AxisAlignedRectangle rectangle ) { UpdateDependencies ( TimeManager . CurrentTime ) ; rectangle . UpdateDependencies ( TimeManager . CurrentTime ) ; return ( X - mScaleX < rectangle . X + rectangle . mScaleX && X + mScaleX > rectangle . X - rectangle . mScaleX && Y - mScaleY < rectangle . Y + rectangle . mScaleY && Y + mScaleY > rectangle . Y - rectangle . mScaleY ) ; }
Returns whether this instance collides against the argument AxisAlignedRectangle.
Returns whether this instance collides against the argument AxisAlignedRectangle .
Whether collision has occurred.
Whether collision has occurred .
rectangle
AxisAlignedRectangle
The AxisAlignedRectangle to test collision against.
The AxisAlignedRectangle to test collision against .