From bac91deb69627c03343a679b517ad58baadc8908 Mon Sep 17 00:00:00 2001 From: zhangqiang <657634622@qq.com> Date: Mon, 31 Aug 2020 17:02:58 +0800 Subject: [PATCH] =?UTF-8?q?=E5=85=AC=E4=BC=9A=E5=89=AF=E6=9C=AC=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0=E8=BE=B9=E7=95=8C=E5=88=A4=E6=96=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Transcript/GuildTranscriptManager.lua | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/Assets/ManagedResources/~Lua/Modules/Guild/Transcript/GuildTranscriptManager.lua b/Assets/ManagedResources/~Lua/Modules/Guild/Transcript/GuildTranscriptManager.lua index dbbaeab789..c3c72b676f 100644 --- a/Assets/ManagedResources/~Lua/Modules/Guild/Transcript/GuildTranscriptManager.lua +++ b/Assets/ManagedResources/~Lua/Modules/Guild/Transcript/GuildTranscriptManager.lua @@ -14,9 +14,14 @@ this.damage = 0 this.drop = nil--当场战斗掉落 this.shopGoodId = 10031--公会副本挑战价格 local refreshedBoss = {} + +local endBossId = 0 function this.Initialize() for _, configInfo in ConfigPairs(guildCheckpointConfig) do table.insert(allChapterConfigData,configInfo) + if configInfo.Id > endBossId then + endBossId = configInfo.Id + end end end function this.GetAllConFigData() @@ -40,7 +45,7 @@ function this.GetGuildChallengeInfoRequest(fun) PrivilegeManager.RefreshStarPrivilege(PRIVILEGE_TYPE.GUILDTRANSCRIPT_BATTLENUM) PrivilegeManager.RefreshStarPrivilege(PRIVILEGE_TYPE.GUILDTRANSCRIPT_BUY_BATTLENUM) end - -- LogPink("curBoss "..curBoss.." blood "..blood.." canSweep "..canSweep.." buffCount "..buffCount.." buffTime "..buffTime.." sweepDamage "..sweepDamage) + -- LogPink("curBoss "..curBoss.." blood "..blood.." canSweep "..canSweep.." buffCount "..buffCount.." buffTime "..buffTime.." sweepDamage "..msg.sweepDamage) Game.GlobalEvent:DispatchEvent(GameEvent.Guild.RefreshGuildTranscript) Game.GlobalEvent:DispatchEvent(GameEvent.Guild.RefreshGuildTranscriptBuff) end) @@ -73,7 +78,7 @@ end local oldBossId = 0 function this.RefreshGuildTranscriptInfo(msg) oldBossId = curBoss - LogGreen("msg.curBoss "..msg.curBoss.." msg.blood "..msg.blood.." msg.isKill "..msg.isKill) + -- LogGreen("msg.curBoss "..msg.curBoss.." msg.blood "..msg.blood.." msg.isKill "..msg.isKill) curBoss = msg.curBoss--当前bossId blood = msg.blood--剩余血量万分比 isKill = msg.isKill--是否击杀 @@ -90,10 +95,12 @@ function this.RefreshGuildTranscriptInfo(msg) isKill = 1 if not refreshedBoss[oldBossId] then refreshedBoss[oldBossId] = oldBossId - LogPink("msg.refreshedBoss "..oldBossId) - PrivilegeManager.RemovePrivilege(PRIVILEGE_TYPE.GUILDTRANSCRIPT_BATTLENUM,3013) - PrivilegeManager.RefreshStarPrivilege(PRIVILEGE_TYPE.GUILDTRANSCRIPT_BATTLENUM) - PrivilegeManager.RefreshStarPrivilege(PRIVILEGE_TYPE.GUILDTRANSCRIPT_BUY_BATTLENUM) + -- LogPink("msg.refreshedBoss "..oldBossId) + if endBossId ~= oldBossId then + PrivilegeManager.RemovePrivilege(PRIVILEGE_TYPE.GUILDTRANSCRIPT_BATTLENUM,3013) + PrivilegeManager.RefreshStarPrivilege(PRIVILEGE_TYPE.GUILDTRANSCRIPT_BATTLENUM) + PrivilegeManager.RefreshStarPrivilege(PRIVILEGE_TYPE.GUILDTRANSCRIPT_BUY_BATTLENUM) + end end end Game.GlobalEvent:DispatchEvent(GameEvent.Guild.RefreshGuildTranscript)