refactor(fight): 重构战斗系统效果和技能逻辑
- 移除了未使用的 Effect0 基类效果 - 优化了技能施放和效果执行的逻辑 - 调整了命中和闪避的计算方式 -
This commit is contained in:
@@ -18,14 +18,17 @@ type Input struct {
|
||||
*info.AttackValue
|
||||
FightC common.FightI
|
||||
// info.BattleActionI
|
||||
Effect NodeManager //effects容器OurEffect node.NodeManager //effects容器
|
||||
Damage decimal.Decimal //造成伤害
|
||||
First bool
|
||||
Effect NodeManager //effects容器 技能的
|
||||
Prop NodeManager //属性容器
|
||||
Status NodeManager //状态容器
|
||||
NewSeIdx NodeManager //全局容器
|
||||
Damage decimal.Decimal //造成伤害
|
||||
First bool //是否先手
|
||||
}
|
||||
|
||||
func NewInput(c common.FightI, p common.PlayerI) *Input {
|
||||
ret := &Input{FightC: c, Player: p}
|
||||
t, _ := NodeM[0]
|
||||
t := NodeM[0]
|
||||
ret.Effect.AddEffect(deepcopy.Copy(t).(Effect)) //添加默认基类,实现继承
|
||||
p.SetFightC(c) //给玩家设置战斗容器
|
||||
return ret
|
||||
|
||||
Reference in New Issue
Block a user