public GameplayScreen()
        {
            TransitionOnTime = TimeSpan.FromSeconds(1.5);
            TransitionOffTime = TimeSpan.FromSeconds(0.5);

            #if XBOX
            scale = 0.5f;
            x = 245; y = 150;
            #elif WINDOWS
            scale = 1.0f;
            x = 135; y = 150;
            #endif

            sounds = new ReachSoundManager(0.50f, 0.50f);
            scoreKeeper = new Scoring(x, 0, sounds);
            board = new Board(10, 22, scale, new Vector2(x, y), scoreKeeper);
            nextPiece = new Piece(board);
            swapPiece = new Piece(board);
            currentPiece = new Piece(board, swapPiece, sounds, scoreKeeper);
            theGenerator = new RandomGenerator();

            pieceList.Add(sounds);
            pieceList.Add(scoreKeeper);
            pieceList.Add(board);
            pieceList.Add(theGenerator);

            Initialize();
        }
Beispiel #2
0
 public Piece(Board theBoard)
     : this()
 {
     IsGameOver = false;
     UseGhostPiece = true;
     FirstSwap = false;
     this.theBoard = theBoard;
 }
Beispiel #3
0
 public Piece(Board theBoard, Piece swapPiece, ReachSoundManager sounds, Scoring scoreKeeper)
     : this(theBoard)
 {
     this.swapPiece = swapPiece;
     Sounds = sounds;
     ScoreKeeper = scoreKeeper;
     Drop = new Board.ScoringEvent(ScoreKeeper.Drop);
     TimeSinceLastAutoDrop = 0;
 }