添加英雄

This commit is contained in:
2025-01-11 11:27:40 +08:00
parent 56832c41fe
commit 3bb8b689a6
126 changed files with 37305 additions and 11828 deletions

View File

@@ -55,6 +55,7 @@ export class HeroViewComp extends CCComp {
is_dead:boolean = false; //是否摧毁
is_stop:boolean = false;
is_atking:boolean = false;
is_boss:boolean = false;
hp: number = 100; /** 血量 */
hp_max: number = 100; /** 最大血量 */
@@ -137,6 +138,10 @@ export class HeroViewComp extends CCComp {
/** 方向 */
this.node.setScale(this.scale,1);
this.node.getChildByName("top").setScale(this.scale,1);
if(this.is_boss){
this.node.setScale(this.node.scale.x*1.2,this.node.scale.y*1.2);
this.node.getChildByName("top").getChildByName("sboss").active = true;
}
/** 显示角色血量 */
this.node.getChildByName("top").getChildByName("hp").active = true;
@@ -509,8 +514,8 @@ export class HeroViewComp extends CCComp {
}
//使用max_skill
do_skill(skill:number){
this.as.max()
this.at = 0; //共享普攻攻击cd
// this.as.max()
// this.at = 0; //共享普攻攻击cd
this.BUFFCOMP.tooltip(3,SkillSet[skill].name,skill);
switch (SkillSet[skill].tg) {
case SkTG.self: //自己