dev_chengFeng
parent
791af67033
commit
eddaa95312
File diff suppressed because it is too large
Load Diff
|
@ -418,7 +418,7 @@ PanelType = {
|
|||
Talisman = {14}, -- 新法宝
|
||||
Guild = {14, 16, 65}, -- 新法宝
|
||||
TimelimitCall={87,16}, --限时召唤
|
||||
QianKunBox={16,1002},--乾坤包囊
|
||||
QianKunBox={1002,1003,16},--乾坤包囊
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -1010,6 +1010,16 @@ function TimeToDHMS(second)
|
|||
local hour = math.floor(math.floor(second - day * 24 * 3600 - sec - minute * 60) / 3600)
|
||||
return string.format(Language[10548],day, hour, minute, sec)
|
||||
end
|
||||
|
||||
--- 将一段时间转换为天时
|
||||
function TimeToDH(second)
|
||||
local day = math.floor(second / (24 * 3600))
|
||||
local minute = math.floor(second / 60) % 60
|
||||
local sec = second % 60
|
||||
local hour = math.floor(math.floor(second - day * 24 * 3600 - sec - minute * 60) / 3600)
|
||||
return string.format("%d天%02d时",day, hour)
|
||||
end
|
||||
|
||||
--- 将一段时间转换为时分秒
|
||||
function TimeToHMS(t)
|
||||
if not t or t < 0 then
|
||||
|
|
|
@ -651,7 +651,7 @@ function this.GetTableByBackDropData(drop)
|
|||
-- TalismanManager.InitUpdateSingleTalismanData(itemdata.backData)
|
||||
-- end
|
||||
-- end
|
||||
LogBlue("drop.soulEquip:"..#drop.soulEquip)
|
||||
-- LogBlue("drop.soulEquip:"..#drop.soulEquip)
|
||||
if drop.soulEquip ~= nil and #drop.soulEquip > 0 then
|
||||
Log("drop.especialEquipId " .. #drop.soulEquip)
|
||||
for i = 1, #drop.soulEquip do
|
||||
|
|
|
@ -203,7 +203,7 @@ function OperatingPanel:ShowTabContent(index)
|
|||
return
|
||||
elseif index == 11 then
|
||||
self.operatingContents[curContent]:OnShow(self.sortingOrder)
|
||||
self.UpView:OnOpen({ showType = UpViewOpenType.ShowLeft, panelType = PanelType.QianKunBox })--货币待修改
|
||||
self.UpView:OnOpen({ showType = UpViewOpenType.ShowLeft, panelType = PanelType.QianKunBox })
|
||||
return
|
||||
end
|
||||
|
||||
|
|
|
@ -7,6 +7,7 @@ local artConfig = ConfigManager.GetConfig(ConfigName.ArtResourcesConfig)
|
|||
local lotterySetting=ConfigManager.GetConfig(ConfigName.LotterySetting)
|
||||
local privilegeConfig=ConfigManager.GetConfig(ConfigName.PrivilegeTypeConfig)
|
||||
local artResourcesConfig =ConfigManager.GetConfig(ConfigName.ArtResourcesConfig)
|
||||
local lotterySpecialConfig = ConfigManager.GetConfig(ConfigName.LotterySpecialConfig)
|
||||
local orginLayer = 0
|
||||
|
||||
local bType={
|
||||
|
@ -29,10 +30,10 @@ function QianKunBox:InitComponent(gameObject)
|
|||
self.tabList = Util.GetGameObject(self.mainPanel,"bg/tabList")
|
||||
self.btnBack = Util.GetGameObject(self.mainPanel,"bg/btnBack")
|
||||
self.bottomBar = Util.GetGameObject(self.mainPanel,"bg/bottomBar")
|
||||
--leftUp
|
||||
self.leftUp = Util.GetGameObject(gameObject,"leftUp")
|
||||
self.leftUptips1 = Util.GetGameObject(self.leftUp,"tips/tips1"):GetComponent("Text")
|
||||
self.leftUpTime = Util.GetGameObject(self.leftUp,"tips/tips2/time"):GetComponent("Text")
|
||||
--midDown
|
||||
self.midDown = Util.GetGameObject(gameObject,"midDown")
|
||||
self.leftUptips1 = Util.GetGameObject(self.midDown,"tips/tips1/times"):GetComponent("Text")
|
||||
self.leftUpTime = Util.GetGameObject(self.midDown,"tips/tips2/time"):GetComponent("Text")
|
||||
self.btnHelp= Util.GetGameObject(gameObject,"btnHelp")
|
||||
self.helpPosition=self.btnHelp:GetComponent("RectTransform").localPosition
|
||||
--rightUp
|
||||
|
@ -50,7 +51,8 @@ function QianKunBox:InitComponent(gameObject)
|
|||
self.btnTen1 = Util.GetGameObject(self.bottom,"btnTen1")
|
||||
self.btnTen2 = Util.GetGameObject(self.bottom,"btnTen2")
|
||||
self.btnTimes= Util.GetGameObject(self.bottom,"countDown/di2/time"):GetComponent("Text")
|
||||
self.limit = Util.GetGameObject(self.bottom,"limit"):GetComponent("Text")
|
||||
--limit
|
||||
self.limit = Util.GetGameObject(gameObject,"limitdi/limit"):GetComponent("Text")
|
||||
--detail
|
||||
self.detail = Util.GetGameObject(gameObject,"detail")
|
||||
--shop
|
||||
|
@ -65,9 +67,10 @@ function QianKunBox:BindEvent()
|
|||
UIManager.OpenPanel(UIName.HelpPopup,HELP_TYPE.QianKunBox,self.helpPosition.x,self.helpPosition.y)
|
||||
end)
|
||||
Util.AddClick(self.btnReward,function()
|
||||
ActivityDetail.new(self.detail,2)
|
||||
ActivityDetail.new(self.detail,2)
|
||||
end)
|
||||
Util.AddClick(self.btnStore,function()
|
||||
-- Game.GlobalEvent:DispatchEvent(GameEvent.Player.OnCurrencyChange,PanelType.QianKunStore)
|
||||
self.shop:SetActive(true)
|
||||
self.btnBack:SetActive(false)
|
||||
self.tabList:SetActive(false)
|
||||
|
@ -130,7 +133,7 @@ function QianKunBox:refreshBtnShow()
|
|||
d=RecruitManager.GetExpendData(m.type)
|
||||
itemId=d[1]
|
||||
itemNum=d[2]
|
||||
LogPink("itemId:"..itemId.." itemNum:"..itemNum)
|
||||
-- LogPink("itemId:"..itemId.." itemNum:"..itemNum)
|
||||
icon.sprite=Util.LoadSprite(artResourcesConfig[itemConfig[itemId].ResourceID].Name)
|
||||
info.text=m.isInfo
|
||||
num.text= tostring(itemNum)
|
||||
|
@ -201,7 +204,7 @@ function QianKunBox:timeCountDown()
|
|||
self.shopData = ShopManager.GetShopDataByType(SHOP_TYPE.QIANKUNBOX_SHOP)--获取活动信息
|
||||
self.leftUpTime.text = TimeToDHMS(self.shopData.endTime - GetTimeStamp())--活动结束的倒计时
|
||||
self.timer = Timer.New(function()
|
||||
self.leftUpTime.text = TimeToDHMS(self.shopData.endTime - GetTimeStamp())
|
||||
self.leftUpTime.text = TimeToDH(self.shopData.endTime - GetTimeStamp())
|
||||
self.btnTime.text = TimeToHMS(timeDown)
|
||||
timeDown = timeDown -1
|
||||
end, 1, -1, true)
|
||||
|
@ -211,9 +214,9 @@ end
|
|||
|
||||
function QianKunBox:refreshMagicNum()
|
||||
local actData = ActivityGiftManager.GetActivityTypeInfo(ActivityTypeDef.QianKunBox)
|
||||
LogYellow("ID:"..actData.activityId.." value"..actData.value)
|
||||
self.leftUptips1.text = 100-math.floor(actData.value/1000)..Language[12226]
|
||||
self.btnTimes.text = 30-actData.value%1000
|
||||
-- LogYellow("ID:"..actData.activityId.." value"..actData.value)
|
||||
self.leftUptips1.text = lotterySpecialConfig[20].Count-math.floor(actData.value/1000)
|
||||
self.btnTimes.text = tostring(lotterySpecialConfig[21].Count-actData.value%1000).."次内必得金色魂印"
|
||||
end
|
||||
|
||||
function QianKunBox:OnSortingOrderChange(_sortingOrder)
|
||||
|
|
Loading…
Reference in New Issue