装备改为 buff 和 debuff 2种加成

This commit is contained in:
2025-06-14 22:54:07 +08:00
parent d01b98f9c3
commit cb91e66646
8 changed files with 162 additions and 144 deletions

View File

@@ -50,12 +50,12 @@ export class Skill extends ecs.Entity {
skillComp.ap = caster.ap+dmg;
if(caster.fac==0){
if(caster.is_master){
skillComp.ap=Math.floor(skillComp.ap*(100+FIGHTCON.hero.ATK+FIGHTCON.ally.ATK)/100);
skillComp.ap=Math.floor(skillComp.ap*(100+FIGHTCON.hero_buff.ATK)/100);
}else{
skillComp.ap=Math.floor(skillComp.ap*(100+FIGHTCON.friend.ATK+FIGHTCON.ally.ATK)/100);
skillComp.ap=Math.floor(skillComp.ap*(100+FIGHTCON.friend_buff.ATK)/100);
}
}else{
skillComp.ap=Math.floor(skillComp.ap*(100-FIGHTCON.enemy.ATK)/100);
skillComp.ap=Math.floor(skillComp.ap*(100-FIGHTCON.enemy_buff.ATK)/100);
}
skillComp.s_uuid = uuid;
skillComp.animType = config.AnimType;

View File

@@ -118,7 +118,7 @@ export class SkillCom extends CCComp {
if(target == null) return;
let remainingDamage = this.ap;
if(target.fac == BoxSet.HERO ){
remainingDamage=remainingDamage*(100-this.FIGHTCON.hero.DEF+this.FIGHTCON.hero_debuff.BURN)/100
remainingDamage=remainingDamage*(100-this.FIGHTCON.hero_buff.DEF+this.FIGHTCON.hero_debuff.BURN)/100
}
target.do_atked(remainingDamage)
this.ent.destroy()