This commit is contained in:
2025-09-03 10:58:29 +08:00
parent 8e044fcf3c
commit 5b9c00fa7a
3 changed files with 1034 additions and 1585 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -67,7 +67,7 @@ export const GuideConfig: { [key: number]: IGuideStep } = {
0: { 0: {
id: "welcome", type: GuideStepType.WAIT,key:0, id: "welcome", type: GuideStepType.WAIT,key:0,
targetPath: "root/gui/LayerUI/role_controller/mission_home/start/name", targetPath: "root/gui/LayerUI/role_controller/mission_home/start/name",
tipText: "伟大的勇者,欢迎来到 『像素大陆』", tipText: "伟大的勇者,欢迎来到 『像素模拟战』",
handOffset: { x: 42, y: -45 }, handOffset: { x: 42, y: -45 },
nextStep: "start_battle", waitTime: 5, end_event: "click", noInput: true, nextStep: "start_battle", waitTime: 5, end_event: "click", noInput: true,
}, },

View File

@@ -6,6 +6,7 @@ import { smc } from "../common/SingletonModuleComp";
import { GameEvent } from "../common/config/GameEvent"; import { GameEvent } from "../common/config/GameEvent";
import { ItemComp } from "./ItemComp"; import { ItemComp } from "./ItemComp";
import { startGuide } from "../common/config/Guide"; import { startGuide } from "../common/config/Guide";
import { it } from "node:test";
const { ccclass, property } = _decorator; const { ccclass, property } = _decorator;
@@ -36,9 +37,9 @@ export class VictoryComp extends CCComp {
this.add_reward(args.rewards) this.add_reward(args.rewards)
this.rewards=args.rewards this.rewards=args.rewards
} }
this.node.getChildByName("box").getChildByName("exp").getChildByName("num").getComponent(Label)!.string="x"+this.game_data["exp"].toString() this.node.getChildByName("box").getChildByName("items").getChildByName("exp").getChildByName("num").getComponent(Label)!.string="x"+this.game_data["exp"].toString()
this.node.getChildByName("box").getChildByName("gold").getChildByName("num").getComponent(Label)!.string="x"+this.game_data["gold"].toString() this.node.getChildByName("box").getChildByName("items").getChildByName("gold").getChildByName("num").getComponent(Label)!.string="x"+this.game_data["gold"].toString()
this.node.getChildByName("box").getChildByName("diamond").getChildByName("num").getComponent(Label)!.string="x"+this.game_data["diamond"].toString() this.node.getChildByName("box").getChildByName("items").getChildByName("diamond").getChildByName("num").getComponent(Label)!.string="x"+this.game_data["diamond"].toString()
this.node.getChildByName("title").getChildByName("victory").active=args.victory this.node.getChildByName("title").getChildByName("victory").active=args.victory
this.node.getChildByName("title").getChildByName("defeat").active=!args.victory this.node.getChildByName("title").getChildByName("defeat").active=!args.victory
this.node.getChildByName("btns").getChildByName("next").active=false this.node.getChildByName("btns").getChildByName("next").active=false
@@ -76,7 +77,14 @@ export class VictoryComp extends CCComp {
diamond:0 diamond:0
} }
this.rewards=[] this.rewards=[]
this.node.getChildByName("box").getChildByName("items").removeAllChildren() let items=this.node.getChildByName("box").getChildByName("items")
items.children.forEach(element => {
if(element.name=="exp"||element.name=="gold"||element.name=="diamond"){
element.getChildByName("num").getComponent(Label)!.string="0"
}else{
element.destroy()
}
});
} }
//看广告双倍 //看广告双倍
watch_ad(){ watch_ad(){