fix: 修正伤害类型和任务状态判断逻辑
All checks were successful
ci/woodpecker/push/my-first-workflow Pipeline was successful

This commit is contained in:
xinian
2026-03-05 17:40:42 +08:00
committed by cnb
parent 3833fd3884
commit 03d93a2fba
4 changed files with 5 additions and 6 deletions

View File

@@ -37,7 +37,6 @@ func (e *NewSel16) TurnStart(fattack *action.SelectSkillAction, sattack *action.
e.Ctx().Our.SetProp(e.Ctx().Our, int8(e.Args()[0].IntPart()), 1, info.AbilityOpType.ADD)
}
return
}
func init() {
input.InitEffect(input.EffectType.NewSel, 16, &NewSel16{})

View File

@@ -77,7 +77,7 @@ func (e *Effect120) OnSkill() bool {
oppMaxHP := alpacadecimal.NewFromInt(int64(e.Ctx().Opp.CurrentPet.Info.MaxHp))
damage := oppMaxHP.Mul(percent).Div(alpacadecimal.NewFromInt(100))
e.Ctx().Opp.Damage(e.Ctx().Our, &info.DamageZone{
Type: info.DamageType.Fixed,
Type: info.DamageType.Percent,
Damage: damage,
})
} else {
@@ -85,7 +85,7 @@ func (e *Effect120) OnSkill() bool {
ourMaxHP := alpacadecimal.NewFromInt(int64(e.Ctx().Our.CurrentPet.Info.MaxHp))
damage := ourMaxHP.Mul(percent).Div(alpacadecimal.NewFromInt(100))
e.Ctx().Our.Damage(e.Ctx().Opp, &info.DamageZone{
Type: info.DamageType.Fixed,
Type: info.DamageType.Percent,
Damage: damage,
})
}

View File

@@ -24,7 +24,7 @@ type Effect28 struct {
func (e *Effect28) OnSkill() bool {
e.Ctx().Opp.Damage(e.Ctx().Our, &info.DamageZone{
Type: info.DamageType.Fixed,
Type: info.DamageType.Percent,
Damage: e.Ctx().Opp.CurrentPet.GetHP().Div(e.Args()[0]),
})
return true

View File

@@ -104,7 +104,7 @@ func (s *InfoService) SetLogin() *model.PlayerInfo {
//tt.Data.FightTime = 60 * 60 * 2 //重置战斗次数
for _, v := range service.NewTaskService().GetDaily() {
if v.IsAcceptable == 0 {
if v.IsAcceptable == 1 {
tt.Data.SetTask(int(v.TaskId), model.Unaccepted)
} else {
tt.Data.SetTask(int(v.TaskId), model.Reserved)
@@ -127,7 +127,7 @@ func (s *InfoService) SetLogin() *model.PlayerInfo {
tt.WeekLastResetTime = gtime.Now()
for _, v := range service.NewTaskService().GetWeek() {
if v.IsAcceptable == 0 {
if v.IsAcceptable == 1 {
tt.Data.SetTask(int(v.TaskId), model.Unaccepted)
} else {
tt.Data.SetTask(int(v.TaskId), model.Reserved)