private void processBust() { if (ChestAndKeyBeforeAnchor()) { ScoreZones[(int)CurrentPlayersTurn].AddMultipleCards( DiscardPile.DrawRandomLump( CardsBeforeAnchor())); } bool anchor = false; while (Field.Count > 0) { Card currentCard = Field[Field.Count - 1]; if (anchor) { ScoreZones[(int)CurrentPlayersTurn].AddCard(currentCard); } else { DiscardPile.AddCard(currentCard); } Field.Remove(currentCard); if (currentCard.Suit == Suites.Anchors) { anchor = true; } } SwitchPlayers(); DoesCannonNeedTarget = false; KrakenCannonOverride = false; }
private void PerformTakeAllAction() { if (ChestAndKeyBothPresentOnField()) { int cardsToTake = Math.Min(Field.Count, DiscardPile.Count); ScoreZones[(int)CurrentPlayersTurn].AddMultipleCards(DiscardPile.DrawRandomLump(cardsToTake)); } ScoreZones[(int)CurrentPlayersTurn].AddMultipleCards(Field); Field.Clear(); SwitchPlayers(); }