feat(战斗系统): 实现攻击和技能伤害加成天赋效果

添加ATK_DMG和SKILL_DMG天赋类型,支持在普通攻击和技能释放时应用额外伤害
修改SACastSystem以处理不同类型的伤害加成
重构TalEffet枚举并更新相关配置
This commit is contained in:
2025-11-24 15:39:05 +08:00
parent 4ed531e100
commit 8d2ec76b01
4 changed files with 57 additions and 25 deletions

View File

@@ -202,6 +202,21 @@ export class TalComp extends ecs.Comp {
const talent = this.Tals[uuid];
const heroAttrs=this.ent.get(HeroAttrsComp);
switch(talent.effet){
case TalEffet.ATK_DMG:
heroAttrs.addCountTal(TalEffet.ATK_DMG, talent.value + talent.value_add);
break;
case TalEffet.SKILL_DMG:
heroAttrs.addCountTal(TalEffet.SKILL_DMG, talent.value + talent.value_add);
break;
case TalEffet.LDMG:
heroAttrs.addCountTal(TalEffet.LDMG, talent.value + talent.value_add);
break;
// case TalEffet.HP:
// heroAttrs.addCountTal(TalEffet.HP, talent.value + talent.value_add);
// break;
// case TalEffet.MP:
// heroAttrs.addCountTal(TalEffet.MP, talent.value + talent.value_add);
// break;
case TalEffet.WFUNY:
heroAttrs.addCountTal(TalEffet.WFUNY, talent.value + talent.value_add);
break;