Ejemplo n.º 1
0
        public static void DynamicLog(LogWrapper logWrapperA, LogWrapper logWrapperB)
        {
            Result resultA = GetResult(logWrapperA.TwoCardHash);
            Result resultB = GetResult(logWrapperB.TwoCardHash);

            resultA.TotalCount += 1;
            resultB.TotalCount += 1;
            Judger.Result result;
            bool          aNeedAddCard = NeedAddCard(resultA);
            bool          bNeedAddCard = NeedAddCard(resultB);

            if (!aNeedAddCard && !bNeedAddCard)
            {
                result = Judger.Judge(logWrapperA.ResultOfTwoCard, logWrapperB.ResultOfTwoCard);
                LogResult(result, GetOdds(result, logWrapperA.ResultOfTwoCard, logWrapperB.ResultOfTwoCard), resultA.TwoCard, resultB.TwoCard);
            }
            else if (aNeedAddCard && !bNeedAddCard)
            {
                result = Judger.Judge(logWrapperA.ResultOfThreeCard, logWrapperB.ResultOfTwoCard);
                LogResult(result, GetOdds(result, logWrapperA.ResultOfThreeCard, logWrapperB.ResultOfTwoCard), resultA.ThreeCard, resultB.TwoCard);
            }
            else if (!aNeedAddCard && bNeedAddCard)
            {
                result = Judger.Judge(logWrapperA.ResultOfTwoCard, logWrapperB.ResultOfThreeCard);
                LogResult(result, GetOdds(result, logWrapperA.ResultOfTwoCard, logWrapperB.ResultOfThreeCard), resultA.TwoCard, resultB.ThreeCard);
            }
            else
            {
                result = Judger.Judge(logWrapperA.ResultOfThreeCard, logWrapperB.ResultOfThreeCard);
                LogResult(result, GetOdds(result, logWrapperA.ResultOfThreeCard, logWrapperB.ResultOfThreeCard), resultA.ThreeCard, resultB.ThreeCard);
            }
        }
Ejemplo n.º 2
0
        public static void StaticLog(LogWrapper logWrapperA, LogWrapper logWrapperB)
        {
            Result resultA = GetResult(logWrapperA.TwoCardHash);
            Result resultB = GetResult(logWrapperB.TwoCardHash);

            resultA.TotalCount += 1;
            resultB.TotalCount += 1;
            Judger.Result result;
            result = Judger.Judge(logWrapperA.ResultOfTwoCard, logWrapperB.ResultOfTwoCard);
            LogResult(result, GetOdds(result, logWrapperA.ResultOfTwoCard, logWrapperB.ResultOfTwoCard), resultA.TwoCard, resultB.TwoCard);

            result = Judger.Judge(logWrapperA.ResultOfThreeCard, logWrapperB.ResultOfTwoCard);
            LogResult(result, GetOdds(result, logWrapperA.ResultOfThreeCard, logWrapperB.ResultOfTwoCard), resultA.ThreeCard, resultB.TwoCard);

            result = Judger.Judge(logWrapperA.ResultOfTwoCard, logWrapperB.ResultOfThreeCard);
            LogResult(result, GetOdds(result, logWrapperA.ResultOfTwoCard, logWrapperB.ResultOfThreeCard), resultA.TwoCard, resultB.ThreeCard);

            result = Judger.Judge(logWrapperA.ResultOfThreeCard, logWrapperB.ResultOfThreeCard);
            LogResult(result, GetOdds(result, logWrapperA.ResultOfThreeCard, logWrapperB.ResultOfThreeCard), resultA.ThreeCard, resultB.ThreeCard);
        }