fix(英雄视图): 修复怪物显示蓝条的问题

根据角色阵营决定是否显示蓝条,仅英雄角色显示
This commit is contained in:
walkpan
2026-01-02 15:19:50 +08:00
parent ed728bd1b9
commit 7b69700f14

View File

@@ -102,7 +102,8 @@ export class HeroViewComp extends CCComp {
// }
/* 显示角色血*/
this.top_node.getChildByName("hp").active = true;
this.top_node.getChildByName("mp").active = true;
// 🔥 怪物不显示蓝条
this.top_node.getChildByName("mp").active = this.model.fac === FacSet.HERO;
this.top_node.getChildByName("shield").active = false;
// 初始隐藏血条(被攻击后才显示)
this.top_node.active = true;