示例#1
0
        public GameLayer(CCSizeI size, CCColor4B backcolor) : base(backcolor)
        {
            // _gameType = gameTipe;

            // create and initialize a Label
            //labelScore.VerticalAlignment = CCVerticalTextAlignment.Top;


            //CRect rect = new CCRect(50, 50, 200, 200);

            //CCDrawNode tile = new CCDrawNode();
            //var color = new CCColor4F(255, 216, 0, 0.5f);
            //tile.DrawRect(rect, new CCColor4F(color));

            //CCRect rect2 = new CCRect(50, 50 + 200, 200, 200);
            //CCDrawNode tile2 = new CCDrawNode();
            //tile.DrawRect(rect2, CCColor4B.Red);

            // add the label as a child to this Layer
            //int i = 0;



            InitProgressTimer(size);

            InitSquares();

            _soundButton = new Sound();
            AddChild(_soundButton);

            _pauseButton = new Pause();
            AddChild(_pauseButton);

            //InitNewGameComponents();

            _pauseButton.OnTapped = OnPausePressed;
        }
示例#2
0
 internal void SetPausePosition(Pause pauseButton)
 {
     pauseButton.Position = new CCPoint(levelsHorizontalPosition, firstRowSquaresVerticalPosition + 170);
 }