refactor(fight): 重构战斗模块

- 移除 BattleStateMachine 和 BattleUnit 相关代码
- 新增 BattleContainer 和 DamageContext 结构体
- 重构伤害计算逻辑,使用高精度 decimal 进行计算
- 更新随机数生成器,支持基于用户和时间的种子生成
- 优化战斗信息结构,增加 OwnerID 字段
This commit is contained in:
2025-08-25 12:58:08 +08:00
parent ada45feb01
commit 1405bf5ee9
10 changed files with 172 additions and 378 deletions

View File

@@ -13,6 +13,7 @@ func (h Controller) OnPlayerFightNpcMonster(data *fight.FightNpcMonsterInboundIn
c.IsFighting = true
t1 := handler.NewTomeeHeader(2503, c.UserID)
ttt := info.NoteReadyToFightInfo{
OwnerID: data.Head.UserID,
FightId: 3,
}
ttt.OurInfo = info.FightUserInfo{UserID: c.UserID}