public override void EnterState(GameManager owner) { _aliensController = ServiceLocator.Resolve <AliensController>(); _statePreparators = ServiceLocator.ResolveList <StatePreparator>(); _audioManager = ServiceLocator.Resolve <AudioManager>(); if (_aliensController.IsNull()) { return; } if (_statePreparators.Count == 0) { return; } foreach (var sp in _statePreparators) { sp.DisableComponents(); } Prepare(owner); }
private void Initialize() => _aliensController = GetComponent <AliensController>();