Пример #1
0
 public StartingGameState(
     StateFactory stateFactory,
     MoveBallSignal moveBallSignal,
     MovePlayerSignal movePlayerSignal,
     PlayerController.Settings playerSettings,
     LaunchBallSignal launchBallSignal)
 {
     _stateFactory     = stateFactory;
     _moveBallSignal   = moveBallSignal;
     _movePlayerSignal = movePlayerSignal;
     _playerSettings   = playerSettings;
     _launchBallSignal = launchBallSignal;
 }
Пример #2
0
        public StartingGameState(
            StateFactory stateFactory,
            LaunchBallSignal launchBallSignal,
            AttachToPlayerSignal attachToPlayerSignal,
            LevelManager levelManager,
            ResetPlayerStateSignal resetPlayerStateSignal)
        {
            _stateFactory         = stateFactory;
            _levelManager         = levelManager;
            _attachToPlayerSignal = attachToPlayerSignal;
            _launchBallSignal     = launchBallSignal;

            resetPlayerStateSignal.Fire();
        }
Пример #3
0
 public PlayingState(
     StateFactory stateFactory,
     FloorTouchedSignal floorTouchedSignal,
     AttachToPlayerSignal attachToPlayerSignal,
     LevelCompletedSignal levelCompletedSignal,
     ResetPlayerStateSignal resetPlayerStateSignal,
     GiveScorepointsSignal giveScorepointsSignal)
 {
     _stateFactory           = stateFactory;
     _resetPlayerStateSignal = resetPlayerStateSignal;
     _giveScorepointsSignal  = giveScorepointsSignal;
     floorTouchedSignal     += OnGameEnded;
     levelCompletedSignal   += OnLevelCompleted;
     attachToPlayerSignal.Fire(false);
 }
Пример #4
0
 public PlayingState(StateFactory stateFactory, MovePlayerSignal movePlayerSignal, GameEndedSignal gameEndedSignal)
 {
     _stateFactory     = stateFactory;
     _movePlayerSignal = movePlayerSignal;
     gameEndedSignal  += OnGameEnded;
 }