神将来源跳转星辰商店修改提交
parent
0d7eacc772
commit
410a0cac4f
|
@ -97,7 +97,7 @@ Material:
|
|||
- _ZWrite: 1
|
||||
m_Colors:
|
||||
- _Center: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _Color: {r: 0, g: 85.445015, b: 2.4686809, a: 1}
|
||||
- _Color: {r: 68.87595, g: 41.56343, b: 0.32488734, a: 1}
|
||||
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _Grain_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
- _Main_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
|
|
|
@ -110,7 +110,7 @@ function JumpViewNew:OnOpen(jumpId,heroConfig,parent)
|
|||
self.desc.text = string.format("<color=#%s>%s:%s/%s</color>",color, ItemConfig[costItemId].Name,itemcount,needCostNum)
|
||||
elseif self.jumpSData.Type == JumpType.XingChenShangDian then
|
||||
local storeTypeConfig = ConfigManager.GetConfigDataByKey(ConfigName.StoreTypeConfig,"StoreType",70)
|
||||
self.shopType = storeTypeConfig.Id
|
||||
self.shopType = 70
|
||||
local configs = ConfigManager.GetAllConfigsDataByKey(ConfigName.StoreConfig,"StoreId",storeTypeConfig.Id)
|
||||
local getChipNum = 1
|
||||
local costItemId = 0
|
||||
|
@ -191,6 +191,8 @@ function JumpViewNew:GoToJumpData()
|
|||
else
|
||||
if self.jumpSData.Type == JumpType.Store then
|
||||
ShopManager.SetSelectIndex(self.jumpSData.Skipfactor[1],{self.ShopId})
|
||||
elseif self.jumpSData.Type == JumpType.XingChenShangDian then
|
||||
ShopManager.SetSelectIndex(self.shopType,{self.ShopId})
|
||||
end
|
||||
JumpManager.GoJump(self.jumpSData.Id,function()
|
||||
self.parent:ClosePanel()
|
||||
|
|
|
@ -414,10 +414,6 @@ end
|
|||
-- 妖晶商店物品数据匹配
|
||||
function ShopViewNew:RechargeShopItemAdapter(shopItem, itemData)
|
||||
-- 获取对象
|
||||
local effect = Util.GetGameObject(shopItem, "Fx_SquareFlow")
|
||||
effect.gameObject:SetActive(false)
|
||||
Util.SetParticleSortLayer(effect, this.sortingOrder + 1)
|
||||
-- 获取对象
|
||||
local first = Util.GetGameObject(shopItem, "first")
|
||||
local firstNum = Util.GetGameObject(shopItem, "first/Text"):GetComponent("Text")
|
||||
local icon = Util.GetGameObject(shopItem, "icon"):GetComponent("Image")
|
||||
|
@ -434,18 +430,6 @@ function ShopViewNew:RechargeShopItemAdapter(shopItem, itemData)
|
|||
local curBuyCount = itemData.buyTimes
|
||||
first:SetActive(curBuyCount < 1)
|
||||
firstNum.text = itemInfo.FirstMultiple[1][2]
|
||||
local isshow = false
|
||||
if self.ShopType == ShopManager.selectIndex2.shopType then
|
||||
for j = 1 , #ShopManager.selectIndex2.storeId do
|
||||
if itemData.id == ShopManager.selectIndex2.storeId[j] then
|
||||
isshow = true
|
||||
break
|
||||
end
|
||||
end
|
||||
end
|
||||
if isshow then
|
||||
effect.gameObject:SetActive(true)
|
||||
end
|
||||
-- 购买事件
|
||||
Util.AddOnceClick(shopItem, function()
|
||||
PayManager.Pay(itemData.goodsId, function(id)
|
||||
|
@ -457,6 +441,10 @@ end
|
|||
-- 商店物品数据匹配
|
||||
function ShopViewNew:ShopItemAdapter(shopItem, itemData)
|
||||
-- 获取对象
|
||||
local effect = Util.GetGameObject(shopItem, "Fx_SquareFlow")
|
||||
effect.gameObject:SetActive(false)
|
||||
Util.SetParticleSortLayer(effect, sortingOrder + 1)
|
||||
-- 获取对象
|
||||
local bg = Util.GetGameObject(shopItem, "bg")
|
||||
local item = Util.GetGameObject(bg, "item")
|
||||
local itemName = Util.GetGameObject(bg, "itemName"):GetComponent("Text")
|
||||
|
@ -531,7 +519,7 @@ function ShopViewNew:ShopItemAdapter(shopItem, itemData)
|
|||
if isEmpty or not _IsUnLock then -- 物品空或者未解锁不现实物品特效
|
||||
self._GoodsItemList[shopItem]:OnOpen(false, goods[1],1,false,false,false)
|
||||
else
|
||||
self._GoodsItemList[shopItem]:OnOpen(false, goods[1],1,false,false,false,ShopViewNew.sortingOrder)
|
||||
self._GoodsItemList[shopItem]:OnOpen(false, goods[1],1,false,false,false,sortingOrder)
|
||||
end
|
||||
|
||||
-- 商品颜色显示
|
||||
|
@ -543,6 +531,19 @@ function ShopViewNew:ShopItemAdapter(shopItem, itemData)
|
|||
self:SetAlpha(limitTimes, textA)
|
||||
self:SetAlpha(itemPrice, textA)
|
||||
|
||||
local isshow = false
|
||||
if self.ShopType == ShopManager.selectIndex2.shopType then
|
||||
for j = 1 , #ShopManager.selectIndex2.storeId do
|
||||
if itemData.id == ShopManager.selectIndex2.storeId[j] then
|
||||
isshow = true
|
||||
break
|
||||
end
|
||||
end
|
||||
end
|
||||
if isshow then
|
||||
effect.gameObject:SetActive(true)
|
||||
end
|
||||
|
||||
-- 购买事件
|
||||
Util.AddOnceClick(lock, function()
|
||||
PopupTipPanel.ShowTip("商品未解锁")
|
||||
|
@ -661,7 +662,7 @@ function ShopViewNew:SetSortLayer(sortLayer)
|
|||
-- self.titleBg:GetComponent("Canvas").sortingOrder = sortLayer + 1
|
||||
|
||||
-- 保存层级
|
||||
ShopViewNew.sortingOrder = sortLayer
|
||||
sortingOrder = sortLayer
|
||||
end
|
||||
|
||||
return ShopViewNew
|
Loading…
Reference in New Issue