fix: 修复战斗开始时不调用卡牌和英雄初始等级问题

修复MissionComp中战斗开始时未调用call_cards方法的问题
调整SingletonModuleComp中英雄初始等级从1改为0
在MissionCardComp和HInfoComp中添加关闭解锁和购买界面的逻辑
更新ubtns.plist.meta中的边框设置
This commit is contained in:
walkpan
2026-01-08 09:18:20 +08:00
parent 76b89442f9
commit 2d560b2a2a
6 changed files with 18126 additions and 9381 deletions

View File

@@ -76,6 +76,8 @@ export class HInfoComp extends CCComp {
this.update_data(this.h_uuid)
this.load_all_hero(this.h_uuid)
this.showInfo()
this.close_buy()
this.close_ranks()
}
update(deltaTime: number) {
@@ -276,6 +278,18 @@ export class HInfoComp extends CCComp {
this.moveHeroesLeft();
this.show_lock()
}
show_buy(){
this.node.getChildByName("unlock").active=true
}
close_buy(){
this.node.getChildByName("unlock").active=false
}
show_ranks(){
this.node.getChildByName("ranks").active=true
}
close_ranks(){
this.node.getChildByName("ranks").active=false
}
buy_hero(){
console.info("[HInfoComp]:buy_hero",this.h_uuid)
if(smc.vmdata.gold < HeroConf.COST) {
@@ -285,6 +299,7 @@ export class HInfoComp extends CCComp {
smc.addHero(this.h_uuid)
this.load_all_hero(this.h_uuid)
this.show_lock()
this.close_buy()
}
start_mission() {
oops.message.dispatchEvent(GameEvent.MissionStart, {})