private void OnMsg_propviewChangeSkin(MobaMessage msg)
 {
     this.coroutine.StopAllCoroutine();
     if (msg.Param != null)
     {
         this.skinID = (int)msg.Param;
     }
     if (null != this.smodel)
     {
         UnityEngine.Object.Destroy(this.smodel);
     }
     if (null != this.animator)
     {
         UnityEngine.Object.Destroy(this.animator);
     }
     if (this.skinID == 0)
     {
         SysHeroMainVo heroMainData = BaseDataMgr.instance.GetHeroMainData(this.heroNPC);
         if (heroMainData != null)
         {
             this.task_loadModel = this.coroutine.StartCoroutine(this.LoadModel(heroMainData.smodel_id), true);
         }
     }
     else
     {
         SysHeroSkinVo dataById = BaseDataMgr.instance.GetDataById <SysHeroSkinVo>(this.skinID.ToString());
         if (dataById != null)
         {
             this.task_loadModel = this.coroutine.StartCoroutine(this.LoadModel(dataById.smodel_id), true);
         }
     }
 }
Esempio n. 2
0
 private void CreateBookItem(SysCouponVo couponVo)
 {
     if (this.IsIllegalArgument(couponVo))
     {
         return;
     }
     this.SetQualityFrame(couponVo.quality);
     if (couponVo.mother_type == 1)
     {
         SysHeroMainVo dataById = BaseDataMgr.instance.GetDataById <SysHeroMainVo>(couponVo.mother_id);
         if (this.IsIllegalArgument(dataById))
         {
             return;
         }
         this.SetTexture(dataById.avatar_icon, 140);
     }
     else if (couponVo.mother_type == 2)
     {
         SysHeroSkinVo dataById2 = BaseDataMgr.instance.GetDataById <SysHeroSkinVo>(couponVo.mother_id);
         if (this.IsIllegalArgument(dataById2))
         {
             return;
         }
         this.SetTexture(dataById2.avatar_icon, 140);
     }
     this.CouponIcon.spriteName = "Magic_bottle_tujian_discount_" + couponVo.off_number;
 }
Esempio n. 3
0
 public override void Init(string[] param)
 {
     base.Init(param);
     if (base.Valid)
     {
         base.Num = 1;
         SysCouponVo dataById = BaseDataMgr.instance.GetDataById <SysCouponVo>(param[2]);
         if (dataById != null)
         {
             if (dataById.mother_type == 1)
             {
                 SysHeroMainVo dataById2 = BaseDataMgr.instance.GetDataById <SysHeroMainVo>(dataById.mother_id);
                 if (dataById2 != null)
                 {
                     base.SIcon = dataById2.avatar_icon;
                     base.BIcon = dataById2.Loading_icon;
                 }
             }
             else if (dataById.mother_type == 2)
             {
                 SysHeroSkinVo dataById3 = BaseDataMgr.instance.GetDataById <SysHeroSkinVo>(dataById.mother_id);
                 if (dataById3 != null)
                 {
                     base.SIcon = dataById3.avatar_icon;
                     base.BIcon = dataById3.Loading_icon;
                 }
             }
             base.ExtraData = dataById;
             base.TypeDes   = LanguageManager.Instance.GetStringById("Currency_Coupon");
             base.Quality   = dataById.quality;
             base.Valid     = true;
         }
     }
 }
Esempio n. 4
0
    public static Texture getSkinTex(int skinId)
    {
        SysHeroSkinVo sysHeroSkinVo = BaseDataMgr.instance.GetDicByType <SysHeroSkinVo>()[skinId.ToString()] as SysHeroSkinVo;
        SysGameResVo  sysGameResVo  = BaseDataMgr.instance.GetDicByType <SysGameResVo>()[sysHeroSkinVo.Loading_icon] as SysGameResVo;
        string        path          = sysGameResVo.path;

        return(CachedRes.getTex(path));
    }
Esempio n. 5
0
 private void CreateBookItem(SysHeroSkinVo skinVo)
 {
     if (this.IsIllegalArgument(skinVo))
     {
         return;
     }
     this.SetQualityFrame(skinVo.quality);
     this.SetTexture(skinVo.avatar_icon, 140);
 }
Esempio n. 6
0
        public static string GetHeroSkinPath(string pathWithoutSkin, int skinId)
        {
            string result;

            if (skinId == 0)
            {
                result = pathWithoutSkin;
            }
            else
            {
                SysHeroSkinVo sysHeroSkinVo = BaseDataMgr.instance.GetDicByType <SysHeroSkinVo>()[skinId.ToString()] as SysHeroSkinVo;
                SysGameResVo  sysGameResVo  = BaseDataMgr.instance.GetDicByType <SysGameResVo>()[sysHeroSkinVo.model_id] as SysGameResVo;
                result = sysGameResVo.id;
            }
            return(result);
        }
Esempio n. 7
0
        public static void GetNewHeroSkin(this ModelManager mmng, int skinId)
        {
            SysHeroSkinVo dataById = BaseDataMgr.instance.GetDataById <SysHeroSkinVo>(skinId.ToString());

            if (dataById == null)
            {
                ClientLogger.Error("Skin Model: SkinId Illegal.");
                return;
            }
            SummSkinData item = new SummSkinData
            {
                SkinId = skinId,
                NpcId  = dataById.npc_id,
                SummId = 0L
            };

            mmng.GetSummSkinList().Add(item);
        }
Esempio n. 8
0
    private void RefreshUI_heroIcon()
    {
        ReadyPlayerSampleInfo memInfo      = this.MemInfo;
        SysHeroMainVo         heroMainData = BaseDataMgr.instance.GetHeroMainData(memInfo.GetHeroId());

        if (heroMainData == null)
        {
            ClientLogger.Error("找不到heroMain表信息,heroID=" + memInfo.GetHeroId());
            return;
        }
        string text = string.Empty;

        if (memInfo.heroSkinId != "0" && memInfo.heroSkinId != string.Empty)
        {
            Dictionary <string, object> dicByType = BaseDataMgr.instance.GetDicByType <SysHeroSkinVo>();
            if (dicByType != null && dicByType.ContainsKey(memInfo.heroSkinId))
            {
                SysHeroSkinVo sysHeroSkinVo = dicByType[memInfo.heroSkinId] as SysHeroSkinVo;
                if (sysHeroSkinVo != null)
                {
                    text = sysHeroSkinVo.avatar_icon;
                }
                else
                {
                    ClientLogger.Error("找不到SysHeroSkinVo表信息,skinID=" + memInfo.heroSkinId);
                }
            }
            else
            {
                ClientLogger.Error("找不到SysHeroSkinVo表信息2,skinID=" + memInfo.heroSkinId);
            }
        }
        else
        {
            text = heroMainData.avatar_icon;
        }
        if (!string.IsNullOrEmpty(text))
        {
            this.sp_heroIcon.mainTexture = ResourceManager.Load <Texture>(text, true, true, null, 0, false);
        }
    }
Esempio n. 9
0
    private bool SourceState(int skinid)
    {
        if (skinid == 0)
        {
            return(false);
        }
        if (this.IsPossess(skinid))
        {
            return(false);
        }
        SysHeroSkinVo dataById = BaseDataMgr.instance.GetDataById <SysHeroSkinVo>(skinid.ToString());

        if (dataById != null)
        {
            string[] array = dataById.source.Split(new char[]
            {
                '|'
            });
            return(0 > array.Length || array[0].CompareTo("1") != 0);
        }
        return(false);
    }
Esempio n. 10
0
        public static GameObject GetHeroPrefabWithSkin(string pathWithoutSkin, int skinId)
        {
            string resPath = string.Empty;

            if (skinId == 0)
            {
                resPath = pathWithoutSkin;
            }
            else
            {
                SysHeroSkinVo sysHeroSkinVo = BaseDataMgr.instance.GetDicByType <SysHeroSkinVo>()[skinId.ToString()] as SysHeroSkinVo;
                SysGameResVo  sysGameResVo  = BaseDataMgr.instance.GetDicByType <SysGameResVo>()[sysHeroSkinVo.model_id] as SysGameResVo;
                resPath = sysGameResVo.path;
            }
            GameObject unitAtResPath = CachedRes.getUnitAtResPath(resPath);

            if (unitAtResPath != null)
            {
                return(unitAtResPath);
            }
            return(CachedRes.getUnitAtResPath(pathWithoutSkin));
        }
Esempio n. 11
0
 public override void Init(string[] param)
 {
     base.Init(param);
     if (base.Valid)
     {
         base.Num = 1;
         string unikey = string.Empty;
         if (base.Discount)
         {
             SysCouponVo dataById = BaseDataMgr.instance.GetDataById <SysCouponVo>(param[2]);
             base.ExtraData = dataById;
             unikey         = dataById.mother_id;
         }
         else
         {
             unikey = param[2];
         }
         SysHeroSkinVo dataById2 = BaseDataMgr.instance.GetDataById <SysHeroSkinVo>(unikey);
         if (dataById2 != null)
         {
             base.SIcon = dataById2.avatar_icon;
             base.BIcon = dataById2.Loading_icon;
             if (base.Discount)
             {
                 base.TypeDes   = LanguageManager.Instance.GetStringById("Currency_Coupon");
                 base.ExtraData = BaseDataMgr.instance.GetDataById <SysCouponVo>(param[2]);
             }
             else
             {
                 base.TypeDes = LanguageManager.Instance.GetStringById("Currency_Skin");
                 base.Des     = LanguageManager.Instance.GetStringById(dataById2.name);
             }
             base.Quality = dataById2.quality;
             base.Valid   = true;
         }
     }
 }
Esempio n. 12
0
 private void OnMsg_sacriviewChangeHero(MobaMessage msg)
 {
     this.coroutine.StopAllCoroutine();
     if (msg.Param != null)
     {
         string modelID = string.Empty;
         modelID      = (string)msg.Param;
         this.heroNPC = modelID;
         HeroInfoData heroInfoData = ModelManager.Instance.Get_heroInfo_item_byModelID_X(modelID);
         this.skinID = ((heroInfoData != null) ? heroInfoData.CurrSkin : 0);
         if (null != this.smodel)
         {
             UnityEngine.Object.Destroy(this.smodel);
         }
         if (null != this.animator)
         {
             UnityEngine.Object.Destroy(this.animator);
         }
         if (this.skinID == 0)
         {
             SysHeroMainVo heroMainData = BaseDataMgr.instance.GetHeroMainData(this.heroNPC);
             if (heroMainData != null)
             {
                 this.task_loadModel = this.coroutine.StartCoroutine(this.LoadModel(heroMainData.smodel_id), true);
             }
         }
         else
         {
             SysHeroSkinVo dataById = BaseDataMgr.instance.GetDataById <SysHeroSkinVo>(this.skinID.ToString());
             if (dataById != null)
             {
                 this.task_loadModel = this.coroutine.StartCoroutine(this.LoadModel(dataById.smodel_id), true);
             }
         }
     }
 }
Esempio n. 13
0
    private void ShowRewardInfo(GameObject go, bool isOver)
    {
        this.RewardInfo.gameObject.SetActive(isOver);
        this.RewardInfo.transform.localPosition = new Vector3(go.transform.localPosition.x + 452f, go.transform.localPosition.y - 204f, 0f);
        this.RewardIcon.gameObject.SetActive(true);
        this.Icon.gameObject.SetActive(false);
        SysAttendanceRewardsVo dataById  = BaseDataMgr.instance.GetDataById <SysAttendanceRewardsVo>(go.name);
        SysDropRewardsVo       dataById2 = BaseDataMgr.instance.GetDataById <SysDropRewardsVo>(dataById.rewards.ToString());
        SysDropItemsVo         dataById3 = BaseDataMgr.instance.GetDataById <SysDropItemsVo>(dataById2.drop_items);

        string[] array = dataById3.rewards.Split(new char[]
        {
            '|'
        });
        string text = array[0];

        switch (text)
        {
        case "1":
        {
            SysCurrencyVo dataById4 = BaseDataMgr.instance.GetDataById <SysCurrencyVo>(array[1]);
            if (dataById4 != null)
            {
                this.RewardInfo.Find("Name").GetComponent <UILabel>().text     = LanguageManager.Instance.GetStringById(dataById4.name);
                this.RewardInfo.Find("Describe").GetComponent <UILabel>().text = LanguageManager.Instance.GetStringById(dataById4.description);
                this.RewardIcon.mainTexture = ResourceManager.Load <Texture>(dataById.loading_icon, true, true, null, 0, false);
            }
            break;
        }

        case "2":
        {
            SysGameItemsVo dataById5 = BaseDataMgr.instance.GetDataById <SysGameItemsVo>(array[1]);
            if (dataById5.type != 4 && dataById5.type != 10)
            {
                this.RewardIcon.mainTexture = ResourceManager.Load <Texture>(dataById.loading_icon, true, true, null, 0, false);
                this.RewardInfo.Find("Name").GetComponent <UILabel>().text     = LanguageManager.Instance.GetStringById(dataById5.name);
                this.RewardInfo.Find("Describe").GetComponent <UILabel>().text = LanguageManager.Instance.GetStringById(dataById5.describe);
            }
            else if (dataById5.type == 10)
            {
                this.RewardIcon.mainTexture = ResourceManager.Load <Texture>(dataById.loading_icon, true, true, null, 0, false);
                this.RewardInfo.Find("Name").GetComponent <UILabel>().text     = LanguageManager.Instance.GetStringById(dataById5.role);
                this.RewardInfo.Find("Describe").GetComponent <UILabel>().text = LanguageManager.Instance.GetStringById(dataById5.name);
            }
            else
            {
                this.RewardIcon.gameObject.SetActive(false);
                this.Icon.gameObject.SetActive(true);
                this.Icon.transform.Find("Sprite").GetComponent <UISprite>().spriteName = dataById5.icon;
                this.RewardInfo.Find("Name").GetComponent <UILabel>().text     = LanguageManager.Instance.GetStringById("Currency_Rune");
                this.RewardInfo.Find("Describe").GetComponent <UILabel>().text = LanguageManager.Instance.GetStringById(dataById5.name);
            }
            break;
        }

        case "3":
        {
            string text2 = array[1];
            switch (text2)
            {
            case "1":
            {
                Dictionary <string, SysHeroMainVo> typeDicByType = BaseDataMgr.instance.GetTypeDicByType <SysHeroMainVo>();
                foreach (string current in typeDicByType.Keys)
                {
                    if (typeDicByType[current].hero_id == int.Parse(array[2]))
                    {
                        SysHeroMainVo heroMainData = BaseDataMgr.instance.GetHeroMainData(current);
                        this.RewardInfo.Find("Describe").GetComponent <UILabel>().text = LanguageManager.Instance.GetStringById(heroMainData.name);
                    }
                }
                this.RewardInfo.Find("Name").GetComponent <UILabel>().text = LanguageManager.Instance.GetStringById("Currency_Hero");
                break;
            }

            case "2":
            {
                SysHeroSkinVo dataById6 = BaseDataMgr.instance.GetDataById <SysHeroSkinVo>(array[2]);
                this.RewardInfo.Find("Name").GetComponent <UILabel>().text     = LanguageManager.Instance.GetStringById("Currency_Skin");
                this.RewardInfo.Find("Describe").GetComponent <UILabel>().text = LanguageManager.Instance.GetStringById(dataById6.name);
                break;
            }

            case "3":
                this.RewardInfo.Find("Name").GetComponent <UILabel>().text     = LanguageManager.Instance.GetStringById("Currency_HeadPortrait");
                this.RewardInfo.Find("Describe").GetComponent <UILabel>().text = string.Empty;
                break;

            case "4":
                this.RewardInfo.Find("Name").GetComponent <UILabel>().text     = LanguageManager.Instance.GetStringById("Currency_PictureFrame");
                this.RewardInfo.Find("Describe").GetComponent <UILabel>().text = string.Empty;
                break;
            }
            this.RewardIcon.mainTexture = ResourceManager.Load <Texture>(dataById.loading_icon, true, true, null, 0, false);
            break;
        }

        case "4":
            this.RewardInfo.Find("Name").GetComponent <UILabel>().text = ((!(array[1] == "1")) ? "小魔瓶经验" : "召唤师经验");
            this.RewardIcon.mainTexture = ResourceManager.Load <Texture>(dataById.loading_icon, true, true, null, 0, false);
            this.RewardInfo.Find("Describe").GetComponent <UILabel>().text = string.Empty;
            break;
        }
    }
Esempio n. 14
0
 public void SetBuyBtnState(int skinId)
 {
     NGUITools.SetActive(this._buyBtn, !this.IsPossess(skinId));
     if (skinId != 0)
     {
         if (this.IsPossess(skinId))
         {
             this.source.gameObject.SetActive(false);
             return;
         }
         this.wearLabel.gameObject.SetActive(false);
         this.wear.gameObject.SetActive(false);
         SysHeroSkinVo dataById = BaseDataMgr.instance.GetDataById <SysHeroSkinVo>(skinId.ToString());
         string        text     = string.Empty;
         string[]      array    = dataById.source.Split(new char[]
         {
             '|'
         });
         if (0 <= array.Length && array[0].CompareTo("1") == 0)
         {
             this.source.gameObject.SetActive(false);
             return;
         }
         this.source.gameObject.SetActive(true);
         this._buyBtn.SetActive(false);
         if (array.Length > 1)
         {
             string text2 = array[0];
             if (text2 != null)
             {
                 if (SkinDrawer.< > f__switch$map33 == null)
                 {
                     SkinDrawer.< > f__switch$map33 = new Dictionary <string, int>(2)
                     {
                         {
                             "7",
                             0
                         },
                         {
                             "8",
                             1
                         }
                     };
                 }
                 int num;
                 if (SkinDrawer.< > f__switch$map33.TryGetValue(text2, out num))
                 {
                     if (num != 0)
                     {
                         if (num == 1)
                         {
                             text = LanguageManager.Instance.GetStringById(array[1]);
                             this.switchBth.gameObject.SetActive(false);
                             this.description.gameObject.SetActive(true);
                             this.description.text = text;
                         }
                     }
                     else
                     {
                         this.switchBth.gameObject.SetActive(true);
                         this.description.gameObject.SetActive(false);
                         text = LanguageManager.Instance.GetStringById("HeroSkinAltar_HeroSkinSource_" + array[0]);
                         this.content.text = text;
                         this.activityID   = int.Parse(array[1]);
                     }
                 }
             }
         }
         else
         {
             this.switchBth.gameObject.SetActive(true);
             this.description.gameObject.SetActive(false);
             text = LanguageManager.Instance.GetStringById("HeroSkinAltar_HeroSkinSource_" + dataById.source);
             this.content.text = text;
         }
         this.strSwitch = array[0];
     }
     else
     {
         this.source.gameObject.SetActive(false);
     }
 }
Esempio n. 15
0
        private void OnGetMsg_UserDataCode(OperationResponse operationResponse)
        {
            string arg  = operationResponse[10] as string;
            string arg2 = operationResponse[59] as string;

            byte[] buffer            = operationResponse[246] as byte[];
            List <DropItemData> list = SerializeHelper.Deserialize <List <DropItemData> >(buffer);

            if (list == null || list.Count < 1)
            {
                return;
            }
            foreach (DropItemData current in list)
            {
                Com.Game.Module.ItemType dropItemType = ToolsFacade.Instance.GetDropItemType(current);
                string text = ToolsFacade.Instance.GetDropItemTypeName(dropItemType);
                Com.Game.Module.ItemType itemType = dropItemType;
                if (itemType != Com.Game.Module.ItemType.HeroSkin)
                {
                    if (itemType == Com.Game.Module.ItemType.NormalGameItem)
                    {
                        SysGameItemsVo     dataById  = BaseDataMgr.instance.GetDataById <SysGameItemsVo>(current.itemId.ToString());
                        SysCustomizationVo dataById2 = BaseDataMgr.instance.GetDataById <SysCustomizationVo>(current.itemId.ToString());
                        if (dataById2 != null && dataById2.customization_type != 1 && dataById.quality < 5)
                        {
                            break;
                        }
                        string text2;
                        switch (dataById.quality)
                        {
                        case 3:
                            text2 = "[C138F9]史诗级";
                            break;

                        case 4:
                            text2 = "[ECC16F]传说级";
                            break;

                        case 5:
                            text2 = "[f81841]典藏级";
                            break;

                        default:
                            text2 = string.Empty;
                            break;
                        }
                        text = string.Concat(new string[]
                        {
                            text2,
                            text,
                            "【",
                            LanguageManager.Instance.GetStringById(dataById.name),
                            "】"
                        });
                    }
                }
                else
                {
                    SysHeroSkinVo dataById3 = BaseDataMgr.instance.GetDataById <SysHeroSkinVo>(current.itemCount.ToString());
                    text = string.Concat(new string[]
                    {
                        (dataById3.quality != 5) ? "[ECC16F]传说级" : "[f81841]典藏级",
                        text,
                        "【",
                        LanguageManager.Instance.GetStringById(dataById3.name),
                        "】"
                    });
                }
                this.data.otherMsgQueue.Enqueue(string.Format("天降鸿运!恭喜[e3905b]{0}[-]在{1}中获得{2}", arg2, arg, text));
            }
        }
Esempio n. 16
0
    public void setSkinInfo(SkinInfo skinInfo, bool isPossess, bool iswear = false)
    {
        if (!CharacterDataMgr.instance.OwenHeros.Contains(Singleton <PropertyView> .Instance.HeroNpc))
        {
            this._useLabel.text = this.strPlzPurchase;
            if (isPossess)
            {
                if (skinInfo.skinId != 0)
                {
                    this._useLabel.text = this.strOwned;
                }
                else
                {
                    this._useLabel.text = this.strPlzPurchase;
                }
            }
            else
            {
                this._useLabel.text = this.strNotOwned;
            }
        }
        else
        {
            this._useLabel.text = ((!isPossess) ? this.strNotOwned : this.strOwned);
        }
        this._useLabel.color = ((!(this._useLabel.text == this.strOwned)) ? Color.white : Color.green);
        float num = ((float)this._costLabel.width + (float)this._diamondSprite.width + 14f) / 2f;

        this._skinInfo          = skinInfo;
        this._uiTex.mainTexture = skinInfo.tex;
        if (skinInfo.IsWear || isPossess || iswear)
        {
            return;
        }
        if (skinInfo.skinId != 0)
        {
            SysHeroSkinVo dataById = BaseDataMgr.instance.GetDataById <SysHeroSkinVo>(skinInfo.skinId.ToString());
            string[]      array    = dataById.source.Split(new char[]
            {
                '|'
            });
            if (0 <= array.Length && array[0].CompareTo("1") != 0)
            {
                this.Single.gameObject.SetActive(false);
                this.Both.gameObject.SetActive(false);
                this.Discount.gameObject.SetActive(false);
                return;
            }
        }
        switch (skinInfo.Container)
        {
        case 1:
        {
            this.Single.gameObject.SetActive(true);
            this.Both.gameObject.SetActive(false);
            this.Discount.gameObject.SetActive(false);
            int num2 = skinInfo.CostType;
            if (num2 != 1)
            {
                if (num2 != 2)
                {
                    if (num2 == 9)
                    {
                        this.Single.GetChild(0).GetComponent <UISprite>().spriteName = "Home_page_icons_cap";
                        this.Single.GetChild(0).GetComponent <UISprite>().SetDimensions(40, 37);
                        this.Single.GetChild(1).GetComponent <UILabel>().text = skinInfo.CostBottle.ToString();
                    }
                }
                else
                {
                    this.Single.GetChild(0).GetComponent <UISprite>().spriteName = "icon_zuanshi";
                    this.Single.GetChild(0).GetComponent <UISprite>().SetDimensions(40, 37);
                    this.Single.GetChild(1).GetComponent <UILabel>().text = skinInfo.Cost.ToString();
                }
            }
            else
            {
                this.Single.GetChild(0).GetComponent <UISprite>().spriteName = "icon_gold";
                this.Single.GetChild(0).GetComponent <UISprite>().SetDimensions(35, 35);
                this.Single.GetChild(1).GetComponent <UILabel>().text = skinInfo.CostMoney.ToString();
            }
            break;
        }

        case 2:
        {
            this.Single.gameObject.SetActive(false);
            this.Both.gameObject.SetActive(true);
            this.Discount.gameObject.SetActive(false);
            int num2 = skinInfo.CostType;
            if (num2 != 1)
            {
                if (num2 != 2)
                {
                    if (num2 != 9)
                    {
                    }
                }
                else
                {
                    this.Both.GetChild(1).GetComponent <UILabel>().text = skinInfo.Cost.ToString();
                }
            }
            else
            {
                this.Both.GetChild(3).GetComponent <UILabel>().text = skinInfo.CostMoney.ToString();
            }
            num2 = skinInfo.CostTypeanother;
            if (num2 != 1)
            {
                if (num2 != 2)
                {
                    if (num2 != 9)
                    {
                    }
                }
                else
                {
                    this.Both.GetChild(1).GetComponent <UILabel>().text = skinInfo.Cost.ToString();
                }
            }
            else
            {
                this.Both.GetChild(3).GetComponent <UILabel>().text = skinInfo.CostMoney.ToString();
            }
            break;
        }

        case 3:
        {
            this.Single.gameObject.SetActive(false);
            this.Both.gameObject.SetActive(false);
            this.Discount.gameObject.SetActive(true);
            int num2 = skinInfo.CostType;
            if (num2 != 1)
            {
                if (num2 != 2)
                {
                    if (num2 == 9)
                    {
                        this.Discount.GetChild(2).GetComponent <UISprite>().spriteName = "Home_page_icons_cap";
                        this.Discount.GetChild(2).GetComponent <UISprite>().SetDimensions(40, 37);
                        this.Discount.GetChild(3).GetComponent <UILabel>().text = skinInfo.CostBottle.ToString();
                        this.Discount.GetChild(1).GetComponent <UILabel>().text = "原价" + skinInfo.CostBottle / skinInfo.Discount;
                    }
                }
                else
                {
                    this.Discount.GetChild(2).GetComponent <UISprite>().spriteName = "icon_zuanshi";
                    this.Discount.GetChild(2).GetComponent <UISprite>().SetDimensions(40, 37);
                    this.Discount.GetChild(3).GetComponent <UILabel>().text = skinInfo.Cost.ToString();
                    this.Discount.GetChild(1).GetComponent <UILabel>().text = "原价" + skinInfo.Cost / skinInfo.Discount;
                }
            }
            else
            {
                this.Discount.GetChild(2).GetComponent <UISprite>().spriteName = "icon_gold";
                this.Discount.GetChild(2).GetComponent <UISprite>().SetDimensions(35, 35);
                this.Discount.GetChild(3).GetComponent <UILabel>().text = skinInfo.CostMoney.ToString();
                this.Discount.GetChild(1).GetComponent <UILabel>().text = "原价" + skinInfo.CostMoney / skinInfo.Discount;
            }
            break;
        }
        }
    }