feat: 实现战斗效果逻辑和接口重构
Some checks failed
ci/woodpecker/push/my-first-workflow Pipeline failed

This commit is contained in:
xinian
2026-03-28 21:57:22 +08:00
committed by cnb
parent 0780eae582
commit 875ad668aa
332 changed files with 2062 additions and 1442 deletions

View File

@@ -22,8 +22,8 @@ type EffectRandomPower struct {
// -----------------------------------------------------------
func init() {
registerRandomPower(61, 50, 150)
registerRandomPower(70, 140, 220)
registerRandomPower(118, 140, 180)
registerRandomPower(70, 150, 220)
registerRandomPower(118, 150, 220)
}
// -----------------------------------------------------------
@@ -45,13 +45,6 @@ func (e *EffectRandomPower) SkillHit() bool {
return true
}
// 如果 FightC 没提供随机器,使用 math/rand 兜底
// var n int
// if e.Input != nil && e.Input.FightC != nil {
// n = int(e.Input.FightC.GetRand().Int31n(int32(e.Max-e.Min+1))) + e.Min
// } else {
// n = grand.Intn(e.Max-e.Min+1) + e.Min
// }
n := grand.N(e.Min, e.Max)
e.Ctx().SkillEntity.XML.Power = n
return true