This commit is contained in:
panw
2026-03-10 11:15:46 +08:00
parent 7c1e09106e
commit 9ef2dd105f
5 changed files with 6096 additions and 1018 deletions

View File

@@ -96,7 +96,7 @@ export class HeroViewComp extends CCComp {
/* 显示角色血*/
this.top_node.getChildByName("hp").active = true;
this.top_node.getChildByName("mp").active = false
this.top_node.getChildByName("mp").active = true
this.top_node.getChildByName("shield").active = false;
// 初始隐藏血条(有更新时才显示)
@@ -111,8 +111,8 @@ export class HeroViewComp extends CCComp {
/** 初始化 UI 节点引用 */
private initUINodes() {
this.top_node = this.node.getChildByName("top");
let hp_y = this.node.getComponent(UITransform).height+10;
this.top_node.setPosition(0, hp_y, 0);
// let hp_y = this.node.getComponent(UITransform).height+10;
// this.top_node.setPosition(0, hp_y, 0);
smc.updateHeroInfo(this.model)
}