public TarotCard FindCardAllInformation(string cardName)
 {
     if (TarotDatabaseObject == null)
     {
         ObtainDatabase();
     }
     try
     {
         var dummyTarot = new TarotCard();
         foreach (var card in TarotDatabaseObject.database)
         {
             if (TryGetCardInformationInCardDataBase(card, cardName))
             {
                 dummyTarot = new TarotCard(card.cardName, card.cardEngName, card.number, card.keyword,
                                            card.curSituation_up, card.curSituation_re, card.feelings_up, card.feelings_re, card.cause_up,
                                            card.cause_re, card.future_up, card.future_re,
                                            card.advice_up, card.advice_re, card.love_up, card.love_re, card.work_up, card.work_re,
                                            card.interpersonal_up, card.interpersonal_re, card.other_up, card.other_re);
                 break;
             }
         }
         return(dummyTarot);
     }
     catch (Exception e)
     {
         Console.WriteLine(e);
         throw;
     }
 }
 public void AddDetectCard(TarotCard tarotCard)
 {
     if (cardNameList.Contains(tarotCard.Name))
     {
         return;
     }
     cardNameList.Add(tarotCard.Name);
     detectCardList.Add(tarotCard);
     ReadCardWithSettingsSpreads();
     ReadingCardNumber += 1;
 }
        private static string Advice_ConvertToString(TarotCard card)
        {
            var advice = "";

            if (card.Direction == CardDirection.Upright)
            {
                advice = card.Advice_Up;
            }
            else if (card.Direction == CardDirection.Reversed)
            {
                advice = card.Advice_Re;
            }
            return(advice);
        }
        private static string Word_ConvertToString(TarotCard card)
        {
            var wordResult = "";

            if (card.Direction == CardDirection.Upright)
            {
                wordResult = card.Work_Up;
            }
            else if (card.Direction == CardDirection.Reversed)
            {
                wordResult = card.Work_Re;
            }
            return(wordResult);
        }
        private static string Love_ConvertToString(TarotCard card)
        {
            var loveResult = "";

            if (card.Direction == CardDirection.Upright)
            {
                loveResult = card.Love_Up;
            }
            else if (card.Direction == CardDirection.Reversed)
            {
                loveResult = card.Love_Re;
            }
            return(loveResult);
        }
        private static string Direction_ConvertToString(TarotCard card)
        {
            var directionResult = "";

            if (card.Direction == CardDirection.Upright)
            {
                directionResult = "正位";
            }
            else if (card.Direction == CardDirection.Reversed)
            {
                directionResult = "逆位";
            }
            return(directionResult);
        }
        public TarotCard FindTarotCardByNameAndDirection(string cardName, CardDirection direction, Vector3 position)
        {
            if (TarotDatabaseObject == null)
            {
                ObtainDatabase();
            }
            try
            {
                var dummyTarot = new TarotCard();
                foreach (var card in TarotDatabaseObject.database)
                {
                    if (TryGetCardInformationInCardDataBase(card, cardName))
                    {
                        switch (direction)
                        {
                        case CardDirection.Default:
                            break;

                        case CardDirection.Upright:
                            dummyTarot = new TarotCard(card.cardName, card.cardEngName, card.keyword, direction, position,
                                                       card.curSituation_up, card.feelings_up, card.cause_up, card.future_up,
                                                       card.advice_up, card.love_up, card.work_up, card.interpersonal_up, card.other_up);
                            break;

                        case CardDirection.Reversed:
                            dummyTarot = new TarotCard(card.cardName, card.cardEngName, card.keyword, direction, position,
                                                       card.curSituation_re, card.feelings_re, card.cause_re, card.future_re,
                                                       card.advice_re, card.love_re, card.work_re, card.interpersonal_re, card.other_re);
                            break;
                        }
                    }
                }
                return(dummyTarot);
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
                throw;
            }
        }