public Game(string player1Name = "", string player2Name = "") { var newDeck = DeckCreator.GenerateDeck(); _playingDeck = DeckCreator.Shuffle(newDeck); CurrentCardStack = new CurrentCardStacks(); var player1 = new Player(1, player1Name); var player2 = new Player(2, player2Name); Players = new List <Player> { player1, player2 }; CurrentPlayer = player1; }
public static bool IsValidMoveAvailableInCurrentCardStacks(ICard currentCard, CurrentCardStacks cardStacks) { var validMove = false; foreach (var column in cardStacks.Columns) { if (IsValidMoveAvailable(currentCard, column)) { validMove = true; } } return(validMove); }