feat(战斗系统): 添加伤害比例属性并应用到伤害计算
在SDataCom中添加dmg_ratio属性用于调整伤害比例 修改HeroAtkSystem中的伤害计算公式,将dmg_ratio纳入计算
This commit is contained in:
@@ -13,7 +13,8 @@ export class SDataCom extends ecs.Comp {
|
||||
fac: number = 0; // 0:hero 1:monster
|
||||
s_uuid:number=0
|
||||
ext_dmg:number=0 //额外伤害
|
||||
splash:number=0 //溅射伤害
|
||||
splash:number=0 //溅射伤害
|
||||
dmg_ratio:number=1 //伤害比例
|
||||
hit_count:number=0 //击中数量
|
||||
reset() {
|
||||
this.Attrs=null
|
||||
@@ -24,6 +25,7 @@ export class SDataCom extends ecs.Comp {
|
||||
this.hit_count=0
|
||||
this.ext_dmg=0
|
||||
this.splash=0
|
||||
this.dmg_ratio=1
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user