From 7a33e422f488306a2c31eaecb732474dc17a1ecc Mon Sep 17 00:00:00 2001 From: dgflash Date: Thu, 28 Jul 2022 09:50:32 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E8=A7=86=E5=9B=BE=E5=B1=82?= =?UTF-8?q?=E4=BB=A3=E7=A0=81=E6=A8=A1=E6=9D=BF=EF=BC=8C=E4=BD=BF=E8=87=AA?= =?UTF-8?q?=E5=AE=9A=E4=B9=89=E5=88=9D=E5=A7=8B=E5=8C=96=E7=95=8C=E9=9D=A2?= =?UTF-8?q?=E9=80=BB=E8=BE=91=E5=9C=A8GameComponent.start=E7=94=9F?= =?UTF-8?q?=E5=91=BD=E5=91=A8=E6=9C=9F=E4=B8=AD=E7=BC=96=E5=86=99=EF=BC=8C?= =?UTF-8?q?=E6=96=B9=E4=BE=BF=E5=9C=A8=E4=BD=BF=E7=94=A8oops.gui.openAsync?= =?UTF-8?q?=E6=97=B6=E8=8E=B7=E5=8F=96=E5=88=B0ecs=E5=AE=9E=E4=BD=93?= =?UTF-8?q?=E5=AF=B9=E8=B1=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .creator/asset-template/typescript/ModuleView.ts | 2 +- .creator/asset-template/typescript/ModuleViewVM.ts | 2 +- assets/main.scene | 4 +++- assets/script/game/initialize/bll/InitRes.ts | 10 +++------- 4 files changed, 8 insertions(+), 10 deletions(-) diff --git a/.creator/asset-template/typescript/ModuleView.ts b/.creator/asset-template/typescript/ModuleView.ts index 97f50dd..13ad0da 100644 --- a/.creator/asset-template/typescript/ModuleView.ts +++ b/.creator/asset-template/typescript/ModuleView.ts @@ -9,7 +9,7 @@ const { ccclass, property } = _decorator; @ecs.register('<%Name%>', false) export class <%Name%>Comp extends CCComp { /** 视图层逻辑代码分离演示 */ - onLoad() { + start() { // var entity = this.ent as ecs.Entity; // ecs.Entity 可转为当前模块的具体实体对象 // this.on(ModuleEvent.Cmd, this.onHandler, this); } diff --git a/.creator/asset-template/typescript/ModuleViewVM.ts b/.creator/asset-template/typescript/ModuleViewVM.ts index 3274c4d..1377256 100644 --- a/.creator/asset-template/typescript/ModuleViewVM.ts +++ b/.creator/asset-template/typescript/ModuleViewVM.ts @@ -12,7 +12,7 @@ export class <%Name%>Comp extends CCVMParentComp { data: any = {}; /** 视图层逻辑代码分离演示 */ - onLoad() { + start() { // var entity = this.ent as ecs.Entity; // ecs.Entity 可转为当前模块的具体实体对象 } diff --git a/assets/main.scene b/assets/main.scene index a2a1958..f4030c5 100644 --- a/assets/main.scene +++ b/assets/main.scene @@ -460,7 +460,9 @@ "_diffuseMapLDR": null, "_enabled": false, "_useHDR": false, - "_editableMaterial": null + "_editableMaterial": null, + "_reflectionHDR": null, + "_reflectionLDR": null }, { "__type__": "cc.FogInfo", diff --git a/assets/script/game/initialize/bll/InitRes.ts b/assets/script/game/initialize/bll/InitRes.ts index d33a37a..ddc4dff 100644 --- a/assets/script/game/initialize/bll/InitRes.ts +++ b/assets/script/game/initialize/bll/InitRes.ts @@ -5,8 +5,8 @@ * @LastEditTime: 2022-07-22 17:09:30 */ import { resLoader } from "../../../../../extensions/oops-plugin-framework/assets/core/common/loader/ResLoader"; -import { AsyncQueue, NextFunction } from "../../../../../extensions/oops-plugin-framework/assets/libs/collection/AsyncQueue"; import { oops } from "../../../../../extensions/oops-plugin-framework/assets/core/Oops"; +import { AsyncQueue, NextFunction } from "../../../../../extensions/oops-plugin-framework/assets/libs/collection/AsyncQueue"; import { ecs } from "../../../../../extensions/oops-plugin-framework/assets/libs/ecs/ECS"; import { config } from "../../common/config/Config"; import { UIID } from "../../common/config/GameUIConfig"; @@ -42,9 +42,6 @@ export class InitResSystem extends ecs.ComblockSystem implements ecs.IEntityEnte /** 加载自定义内容(可选) */ private loadCustom(queue: AsyncQueue) { queue.push(async (next: NextFunction, params: any, args: any) => { - // 设置渠道号 - // if (config.query.channelId) SDKPlatform.setChannelId(config.query.channelId); - // 加载多语言对应字体 resLoader.load("language/font/" + oops.language.current, next); }); @@ -56,16 +53,15 @@ export class InitResSystem extends ecs.ComblockSystem implements ecs.IEntityEnte // 设置默认语言 let lan = oops.storage.get("language"); if (lan == null) { - // lan = SDKPlatform.getLanguage(); lan = "zh"; - oops.storage.set("language", lan!); + oops.storage.set("language", lan); } // 设置语言包路径 oops.language.setAssetsPath(config.game.languagePathJson, config.game.languagePathTexture); // 加载语言包资源 - oops.language.setLanguage(lan!, next); + oops.language.setLanguage(lan, next); }); }