public UniTask Initialize() { _asteroidGameSettings = DIResolver.GetObject <AsteroidGameSettings>(); _gameSignal = DIResolver.GetObject <GameSignals>(); _bookKeepingInGameData = DIResolver.GetObject <BookKeepingInGameData>(); return(UniTask.CompletedTask); }
protected override string OnInit() { string res = base.OnInit(); _gameSignals = DIResolver.GetObject <GameSignals>(); _bookKeepingInGameData = DIResolver.GetObject <BookKeepingInGameData>(); return(res); }
public UniTask Initialize() { _gameSignals = DIResolver.GetObject <GameSignals>(); _bookKeepingInGameData = DIResolver.GetObject <BookKeepingInGameData>(); _gameSignals.PlayerDespawnedSignal.Listen(HandlePlayerDespawned, PlayerDespawnedPrioritySignal.Priority.DECREASE_PLAYER_LIFE).AddTo(disposables); return(UniTask.CompletedTask); }
public UniTask Initialize() { _gameSignals = DIResolver.GetObject <GameSignals>(); _bookKeepingInGameData = DIResolver.GetObject <BookKeepingInGameData>(); _asteroidGameSettings = DIResolver.GetObject <AsteroidGameSettings>(); _playerSpawnerSystem = DIResolver.GetObject <PlayerSpawnerSystem>(); _gameSignals.PlayerDespawnedSignal.Listen(HandlePlayerDespawned, PlayerDespawnedPrioritySignal.Priority.RESPAWN_PLAYER).AddTo(disposables); return(UniTask.CompletedTask); }
public async UniTask Initialize() { _multiplePrefabMemoryPool = DIResolver.GetObject <MultiplePrefabMemoryPool>(); _gameSignals = DIResolver.GetObject <GameSignals>(); _asteroidGameSettings = DIResolver.GetObject <AsteroidGameSettings>(); _bookKeepingInGameData = DIResolver.GetObject <BookKeepingInGameData>(); _gameSignals.GameStartSignal.Listen(HandleGameStart, GameStartPrioritySignal.PRIORITY_SPAWN_PLAYER).AddToDisposables(disposables); _gameSignals.GameEntityDespawnedSignal.Listen(HandleGameEntityDespawned).AddToDisposables(disposables); await UniTask.CompletedTask; }
public UniTask Initialize() { _bookKeepingInGameData = DIResolver.GetObject <BookKeepingInGameData>(); _asteroidGameSettings = DIResolver.GetObject <AsteroidGameSettings>(); _bookKeepingInGameData.Score.Subscribe(x => { EvaluateScore(x); }).AddTo(disposables); return(UniTask.CompletedTask); }
public UniTask Initialize() { _highScoreManager = DIResolver.GetObject <HighScoreManager>(); _gameSignals = DIResolver.GetObject <GameSignals>(); _bookKeepingInGameData = DIResolver.GetObject <BookKeepingInGameData>(); _gameSignals.GameOverSignal.Listen(HandleGameOver).AddToDisposables(disposables); _bookKeepingInGameData.HighScore.Value = _highScoreManager.GetCurrentHighScore(); return(UniTask.CompletedTask); }
public UniTask Initialize() { _gameSignals = DIResolver.GetObject <GameSignals>(); _asteroidSpawnerSystem = DIResolver.GetObject <AsteroidSpawnerSystem>(); _asteroidAssetSource = DIResolver.GetObject <AsteroidGameAssetSource>(); _bookKeepingInGameData = DIResolver.GetObject <BookKeepingInGameData>(); _gameSignals.GameStartSignal.Listen(HandleGameStartSignal, GameStartPrioritySignal.PRIORITY_SPAWN_WAVE).AddTo(disposables); _gameSignals.AsteroidSpawnedSignal.Listen(HandleAsteroidSpawned).AddTo(disposables); _gameSignals.AsteroidDespawnedSignal.Listen(HandleAsteroidDespawned).AddTo(disposables); return(UniTask.CompletedTask); }
public UniTask Initialize() { _bookKeepingInGameData = DIResolver.GetObject <BookKeepingInGameData>(); _gameSignal = DIResolver.GetObject <GameSignals>(); _bookKeepingInGameData.PlayerLife.Subscribe(life => { if (life == 0) { GoToGameOverState(); } }).AddTo(disposables); return(UniTask.CompletedTask); }
protected override void OnInit() { base.OnInit(); _bookKeepingInGameData = DIResolver.GetObject <BookKeepingInGameData>(); }
protected override Task OnUISceneInit() { _bookKeepingInGameData = DIResolver.GetObject <BookKeepingInGameData>(); return(Task.CompletedTask); }
public UniTask Initialize() { _bookKeepingInGameData = DIResolver.GetObject <BookKeepingInGameData>(); return(UniTask.CompletedTask); }