/// <summary> /// Начало 2 игры сплита /// </summary> public void SplitGame2Start() { _deck.Shuffle(CardCount); //перемешиваем колоду и берем из нее 11 карт //добавляем карты из основной игры в сплит-колоды PlayerCardsList_Split2.Add(PlayerSecondCard); DealerSplitCardsList.Add(DealerFirstCard); DealerSplitCardsList.Add(DealerSecondCard); // Берем карту из главной игры totalplayer += PlayerSecondCard.GetValue(); PlayerCards += PlayerSecondCard.GetCaption() + " "; //Берем карты для дилера из главной игры totaldealer += DealerFirstCard.GetValue(); DealerCards += DealerFirstCard.GetCaption() + " "; totaldealer += DealerSecondCard.GetValue(); DealerCards += DealerSecondCard.GetCaption() + " "; PlayerAddCard(PlayerCardsList_Split2); if (GetTotalDealer() == 22) { totaldealer = 2; } }
void ReleaseDesignerOutlets() { if (ButtonStick != null) { ButtonStick.Dispose(); ButtonStick = null; } if (ButtonHit != null) { ButtonHit.Dispose(); ButtonHit = null; } if (LabelPlayerScore != null) { LabelPlayerScore.Dispose(); LabelPlayerScore = null; } if (LabelDealerScore != null) { LabelDealerScore.Dispose(); LabelDealerScore = null; } if (LabelDealersHandTotal != null) { LabelDealersHandTotal.Dispose(); LabelDealersHandTotal = null; } if (LabelPlayersHandTotal != null) { LabelPlayersHandTotal.Dispose(); LabelPlayersHandTotal = null; } if (LabelConvoText != null) { LabelConvoText.Dispose(); LabelConvoText = null; } if (DealerFirstCard != null) { DealerFirstCard.Dispose(); DealerFirstCard = null; } if (DealerSecondCard != null) { DealerSecondCard.Dispose(); DealerSecondCard = null; } if (DealerThirdCard != null) { DealerThirdCard.Dispose(); DealerThirdCard = null; } if (DealerFourthCard != null) { DealerFourthCard.Dispose(); DealerFourthCard = null; } if (DealerFifthCard != null) { DealerFifthCard.Dispose(); DealerFifthCard = null; } if (PlayerFirstCard != null) { PlayerFirstCard.Dispose(); PlayerFirstCard = null; } if (PlayerSecondCard != null) { PlayerSecondCard.Dispose(); PlayerSecondCard = null; } if (PlayerThirdCard != null) { PlayerThirdCard.Dispose(); PlayerThirdCard = null; } if (PlayerFourthCard != null) { PlayerFourthCard.Dispose(); PlayerFourthCard = null; } if (PlayerFifthCard != null) { PlayerFifthCard.Dispose(); PlayerFifthCard = null; } }