Ejemplo n.º 1
0
 public DestroyBlock(BlocksGenerator blocksGenerator, BlockController[,] blocks, BlockGameGenerator blockGameGenerator, BlockPoolView blockPool)
 {
     _blocksGenerator             = blocksGenerator;
     _blocks                      = blocks;
     _blockPool                   = blockPool;
     blockGameGenerator.AddBlock += _blockGameGenerator_AddBlock;
 }
Ejemplo n.º 2
0
 public BlockGameController(BlockPoolView blockPool, IDictionary <Side, Sprite> sideSprites, BlockSpritesViewDescription spritesViewDescription, BlockView previewBlock)
 {
     _blockPool                           = blockPool;
     _sideSprites                         = sideSprites;
     _spritesViewDescription              = spritesViewDescription;
     _previewBlock                        = previewBlock;
     _blocksGenerator                     = new BlocksGenerator(_blockPool, _spritesViewDescription);
     _blocksGenerator.ChangeBlockPrewiew += _blocksGenerator_ChangeBlockPrewiew;
     _blocks                  = new BlockController[_weightGamePole, _heightGamePole];
     _blockGameGenerator      = new BlockGameGenerator(_blocks, _borderGamePole, _weightGamePole, _heightGamePole, _blocksGenerator, _spritesViewDescription, _sideSprites);
     _blockGamePoleController = new BlockGamePoleController(_blocks, _weightGamePole, _heightGamePole, _borderGamePole, _blockGameGenerator);
     _destroyBlock            = new DestroyBlock(_blocksGenerator, _blocks, _blockGameGenerator, _blockPool);
     _blockStateController    = new BlockStateController(_blockGameGenerator, _blockGamePoleController, _destroyBlock);
 }
Ejemplo n.º 3
0
 public BlocksGenerator(BlockPoolView blockPool, BlockSpritesViewDescription spritesViewDescription)
 {
     _blockPool = blockPool;
     _spritesViewDescription = spritesViewDescription;
     _blocks.Push(GenBlock());
 }