feat(game): 技能基础框架基本搭建完成,下步遇到再完善
- 调整了英雄角色top.prefab节点结构和组件关联,优化层级关系和属性值 - 修改pow、mpb等子节点的组件及位置,提升表现效果 - 更新技能atk_fires.prefab增加了ReadyLoop、SkillTime等新属性 - 调整攻击技能atk_s1.prefab的运行类型及相关时间与计数参数 - 修正atk_s1.prefab目标覆盖配置,完善prefab实例结构 - 精简atk_s_1.prefab的子节点引用,去除冗余id链接,简化资源结构
This commit is contained in:
@@ -120,7 +120,7 @@ export class HeroViewComp extends CCComp {
|
||||
}
|
||||
/* 显示角色血*/
|
||||
this.node.getChildByName("top").getChildByName("hp").active = true;
|
||||
this.BUFFCOMP.show_shield(this.shield,this.Attrs[Attrs.SHIELD_MAX])
|
||||
this.node.getChildByName("top").getChildByName("pow").active = true;
|
||||
}
|
||||
|
||||
// ==================== BUFF系统初始====================
|
||||
@@ -494,12 +494,16 @@ export class HeroViewComp extends CCComp {
|
||||
this.processDamageQueue();
|
||||
// 更新临时 buff/debuff 时间
|
||||
this.updateTemporaryBuffsDebuffs(dt);
|
||||
this.BUFFCOMP.hp_show(this.hp,this.Attrs[Attrs.HP_MAX])
|
||||
this.BUFFCOMP.mp_show(this.mp,this.Attrs[Attrs.MP_MAX])
|
||||
this.BUFFCOMP.show_shield(this.shield,this.Attrs[Attrs.SHIELD_MAX])
|
||||
}
|
||||
BaseUp(dt:number){
|
||||
this.mp += HeroUpSet.MP*dt
|
||||
this.hp += HeroUpSet.HP*dt
|
||||
if(this.mp > this.Attrs[Attrs.MP_MAX]) this.mp = this.Attrs[Attrs.MP_MAX]
|
||||
if(this.hp > this.Attrs[Attrs.HP_MAX]) this.hp = this.Attrs[Attrs.HP_MAX]
|
||||
|
||||
}
|
||||
do_fight_end(){
|
||||
this.as.do_buff()
|
||||
@@ -587,23 +591,15 @@ export class HeroViewComp extends CCComp {
|
||||
|
||||
}
|
||||
|
||||
do_atked(remainingDamage:number,
|
||||
crit:number=0,crit_d:number=0,
|
||||
burn_count:number=0,burn_value:number=0,
|
||||
stun_time:number=0,stun_ratio:number=0,
|
||||
frost_time:number=0,frost_ratio:number=0,
|
||||
atked_anm:string="atked"
|
||||
){
|
||||
do_atked(remainingDamage:number,CAttrs:any,s_uuid:number){
|
||||
let SConf=SkillSet[s_uuid]
|
||||
this.do_atked_trigger()
|
||||
|
||||
|
||||
if(this.check_dodge()) return
|
||||
let is_crit = this.check_crit(crit)
|
||||
|
||||
let is_crit = this.check_crit(CAttrs[Attrs.CRITICAL])
|
||||
if(this == null) return;
|
||||
let damage = this.count_damage(remainingDamage)
|
||||
if(is_crit) {
|
||||
damage = Math.floor(damage * (1 + (FightSet.CRIT_DAMAGE+crit_d)/100))
|
||||
damage = Math.floor(damage * (1 + (FightSet.CRIT_DAMAGE+CAttrs[Attrs.CRITICAL_DMG])/100))
|
||||
}
|
||||
// console.log(this.hero_name+"[HeroViewComp]:heroview :damage|hp|hp_max",damage,this.hp,this.Attrs[BuffAttr.HP_MAX])
|
||||
damage=this.check_shield(damage)
|
||||
@@ -625,12 +621,9 @@ export class HeroViewComp extends CCComp {
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
// this.update_vm
|
||||
this.back()
|
||||
this.showDamage(damage, is_crit,atked_anm);
|
||||
|
||||
this.showDamage(damage, is_crit,SConf.AtkedType);
|
||||
}
|
||||
//后退
|
||||
back(){
|
||||
|
||||
Reference in New Issue
Block a user