예제 #1
0
        /// <summary>
        /// 1 < x < width - 1, 1
        /// </summary>
        private void FormBottom()
        {
            int currentWidth = 1;

            Block current = data.bottomLeft;

            while (currentWidth < (data.width - 1))
            {
                current = current.GetRightAdjacent();
                current.SetSprite(BlockPosition.bottom);
                currentWidth++;
            }
        }
예제 #2
0
        /// <summary>
        /// 1, 1 < x < height
        /// </summary>
        private void FormLeft()
        {
            int currentHeight = 1;

            Block current = data.bottomLeft;

            while (currentHeight < (data.height - 1))
            {
                current = current.GetTopAdjacent();
                current.SetSprite(BlockPosition.left);
                currentHeight++;
            }
        }
예제 #3
0
        /// <summary>
        /// width, 1 < y < height - 1
        /// </summary>
        private void FormRight()
        {
            int currentHeight = (data.height - 1);

            Block current = data.topRight;

            while (currentHeight > 1)
            {
                current = current.GetBottomAdjacent();
                current.SetSprite(BlockPosition.right);
                currentHeight--;
            }
        }
예제 #4
0
        /// <summary>
        /// 1 < x < width - 1, height
        /// </summary>
        private void FormTop()
        {
            int currentWidth = (data.width - 1);

            Block current = data.topRight;

            while (currentWidth > 1)
            {
                current = current.GetLeftAdjacent();
                current.SetSprite(BlockPosition.top);
                currentWidth--;
            }
        }