修复bug和ui调整,下一步,达到特定等级才激活技能

This commit is contained in:
2025-07-23 10:41:09 +08:00
parent 1611b5d3b5
commit f805bbcd4a
138 changed files with 12897 additions and 56084 deletions

View File

@@ -20,6 +20,7 @@ export class BarCompComp extends CCComp {
hero:HeroViewComp = null;
friend:HeroViewComp = null;
boss:HeroViewComp = null;
update_count:number=0
/** 视图层逻辑代码分离演示 */
protected onLoad(): void {
this.on(GameEvent.FightReady,this.readay,this)
@@ -38,6 +39,7 @@ export class BarCompComp extends CCComp {
this.node.getChildByName("bar").active = true
this.node.getChildByName("bar").getChildByName("more").active=false
this.node.getChildByName("bar").getChildByName("uplv").active=false
this.update_count=0
}
private master_called(e:any,data:any){
this.node.getChildByName("bar").active = true
@@ -62,9 +64,12 @@ export class BarCompComp extends CCComp {
}
}
show_uplv_button(){
this.update_count++
this.node.getChildByName("bar").getChildByName("uplv").active=true
}
hide_uplv_button(){
this.update_count--
if(this.update_count > 0) return
this.node.getChildByName("bar").getChildByName("uplv").active=false
}
show_master_more(){