血条显示修改

This commit is contained in:
2025-06-12 20:30:19 +08:00
parent c35ae83511
commit 6aeee46c7c
27 changed files with 65 additions and 70 deletions

View File

@@ -20,7 +20,6 @@ export class BattleMoveSystem extends ecs.ComblockSystem implements ecs.ISystemU
const shouldStop = this.checkEnemiesInFace(e);
view.is_atking = this.checkEnemiesInRange(e, view.dis);
console.log("shouldStop",shouldStop,"view.is_atking",view.is_atking)
// 更新渲染层级
this.updateRenderOrder(e);

View File

@@ -39,12 +39,10 @@ export class BuffComp extends Component {
info_init(){
this.top_node = this.node.getChildByName("top");
this.top_node.getChildByName("lv").active=(this.node.getComponent(HeroViewComp).fac == 0 ? true : false)
this.top_node.getChildByName("lv").active=false
// this.top_node.getChildByName("hp").active=(this.node.getComponent(HeroViewComp).fac == 1 ? true : false)
this.top_node.getChildByName("sboss").active=this.node.getComponent(HeroViewComp).is_boss
if(this.node.getComponent(HeroViewComp).hero_uuid == 9999){
this.top_node.getChildByName("lv").active=false
}
this.top_node.getChildByName("lv").getChildByName("lv").getComponent(Label)!.string = this.node.getComponent(HeroViewComp).lv.toFixed(0)
this.top_node.getChildByName("ihp").getChildByName("num").getComponent(Label)!.string = this.node.getComponent(HeroViewComp).hp.toFixed(0)
this.top_node.getChildByName("iap").getChildByName("num").getComponent(Label)!.string = this.node.getComponent(HeroViewComp).ap.toFixed(0)