diff --git a/modules/hero/model_hero.go b/modules/hero/model_hero.go index 34110531b..9d5dc9db0 100644 --- a/modules/hero/model_hero.go +++ b/modules/hero/model_hero.go @@ -209,24 +209,8 @@ func (this *ModelHero) resetJuexingProperty(hero *pb.DBHero) { continue } value, _ := strconv.Atoi(awakenData.Phasebonus[1]) - switch key { - case comm.Hp: - hero.JuexProperty[comm.Hp] += int32(value) - case comm.Def: - hero.JuexProperty[comm.Def] += int32(value) - case comm.Atk: - hero.JuexProperty[comm.Atk] += int32(value) - case comm.Speed: - hero.JuexProperty[comm.Speed] += int32(value) - case comm.ResonanceHpPro: - hero.JuexProperty[comm.Hp] += int32(math.Floor((float64(value) / 1000) * float64(hero.Property[comm.Hp]))) - case comm.ResonanceAtkPro: - hero.JuexProperty[comm.Atk] += int32(math.Floor((float64(value) / 1000) * float64(hero.Property[comm.Atk]))) - case comm.ResonanceDefPro: - hero.JuexProperty[comm.Def] += int32(math.Floor((float64(value) / 1000) * float64(hero.Property[comm.Def]))) - default: - this.module.Errorf("unkonw Resonance property:%s", key) - } + hero.JuexProperty[key] += int32(value) + } }