Exemple #1
0
        public void PutInMiddle(D thisCard)
        {
            int index;

            index = _objectList.Count / 2;
            if (DeckStyle == EnumStyleType.Unknown)
            {
                thisCard.IsUnknown = true; //i think if putting in middle, should be unknown
            }
            else
            {
                thisCard.IsUnknown = false;
            }
            _objectList.InsertMiddle(index, thisCard);
        }
Exemple #2
0
        public void CutDeck()
        {
            if (_objectList.Count < 4)
            {
                throw new BasicBlankException("Cannot cut deck because there are less then 4 cards left");
            }
            int Index;

            Index = _objectList.Count / 2;
            if (_objectList.ObjectExist(CurrentCard.Deck))
            {
                _objectList.RemoveObjectByDeck(CurrentCard.Deck); //try this way.  not sure if it will later cause problems but its a risk to try to take.
            }
            _objectList.InsertMiddle(Index, CurrentCard);
            RemoveFromPile();
        }