public void SubjectUpdated() { _currentMainStreamState = _subject.MainStreamState; if (_currentMainStreamState == ThisState()) { _mainStream = true; } else { _mainStream = false; } }
private void AddMainStreamEventHandlers(AutoStrategy strategy) { strategy.RequestMainStream += (s, e) => { if (MainStreamState != MainStreamState.Attack) { return; } MainStreamState = strategy.ThisState(); Notify(); }; strategy.ReleaseMainStream += (s, e) => { if (MainStreamState == MainStreamState.Attack) { MainStreamState = MainStreamState.PickItem; } MainStreamState = MainStreamState.Attack; Notify(); }; }