Пример #1
0
        public static decimal GetAward(string PrizeContent, Operation_Record record, List <Size_Six> Size_Six_List, ref List <Araw_Return_S> Araw_Return_Ss, ref List <string> NoAwardList, ref List <string> AwardList)
        {
            decimal getdecimal = 0;

            try
            {
                //获取1-6买码对应数据
                List <Size_Six_S> Size_Six_Ss = Size_Six_S.GetBase(record.Buy_Content, Size_Six_List, record.BuyPayReturn);
                //获取开奖六位数
                List <int> contList6 = Split_Hepler.str_to_ints(PrizeContent).ToList();
                contList6.RemoveAt(contList6.Count - 1);

                //对应指定的码特
                int count = 1;
                foreach (var item in contList6)
                {
                    foreach (var buyItem in Size_Six_Ss.Where(i => i.Award_Globe == count))
                    {
                        if (buyItem.GlobeCodeList.Contains(item))
                        {
                            //if (item == 49 && buyItem.IsEnable == (int)IsEnable.Enable)
                            //{
                            //    //使用和局
                            //    Araw_Return_Ss.Add(new Araw_Return_S() { Name = buyItem.Name, Araw_Money = (decimal)record.UnitPrice });
                            //}
                            //else
                            //{
                            getdecimal += (decimal)(buyItem.PayReturn * record.UnitPrice);
                            AwardList.Add(buyItem.Name);
                            //}
                        }
                        else
                        {
                            NoAwardList.Add(buyItem.Name);
                        }
                    }
                    count++;
                }
            }
            catch (Exception ex)
            {
                LogHelper.Error(ex);
            }
            return(getdecimal);
        }
Пример #2
0
 /// <summary>
 /// 设置6系
 /// </summary>
 public void Set_SizeSix(Globe_Clue item, List <Size_Six> Size_Six_List)
 {
     try
     {
         string[] globe_clues = item.Clue.Split(new char[] { ',' });
         string[] globe_pays  = item.Pay.Split(new char[] { ',' });
         for (int i = 0; i < globe_clues.Length; i++)
         {
             int      clue     = Convert.ToInt32(globe_clues[i]);
             Size_Six Size_Six = Size_Six_List.FirstOrDefault(g => g.Code == clue);
             if (Size_Six != null)
             {
                 float      pay        = float.Parse(globe_pays[i]);
                 Size_Six_S Size_Six_S = Size_Six_S.GetBase(Size_Six, pay);
                 this.Size_Six_S_List.Add(Size_Six_S);
             }
         }
     }
     catch (Exception ex)
     {
         LogHelper.Error(ex);
     }
 }
Пример #3
0
        public static void SetContent(Globe_Clue clue, Operation_Record_S item)
        {
            try
            {
                GlobeClueType GlobeClueType = (GlobeClueType)clue.First_Type;
                switch (GlobeClueType)
                {
                case GlobeClueType.Special:
                    item.BuyDisplay     = Globe_S.GetBase_Str(item.Buy_Content, Constant.Globe_List);
                    item.FirstGlobeList = Globe_S.GetBase(item.Buy_Content, Constant.Globe_List);
                    item.FirstIsGloble  = true;
                    item.BuyDisplay2    = Size_S.GetBase_Str(item.Buy_Content2, Constant.Size_Special_List);
                    break;

                case GlobeClueType.Normal:
                    item.BuyDisplay     = Globe_S.GetBase_Str(item.Buy_Content, Constant.Globe_List);
                    item.FirstGlobeList = Globe_S.GetBase(item.Buy_Content, Constant.Globe_List);
                    item.FirstIsGloble  = true;
                    break;

                case GlobeClueType.SpecialNormal:
                    item.BuyDisplay     = Globe_S.GetBase_Str(item.Buy_Content, Constant.Globe_List);
                    item.FirstGlobeList = Globe_S.GetBase(item.Buy_Content, Constant.Globe_List);
                    item.FirstIsGloble  = true;
                    item.BuyDisplay2    = Size_NormalS.GetBase_Str(item.Buy_Content2, Constant.Size_SpecialNormal_List);
                    break;

                case GlobeClueType.NormalSix:
                    item.BuyDisplay = Size_Six_S.GetBase_Str(item.Buy_Content, Constant.Size_Six_List);
                    break;

                case GlobeClueType.Line:
                    item.BuyDisplay     = Globe_S.GetBase_Str(item.Buy_Content, Constant.Globe_List);
                    item.FirstGlobeList = Globe_S.GetBase(item.Buy_Content, Constant.Globe_List);
                    item.FirstIsGloble  = true;
                    break;

                case GlobeClueType.Wave:
                    item.BuyDisplay = Wave_S.GetBase_Str(item.Buy_Content, Constant.Wave_List);
                    break;

                case GlobeClueType.Detail:
                    item.BuyDisplay  = Animal_Info_S.GetBase_Str(item.Buy_Content, Constant.Animal_Info_List);
                    item.BuyDisplay2 = Detail_S.GetBase_Str(item.Buy_Content2, Constant.Detail_List);
                    break;

                case GlobeClueType.SpecialAnimal:
                    item.BuyDisplay = Animal_Info_S.GetBase_Str(item.Buy_Content, Constant.Animal_Info_List);
                    break;

                case GlobeClueType.CombineAnimal:
                    item.BuyDisplay = Animal_Info_S.GetBase_Str(item.Buy_Content, Constant.Animal_Info_List);
                    break;

                case GlobeClueType.LineAnimal:
                    item.BuyDisplay = Animal_Info_S.GetBase_Str(item.Buy_Content, Constant.Animal_Info_List);
                    break;

                case GlobeClueType.LineDetail:
                    item.BuyDisplay = Detail_S.GetBase_Str(item.Buy_Content, Constant.Detail_List);
                    break;

                case GlobeClueType.NotAll:
                    item.BuyDisplay     = Globe_S.GetBase_Str(item.Buy_Content, Constant.Globe_List);
                    item.FirstGlobeList = Globe_S.GetBase(item.Buy_Content, Constant.Globe_List);
                    item.FirstIsGloble  = true;
                    break;

                default:
                    break;
                }
            }
            catch (Exception ex)
            {
                LogHelper.Error(ex);
            }
        }