Пример #1
0
        private async Task InitializeChain()
        {
            Log.Information("Initialize Chain");

            var chain = Enumerable.Range(0, this.Options.StartLength)
                        .Select(_ => this.PickRandomButton())
                        .ToList();

            this.Status             = new SimpleGameStatus(chain);
            this.timeSpanCalculator = new SimpleGameTimeSpanCalculator(this.Options, this.Status);

            await this.stateMachine.FireAsync(SimpleGameEvent.DisplayChain);
        }
Пример #2
0
 public SimpleGameTimeSpanCalculator(SimpleGameOptions options, SimpleGameStatus status)
 {
     this.options = options;
     this.status  = status;
 }