feat(fight): 添加战斗前状态检查与经验获取限制判断
- 在挑战BOSS和野外怪物战斗前,增加 CanFight 状态检查,防止非法战斗 - 修复战斗胜利后经验与物品发放逻辑,增加 CanGetExp 判断避免重复获取 - 优化战斗中精灵切换逻辑与相关伤害效果处理,确保死亡标记正确设置 - 修正战斗轮次中被动切换行为及技能执行顺序问题 - 移除无用的管理员会话控制器和宠物融合模型代码 - 调整战斗输入结构体中的 Switch 类型为 Map 以提高查找效率 - 修复战斗中精灵存活判定条件,
This commit is contained in:
@@ -38,8 +38,10 @@ func (p *Player) AddPetExp(petinfo *model.PetInfo, addExp uint32) {
|
||||
petinfo.Exp = Exp
|
||||
// 重新计算面板
|
||||
if originalLevel != petinfo.Level {
|
||||
if petinfo.Level <= 100 {
|
||||
petinfo.CalculatePetPane()
|
||||
}
|
||||
|
||||
petinfo.CalculatePetPane()
|
||||
petinfo.Cure()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user