fix(fight): 修复空变更提交问题

This commit is contained in:
1
2025-11-09 02:48:32 +00:00
parent 51cd6636c4
commit f3c5a5106c
2 changed files with 3 additions and 2 deletions

View File

@@ -278,7 +278,7 @@ func (f *FightC) processSkillAttack(attacker, defender *input.Input, a *action.S
attacker.SkillID = uint32(a.ID) //获取技能ID
if attacker.AttackTime > 0 { //如果命中
attacker.UseSkill(defender, a) //暴击计算
attacker.CalculateCrit(defender, a) //暴击计算
attacker.AttackValue.IsCritical = a.Crit
attacker.DamageZone.Damage = attacker.CalculatePower(defender, a.SkillEntity)

View File

@@ -13,7 +13,8 @@ import (
"github.com/shopspring/decimal"
)
func (u *Input) UseSkill(opp *Input, skill *action.SelectSkillAction) {
// 计算暴击
func (u *Input) CalculateCrit(opp *Input, skill *action.SelectSkillAction) {
skill.Crit = 0
if skill.Category() == info.Category.STATUS { //属性技能不用算暴击