Пример #1
0
 public void Update(MatchInput input)
 {
     Assert.AreEqual(PlayerInputs.Length, input.PlayerCount);
     for (int i = 0; i < input.PlayerCount; i++)
     {
         PlayerInputs[i].Update(input[i]);
     }
 }
Пример #2
0
 public void Reset(MatchInput current)
 {
     if (PlayerInputs?.Length != current.PlayerCount)
     {
         PlayerInputs = new PlayerInputContext[current.PlayerCount];
     }
     for (int i = 0; i < PlayerInputs.Length; i++)
     {
         PlayerInputs[i] = new PlayerInputContext {
             Current = current[i]
         };
     }
 }
Пример #3
0
 public void Reset(MatchInput previous, MatchInput current)
 {
     Reset(previous);
     Update(current);
 }
Пример #4
0
 public MatchInputContext(MatchInput input)
 {
     Reset(input);
     Predict();
 }
 public MatchInputContext(MatchInput input)
 {
     Reset(input);
 }