コード例 #1
0
ファイル: RulesEngine1.cs プロジェクト: jasmarc/mancala
 public void HandleRemainingSeeds(IBoard board)
 {
     ICup cup = board.Goal(board.Turn);
     Player otherPlayer = this.otherPlayer(board.Turn);
     cup.Seeds += board.SeedsLeft(otherPlayer);
     foreach (ICup c in board.Cups.Where(x => !(x is GoalCup)))
         c.Seeds = 0;
 }