战斗修改 我要变强,战斗伤害记录入口屏蔽

wangzhenxing 2023-11-13 18:28:01 +08:00
parent 667c386356
commit d5ed3cf71b
4 changed files with 20 additions and 3 deletions

View File

@ -158,7 +158,7 @@ end
-- 判断是否命中 -- 判断是否命中
function Skill:CheckTargetIsHit(role) function Skill:CheckTargetIsHit(role)
if role==nil then if role == nil then
return false return false
end end
return self.effectCaster:CheckTargetIsHit(role) return self.effectCaster:CheckTargetIsHit(role)

View File

@ -85,7 +85,18 @@ function SkillCaster:OnSkillCast(skill)
local targets = skill:GetDirectTargets() local targets = skill:GetDirectTargets()
for _, target in ipairs(targets) do for _, target in ipairs(targets) do
local t= self.owner.RootPanel.GetRoleView(target) local t= self.owner.RootPanel.GetRoleView(target)
self.owner.RoleLiveGO.transform:DOMove(Vector3.New(t.GameObject.transform.position.x-(self.owner.camp==0 and displaceoffset[1] or(-displaceoffset[1])),t.GameObject.transform.position.y+displaceoffset[2],t.GameObject.transform.position.z), combat.AttackDisplaceTime/1000, false):OnComplete(function () local posx=0
local posy=0
if displaceoffset and #displaceoffset>0 then
if displaceoffset[1] and type(displaceoffset[1]) ~="userdata" then
posx=displaceoffset[1]
end
if displaceoffset[2] and type(displaceoffset[2]) ~="userdata" then
posy=displaceoffset[2]
end
end
self.owner.RoleLiveGO.transform:DOMove(Vector3.New(t.GameObject.transform.position.x-(self.owner.camp==0 and posx or(-posx)),t.GameObject.transform.position.y+posy,t.GameObject.transform.position.z), combat.AttackDisplaceTime/1000, false):OnComplete(function ()
if self.owner.OnSkillPlay then if self.owner.OnSkillPlay then
self.owner:OnSkillPlay(localtype,combat) self.owner:OnSkillPlay(localtype,combat)
end end
@ -106,11 +117,14 @@ function SkillCaster:OnSkillCast(skill)
-- displaceoffset=self.owner.SkillAttackDisplaceoffset -- displaceoffset=self.owner.SkillAttackDisplaceoffset
-- end -- end
if skill.AttackDisplaceOffset then if skill.AttackDisplaceOffset then
displaceoffset=skill.AttackDisplaceOffset if skill.AttackDisplaceOffset and #skill.AttackDisplaceOffset>0 and type(skill.AttackDisplaceOffset[1]) ~="userdata" and type(skill.AttackDisplaceOffset[2]) ~="userdata" then
displaceoffset=skill.AttackDisplaceOffset
end
end end
self.owner.GameObject:SetActive(false) self.owner.GameObject:SetActive(false)
local targets = skill:GetDirectTargets() local targets = skill:GetDirectTargets()
for _, target in ipairs(targets) do for _, target in ipairs(targets) do
local t= self.owner.RootPanel.GetRoleView(target) local t= self.owner.RootPanel.GetRoleView(target)
self.owner.RoleLiveGO.transform:DOMove(Vector3.New(t.GameObject.transform.position.x-(self.owner.camp==0 and displaceoffset[1] or(-displaceoffset[1])),t.GameObject.transform.position.y+displaceoffset[2],t.GameObject.transform.position.z), combat.AttackDisplaceTime/1000, false):OnComplete(function () self.owner.RoleLiveGO.transform:DOMove(Vector3.New(t.GameObject.transform.position.x-(self.owner.camp==0 and displaceoffset[1] or(-displaceoffset[1])),t.GameObject.transform.position.y+displaceoffset[2],t.GameObject.transform.position.z), combat.AttackDisplaceTime/1000, false):OnComplete(function ()
if self.owner.OnSkillPlay then if self.owner.OnSkillPlay then

View File

@ -125,6 +125,8 @@ function BattleFailPopup:OnOpen(battlePanel, showRecord, backPanel,_fightType)
this.btnBattleBack:SetActive(true) this.btnBattleBack:SetActive(true)
this.btnGrowUp:SetActive(true) this.btnGrowUp:SetActive(true)
end end
this.btnGrowUp:SetActive(false)
this.btn_record:SetActive(false)
if fightType == BATTLE_TYPE.GUILD_CAR_DELAY then--车迟 if fightType == BATTLE_TYPE.GUILD_CAR_DELAY then--车迟
--车迟抢夺cd计时 --车迟抢夺cd计时
GuildCarDelayManager.SetCdTime(GuildCarDelayProType.Loot) GuildCarDelayManager.SetCdTime(GuildCarDelayProType.Loot)

View File

@ -152,6 +152,7 @@ function RewardItemPopup:OnOpen(...)
end end
local haveRecord = BattleRecordManager.isHaveRecord() local haveRecord = BattleRecordManager.isHaveRecord()
this.btnResult:SetActive(haveRecord and args[5]) this.btnResult:SetActive(haveRecord and args[5])
this.btnResult:SetActive(false)
this.btnBattleBack:SetActive(haveRecord and args[5] and BattleManager.GetLastBattleType() ~= BATTLE_TYPE.MAP_FIGHT and not GuideManager.IsInMainGuide() and not MapManager.Mapping and BattleManager.GetLastBattleType() ~= BATTLE_TYPE.TASUILINGXIAO) this.btnBattleBack:SetActive(haveRecord and args[5] and BattleManager.GetLastBattleType() ~= BATTLE_TYPE.MAP_FIGHT and not GuideManager.IsInMainGuide() and not MapManager.Mapping and BattleManager.GetLastBattleType() ~= BATTLE_TYPE.TASUILINGXIAO)
this.expeditionGo:SetActive(compShowType == 5) this.expeditionGo:SetActive(compShowType == 5)
this.guildDeathPos:SetActive(compShowType == 4)--十绝阵 this.guildDeathPos:SetActive(compShowType == 4)--十绝阵