|
@@ -103,35 +103,35 @@ namespace GFGGame
|
|
ItemCfg itemCfg = ItemCfgArray.Instance.GetCfg(itemdata.id);
|
|
ItemCfg itemCfg = ItemCfgArray.Instance.GetCfg(itemdata.id);
|
|
string resPath = "";
|
|
string resPath = "";
|
|
string resPath1 = "";
|
|
string resPath1 = "";
|
|
- // switch (itemCfg.rarity)
|
|
|
|
- // {
|
|
|
|
- // case ConstDressRarity.Rarity_TIANYI:
|
|
|
|
- // resPath = ResPathUtil.GetViewEffectPath("ui_LuckyBox", "CK_Yellow_01");
|
|
|
|
- // SceneController.AddObjectToView(gameObject1, wrapper1, _ui.m_comCard.m_holder, resPath, out gameObject1, out wrapper1);
|
|
|
|
- // _ui.m_comCard.m_holder.visible = true;
|
|
|
|
- // resPath1 = ResPathUtil.GetViewEffectPath("ui_LuckyBox", "CK_Yellow_01_top");
|
|
|
|
- // SceneController.AddObjectToView(gameObject2, wrapper2, _ui.m_comCard.m_holder1, resPath1, out gameObject2, out wrapper2);
|
|
|
|
- // _ui.m_comCard.m_holder1.visible = true;
|
|
|
|
- // break;
|
|
|
|
- // case ConstDressRarity.Rarity_DIANCANG:
|
|
|
|
- // resPath = ResPathUtil.GetViewEffectPath("ui_LuckyBox", "CK_Purple_02");
|
|
|
|
- // SceneController.AddObjectToView(gameObject1, wrapper1, _ui.m_comCard.m_holder, resPath, out gameObject1, out wrapper1);
|
|
|
|
- // _ui.m_comCard.m_holder.visible = true;
|
|
|
|
- // resPath1 = ResPathUtil.GetViewEffectPath("ui_LuckyBox", "CK_Purple_02_top");
|
|
|
|
- // SceneController.AddObjectToView(gameObject2, wrapper2, _ui.m_comCard.m_holder1, resPath1, out gameObject2, out wrapper2);
|
|
|
|
- // _ui.m_comCard.m_holder1.visible = true;
|
|
|
|
- // break;
|
|
|
|
- // case ConstDressRarity.Rarity_ZHENXI:
|
|
|
|
- // resPath = ResPathUtil.GetViewEffectPath("ui_LuckyBox", "CK_Bule_03");
|
|
|
|
- // SceneController.AddObjectToView(gameObject1, wrapper1, _ui.m_comCard.m_holder, resPath, out gameObject1, out wrapper1);
|
|
|
|
- // _ui.m_comCard.m_holder.visible = true;
|
|
|
|
- // break;
|
|
|
|
- // case ConstDressRarity.Rarity_FANPIN:
|
|
|
|
- // resPath = ResPathUtil.GetViewEffectPath("ui_LuckyBox", "CK_grey_04");
|
|
|
|
- // SceneController.AddObjectToView(gameObject1, wrapper1, _ui.m_comCard.m_holder, resPath, out gameObject1, out wrapper1);
|
|
|
|
- // _ui.m_comCard.m_holder.visible = true;
|
|
|
|
- // break;
|
|
|
|
- // }
|
|
|
|
|
|
+ switch (itemCfg.rarity)
|
|
|
|
+ {
|
|
|
|
+ case ConstDressRarity.Rarity_TIANYI:
|
|
|
|
+ resPath = ResPathUtil.GetViewEffectPath("ui_LuckyBox", "CK_Yellow_01");
|
|
|
|
+ SceneController.AddObjectToView(gameObject1, wrapper1, _ui.m_comCard.m_holder, resPath, out gameObject1, out wrapper1);
|
|
|
|
+ _ui.m_comCard.m_holder.visible = true;
|
|
|
|
+ resPath1 = ResPathUtil.GetViewEffectPath("ui_LuckyBox", "CK_Yellow_01_top");
|
|
|
|
+ SceneController.AddObjectToView(gameObject2, wrapper2, _ui.m_comCard.m_holder1, resPath1, out gameObject2, out wrapper2);
|
|
|
|
+ _ui.m_comCard.m_holder1.visible = true;
|
|
|
|
+ break;
|
|
|
|
+ case ConstDressRarity.Rarity_DIANCANG:
|
|
|
|
+ resPath = ResPathUtil.GetViewEffectPath("ui_LuckyBox", "CK_Purple_02");
|
|
|
|
+ SceneController.AddObjectToView(gameObject1, wrapper1, _ui.m_comCard.m_holder, resPath, out gameObject1, out wrapper1);
|
|
|
|
+ _ui.m_comCard.m_holder.visible = true;
|
|
|
|
+ resPath1 = ResPathUtil.GetViewEffectPath("ui_LuckyBox", "CK_Purple_02_top");
|
|
|
|
+ SceneController.AddObjectToView(gameObject2, wrapper2, _ui.m_comCard.m_holder1, resPath1, out gameObject2, out wrapper2);
|
|
|
|
+ _ui.m_comCard.m_holder1.visible = true;
|
|
|
|
+ break;
|
|
|
|
+ case ConstDressRarity.Rarity_ZHENXI:
|
|
|
|
+ resPath = ResPathUtil.GetViewEffectPath("ui_LuckyBox", "CK_Bule_03");
|
|
|
|
+ SceneController.AddObjectToView(gameObject1, wrapper1, _ui.m_comCard.m_holder, resPath, out gameObject1, out wrapper1);
|
|
|
|
+ _ui.m_comCard.m_holder.visible = true;
|
|
|
|
+ break;
|
|
|
|
+ case ConstDressRarity.Rarity_FANPIN:
|
|
|
|
+ resPath = ResPathUtil.GetViewEffectPath("ui_LuckyBox", "CK_grey_04");
|
|
|
|
+ SceneController.AddObjectToView(gameObject1, wrapper1, _ui.m_comCard.m_holder, resPath, out gameObject1, out wrapper1);
|
|
|
|
+ _ui.m_comCard.m_holder.visible = true;
|
|
|
|
+ break;
|
|
|
|
+ }
|
|
|
|
|
|
_ui.m_comCard.m_loaType.url = ResPathUtil.GetCommonGameResPath("hd_sxicon_" + itemCfg.rarity);
|
|
_ui.m_comCard.m_loaType.url = ResPathUtil.GetCommonGameResPath("hd_sxicon_" + itemCfg.rarity);
|
|
_ui.m_comCard.m_loaIcon.url = ResPathUtil.GetIconPath(itemCfg);
|
|
_ui.m_comCard.m_loaIcon.url = ResPathUtil.GetIconPath(itemCfg);
|