fix(fight): 修复技能效果参数错误和伤害统计问题 - 修复effect_508中参数索引错误,将Args()[1]改为Args()[0] - 修复effect_508中持续时间设置错误,统一设置为1 - 修复战斗伤害统计错误,将我方受伤统计改为对方受伤统计 ```
This commit is contained in:
@@ -35,8 +35,8 @@ func (e *Effect508) DamageSubEx(t *info.DamageZone) bool {
|
|||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
if t.Damage.Cmp(e.Args()[1]) > 0 {
|
if t.Damage.Cmp(e.Args()[0]) > 0 {
|
||||||
t.Damage = t.Damage.Sub(e.Args()[1])
|
t.Damage = t.Damage.Sub(e.Args()[0])
|
||||||
} else {
|
} else {
|
||||||
t.Damage = alpacadecimal.Zero
|
t.Damage = alpacadecimal.Zero
|
||||||
}
|
}
|
||||||
@@ -45,6 +45,6 @@ func (e *Effect508) DamageSubEx(t *info.DamageZone) bool {
|
|||||||
func (e *Effect508) SetArgs(t *input.Input, a ...int) {
|
func (e *Effect508) SetArgs(t *input.Input, a ...int) {
|
||||||
|
|
||||||
e.EffectNode.SetArgs(t, a...)
|
e.EffectNode.SetArgs(t, a...)
|
||||||
e.EffectNode.Duration(e.EffectNode.SideEffectArgs[0])
|
e.EffectNode.Duration(1)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -166,7 +166,7 @@ func (our *Input) Damage(in *Input, sub *info.DamageZone) {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
if sub.Type == info.DamageType.Red { //红才会产生造成伤害
|
if sub.Type == info.DamageType.Red { //红才会产生造成伤害
|
||||||
our.AttackValue.LostHp += uint32(sub.Damage.IntPart()) //红伤落实
|
our.Opp.AttackValue.LostHp += uint32(sub.Damage.IntPart()) //红伤落实
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user