Merge branch 'china/dev' of http://60.1.1.230/gaoxin/JL_Client into china/dev

dev_chengFeng
jiaoyangna 2021-03-30 22:59:05 +08:00
commit f30b4ea7eb
4 changed files with 49 additions and 30 deletions

View File

@ -223,13 +223,15 @@ function this.PatFaceSpecialMonitor(v,patFaceAllData,type,starUpGiftNum)
table.insert(patFaceAllData,v) table.insert(patFaceAllData,v)
end end
end end
-- elseif v.Type == 12 then--福星高照活动 elseif v.Type == 12 then--福星高照活动
-- local ActData = ActivityGiftManager.GetActivityTypeInfo(ActivityTypeDef.FuXingGaoZhao) local ActData = ActivityGiftManager.GetActivityTypeInfo(ActivityTypeDef.FuXingGaoZhao)
-- if ActData then local data = string.split(ConfigManager.GetConfigDataByKey(ConfigName.SpecialConfig,"Id",109).Value,"#")
-- if RedPointManager.PlayerPrefsGetStr(v.Id..PlayerManager.level.."TimeLimitSkin") == "0" then local time = ActData.startTime + tonumber(data[1])*86400 - GetTimeStamp()
-- table.insert(patFaceAllData,v) if time >0 then
-- end if RedPointManager.PlayerPrefsGetStr(v.Id.."PatFace") == "0" then
-- end table.insert(patFaceAllData,v)
end
end
else else
if RedPointManager.PlayerPrefsGetStr(v.Id.."PatFace") == "0" then if RedPointManager.PlayerPrefsGetStr(v.Id.."PatFace") == "0" then
table.insert(patFaceAllData,v) table.insert(patFaceAllData,v)

View File

@ -117,7 +117,7 @@ function FuXingGaoZhao:SetTime()
self.timer = nil self.timer = nil
end end
local time = data.startTime + tonumber(timeData[1])*86400 - GetTimeStamp() local time = data.startTime + tonumber(timeData[1])*86400 - GetTimeStamp()
self.time.text = string.format("剩余接受时间:%s",TimeToFelaxible(time)) self.time.text = string.format("剩余结束时间:%s",TimeToFelaxible(time))
self.timer = Timer.New(function() self.timer = Timer.New(function()
time = time - 1 time = time - 1
if time < 1 then if time < 1 then
@ -125,7 +125,7 @@ function FuXingGaoZhao:SetTime()
self.timer = nil self.timer = nil
self:ClosePanel() self:ClosePanel()
end end
self.time.text = string.format("剩余接受时间:%s",TimeToFelaxible(time)) self.time.text = string.format("剩余结束时间:%s",TimeToFelaxible(time))
end, 1, -1, true) end, 1, -1, true)
self.timer:Start() self.timer:Start()
end end

View File

@ -1000,6 +1000,9 @@ function this.TimeFormat()
local data = string.split(ConfigManager.GetConfigDataByKey(ConfigName.SpecialConfig,"Id",109).Value,"#") local data = string.split(ConfigManager.GetConfigDataByKey(ConfigName.SpecialConfig,"Id",109).Value,"#")
local time = ActData.startTime + tonumber(data[1])*86400 - GetTimeStamp() local time = ActData.startTime + tonumber(data[1])*86400 - GetTimeStamp()
activityTabs[k].timeText.text = TimeToFelaxible(time) activityTabs[k].timeText.text = TimeToFelaxible(time)
if time <= 0 then
activityTabs[k].go.gameObject:SetActive(false)
end
end end
else else
activityTabs[k].go.gameObject:SetActive(false) activityTabs[k].go.gameObject:SetActive(false)

View File

@ -251,7 +251,8 @@ function this.MoveTT(targetIndex,_data)
this.MapMove(allGridData[curGridIndex].x,0.3) this.MapMove(allGridData[curGridIndex].x,0.3)
if curGridIndex==targetIndex then if curGridIndex==targetIndex then
Log("待机动画") Log("待机动画")
this.SkeletonGraphic.AnimationState:SetAnimation(0, "idle", true) -- this.SkeletonGraphic.AnimationState:SetAnimation(0, "idle", true)
this.liveNode:SetWalkDir(WALK_DIR.IDLE_FRONT)
this.startBtn:GetComponent("Button").enabled=true this.startBtn:GetComponent("Button").enabled=true
this.EventTrigger(_data) this.EventTrigger(_data)
if curGridIndex>=#allGridData then if curGridIndex>=#allGridData then
@ -443,40 +444,50 @@ local npc
local scale local scale
---加载跑图角色 ---加载跑图角色
function this.LoadTT() function this.LoadTT()
local mapNpc = "live2d_npc_map" -- local mapNpc = "live2d_npc_map"
local mapNpc2 = "live2d_npc_map_nv" -- local mapNpc2 = "live2d_npc_map_nv"
npc = NameManager.roleSex == ROLE_SEX.BOY and mapNpc or mapNpc2 -- npc = NameManager.roleSex == ROLE_SEX.BOY and mapNpc or mapNpc2
scale = NameManager.roleSex == ROLE_SEX.BOY and Vector3.one * 0.25 or Vector3.one * 0.12 -- scale = NameManager.roleSex == ROLE_SEX.BOY and Vector3.one * 0.25 or Vector3.one * 0.12
if not this.liveNode then -- if not this.liveNode then
this.liveNode = poolManager:LoadLive(npc, this.TT.transform, scale, Vector3.New(0,-42.4,0)) -- this.liveNode = poolManager:LoadLive(npc, this.TT.transform, scale, Vector3.New(0,-42.4,0))
end -- end
this.SkeletonGraphic = this.liveNode:GetComponent("SkeletonGraphic") -- this.SkeletonGraphic = this.liveNode:GetComponent("SkeletonGraphic")
if this.SkeletonGraphic then -- if this.SkeletonGraphic then
this.SkeletonGraphic.AnimationState:SetAnimation(0, "idle", true) -- this.SkeletonGraphic.AnimationState:SetAnimation(0, "idle", true)
-- end
if this.liveNode then
this.liveNode:OnClose()
end end
this.liveNode = PlayerLiveView:New(this.TT,1)
this.liveNode:OnOpen(GetPlayerRoleSingleConFig().Scale7,Vector3.New(0,0,0),WALK_DIR.IDLE_FRONT)
end end
--设置跑图角色方向 --设置跑图角色方向
function this.SetTTDirection() function this.SetTTDirection()
if not this.SkeletonGraphic then if not this.liveNode then
return return
end end
local nexIndex=curGridIndex+1 local nexIndex=curGridIndex+1
if nexIndex>#allGridData then if nexIndex>#allGridData then
this.SkeletonGraphic.AnimationState:SetAnimation(0, "touch", true) -- this.SkeletonGraphic.AnimationState:SetAnimation(0, "touch", true)
this.liveNode:SetWalkDir(WALK_DIR.TOUCH)
return return
end end
if allGridData[curGridIndex].y==allGridData[nexIndex].y then if allGridData[curGridIndex].y==allGridData[nexIndex].y then
this.SkeletonGraphic.AnimationState:SetAnimation(0, "move2", true) -- this.SkeletonGraphic.AnimationState:SetAnimation(0, "move2", true)
if allGridData[curGridIndex].x<allGridData[nexIndex].x then if allGridData[curGridIndex].x<allGridData[nexIndex].x then
this.SkeletonGraphic.transform.localEulerAngles = Vector3.New(0, 0, 0) -- this.SkeletonGraphic.transform.localEulerAngles = Vector3.New(0, 0, 0)
this.liveNode:SetWalkDir(WALK_DIR.RUN_RIGHT)
else else
this.SkeletonGraphic.transform.localEulerAngles = Vector3.New(0, 180, 0) -- this.SkeletonGraphic.transform.localEulerAngles = Vector3.New(0, 180, 0)
this.liveNode:SetWalkDir(WALK_DIR.RUN_LEFT)
end end
elseif allGridData[curGridIndex].x==allGridData[nexIndex].x then elseif allGridData[curGridIndex].x==allGridData[nexIndex].x then
if allGridData[curGridIndex].y<allGridData[nexIndex].y then if allGridData[curGridIndex].y<allGridData[nexIndex].y then
this.SkeletonGraphic.AnimationState:SetAnimation(0, "move3", true) -- this.SkeletonGraphic.AnimationState:SetAnimation(0, "move3", true)
this.liveNode:SetWalkDir(WALK_DIR.RUN_UP)
else else
this.SkeletonGraphic.AnimationState:SetAnimation(0, "move", true) -- this.SkeletonGraphic.AnimationState:SetAnimation(0, "move", true)
this.liveNode:SetWalkDir(WALK_DIR.RUN_DOWN)
end end
end end
end end
@ -649,10 +660,13 @@ function this:OnClose()
this.shopBtn:SetActive(false) this.shopBtn:SetActive(false)
this.StopAuto() this.StopAuto()
isPlayMove=1 isPlayMove=1
-- if this.liveNode then
-- poolManager:UnLoadLive(npc, this.liveNode)
-- this.liveNode = nil
-- end
if this.liveNode then if this.liveNode then
poolManager:UnLoadLive(npc, this.liveNode) this.liveNode:OnClose()
this.liveNode = nil end
end
if this.timer then if this.timer then
this.timer:Stop() this.timer:Stop()
this.timer = nil this.timer = nil