Exemplo n.º 1
0
        public override CellsGroup GetArea(GridCell hitGridCell)
        {
            CellsGroup      cG   = new CellsGroup();
            List <GridCell> area = MBoard.grid.GetAllByID(hitGridCell.Match.GetID());

            cG.Add(hitGridCell);
            foreach (var item in area)
            {
                if (hitGridCell.IsMatchObjectEquals(item) && item.IsMatchable)
                {
                    cG.Add(item);
                }
            }

            return(cG);
        }
Exemplo n.º 2
0
        public override CellsGroup GetArea(GridCell hitGridCell)
        {
            CellsGroup      cG   = new CellsGroup();
            List <GridCell> area = new NeighBors(hitGridCell, true).Cells;

            cG.Add(hitGridCell);
            foreach (var item in area)
            {
                if (hitGridCell.IsMatchObjectEquals(item) && item.IsMatchable)
                {
                    cG.Add(item);
                }
            }

            return(cG);
        }