修改战斗

onepiece_demo_arena
xiejun 2023-12-13 19:08:39 +08:00
parent e2a2bb3f1b
commit 25dc5ca5a9
2 changed files with 5 additions and 2 deletions

View File

@ -1065,6 +1065,8 @@ function this.GetSkillCombat(id)
HightLightTime=combat.HightLightTime, HightLightTime=combat.HightLightTime,
AttackMove=combat.AttackMove, AttackMove=combat.AttackMove,
HitScale=combat.HitScale, HitScale=combat.HitScale,
HitRecycleTime=combat.HitRecycleTime,
HitTimeScale=combat.HitTimeScale,
} }

View File

@ -832,13 +832,14 @@ function SkillCaster:CheckSkillHitEffect(checkType, combat, skill)
local scale = combat.HitScale and Vector3.New(combat.HitScale[1]/1000, combat.HitScale[2]/1000, 0) or Vector3.One local scale = combat.HitScale and Vector3.New(combat.HitScale[1]/1000, combat.HitScale[2]/1000, 0) or Vector3.One
local sortingOrder = self.owner.role.camp == 0 and self.owner.GameObject:GetComponent("Canvas").sortingOrder + 21 or BattleManager.GetBattleSorting() + 20 local sortingOrder = self.owner.role.camp == 0 and self.owner.GameObject:GetComponent("Canvas").sortingOrder + 21 or BattleManager.GetBattleSorting() + 20
local go2 = BattleManager.LoadSpineAsset(combat.Hit, self.owner.SingleHitEffectRoot.transform) local go2 = BattleManager.LoadSpineAsset(combat.Hit, self.owner.SingleHitEffectRoot.transform)
go2.transform:SetParent(self.owner.SingleHitEffectRoot.transform) go2.transform:SetParent(self.owner.SingleHitEffectRoot.transform)
-- 检测特效旋转 -- 检测特效旋转
local compnet=go2:GetComponent("SkeletonGraphic") local compnet=go2:GetComponent("SkeletonGraphic")
if compnet~=nil then if compnet~=nil then
-- compnet.transform.localScale = Vector3.one * 3 -- compnet.transform.localScale = Vector3.one * 3
-- compnet.transform.sizeDelta = Vector2.New(1000, 1000) -- compnet.transform.sizeDelta = Vector2.New(1000, 1000)
compnet.AnimationState:SetAnimation(0, "attack", true) compnet.AnimationState:SetAnimation(0, "attack", true)
compnet.AnimationState.TimeScale=combat.HitTimeScale/1000
end end
if self:CheckRotate(go2, combat.HitOrientation) then if self:CheckRotate(go2, combat.HitOrientation) then
offset = -offset offset = -offset
@ -848,7 +849,7 @@ function SkillCaster:CheckSkillHitEffect(checkType, combat, skill)
-- go2.transform:SetParent(self.effectRoot.transform) -- go2.transform:SetParent(self.effectRoot.transform)
go2.transform.localScale = scale go2.transform.localScale = scale
go2:SetActive(true) go2:SetActive(true)
BattleManager.AddDelayRecycleRes(combat.Hit, go2, 2) BattleManager.AddDelayRecycleRes(combat.Hit, go2,combat.HitRecycleTime/1000 )
LogError("HitTime") LogError("HitTime")
end end