数字小游戏挂机修改

tcx_xiyou_dev
PC-202302260912\Administrator 2024-05-11 17:21:35 +08:00
parent 8d8906b93a
commit 5600588ecc
2 changed files with 16 additions and 7 deletions

View File

@ -75,12 +75,12 @@ function RatioNumberLevelPanel:BindEvent()
Util.AddClick(this.btn_reward, function ()
if RatioNumberManager.gameIndex==0 then
if RatioNumberManager.gameIndex==1 then
PopupTipPanel.ShowTip("至少通关一层才可领取挂机奖励")
return
end
LogError("GetTimeStamp()=="..GetTimeStamp().." showTime=="..RatioNumberManager.rewardStartTime)
if GetTimeStamp()-RatioNumberManager.rewardStartTime<360 then
if GetTimeStamp()- RatioNumberManager.rewardStartTime < 360 then
PopupTipPanel.ShowTip("累计挂机奖励中")
return
end
@ -206,12 +206,15 @@ function this.GetBoxShowState(hangupTime)
local state = 0
local curTime=GetTimeStamp()
LogError("curTime=========="..curTime.." hangupTime== "..hangupTime)
local addTime=curTime-hangupTime
if addTime>maxTime then
hangupTime=maxTime
else
hangupTime=addTime
if hangupTime>0 then
local addTime=curTime-hangupTime
if addTime>maxTime then
hangupTime=maxTime
else
hangupTime=addTime
end
end
LogError("hangupTime==========================="..hangupTime)
if hangupTime < AdventureManager.adventureRefresh then
state = 0

View File

@ -46,8 +46,14 @@ function RatioNumberManager.Init(msg)
this.chapterId =this.chapterId + 1
end
this.rewardIdArr = msg.rewardIdArr
LogError("this.gameindex====================================="..this.gameIndex)
if msg.rewardStartTime then
this.rewardStartTime = msg.rewardStartTime
else
if this.rewardStartTime==0 then
this.rewardStartTime=GetTimeStamp()
end
LogError("this.rewardStartTime======================================================"..this.rewardStartTime)
end
RatioNumberManager.SelectInit()