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)