示例#1
0
        public Nullable <Rectangle> GetRectIfPlayerIsBlocked(BoundingArea boundingArea)
        {
            Rectangle limitRect = _tileArray[0, 0].GetBoundingArea().GetRect();

            limitRect.Width  = _width * _tileWidth;
            limitRect.Height = _height * _tileHeight;
            if (!limitRect.Contains(boundingArea.GetRect()))
            {
                return(limitRect);
            }

            return(getIntersectingRectangle(boundingArea));
        }
示例#2
0
 public bool Contains(BoundingArea boundingArea)
 {
     return(GetRect().Contains(boundingArea.GetRect()));
 }
示例#3
0
 public bool Intersects(BoundingArea boundingArea)
 {
     return(GetRect().Intersects(boundingArea.GetRect()));
 }