From 0e7a009383fe739bdee572a67876f2f59c66050f Mon Sep 17 00:00:00 2001 From: xlj <543978819@qq.com> Date: Sat, 20 Sep 2025 20:44:55 +0800 Subject: [PATCH] update --- assets/Scripts/Sub/UI/PreloadUI.ts | 13 ++++++++++--- xchat_cfg | 2 +- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/assets/Scripts/Sub/UI/PreloadUI.ts b/assets/Scripts/Sub/UI/PreloadUI.ts index 1a7f69a3..dedbfb9e 100644 --- a/assets/Scripts/Sub/UI/PreloadUI.ts +++ b/assets/Scripts/Sub/UI/PreloadUI.ts @@ -15,6 +15,7 @@ import { ProgressBar, Sprite, SpriteFrame, + VideoPlayer, } from "cc"; import { GButton } from "../../Main/Common/GButton"; import ResManager from "../../Main/Manager/ResManager"; @@ -60,7 +61,7 @@ export class PreloadUI extends Component { loginBtn: Node; private jinduBar: Node = null; private jinduFilled: Sprite = null; - + private VideoPlayer: VideoPlayer; start() { //Utils.addInnerEL(InnerMsgCode.UI_ShowPrompt, this, this.resiveShowPrompt) Utils.parseNode(this.node, this._nodeTab); @@ -68,6 +69,8 @@ export class PreloadUI extends Component { this.loginBtn = this._nodeTab.btnLogin; this.loginBtn.active = false; + this.VideoPlayer = this._nodeTab.VideoPlayer.getComponent(VideoPlayer); + GButton.BandClick(this.loginBtn, this.onLogin, this); this.jinduBar = this.node.getChildByName("jinduBar"); @@ -81,6 +84,8 @@ export class PreloadUI extends Component { this.jinduFilled.fillRange = 0; + if (!this.VideoPlayer.isPlaying) this.VideoPlayer.play(); + // 初始化配置 ConfigManager.I.init(); //console.log(ConfigManager.tables.TbGlobalConfig.GameName); @@ -254,10 +259,12 @@ export class PreloadUI extends Component { let res = await CommonService.I.reqResConfig(reqData); if (res && res.code === proto.cs.EnmRetCode.SUCCESS) { // 保存数据 - const aiCharacterData = DataManager.I.getDataById(DataId.AiCharacter); + const aiCharacterData = DataManager.I.getDataById( + DataId.AiCharacter + ); aiCharacterData.aiCharacter = res.data; } - } + } private enterGame() { this.mainScene.init(); diff --git a/xchat_cfg b/xchat_cfg index efa86a17..cbc3df1c 160000 --- a/xchat_cfg +++ b/xchat_cfg @@ -1 +1 @@ -Subproject commit efa86a170dd5076414b26921bd7867f9db88c422 +Subproject commit cbc3df1ca2522e1bdb47d0fdf4371f47b3485a1d