From a6055ad8b4e9d653e8074d04fb28790f8d32a3c8 Mon Sep 17 00:00:00 2001 From: dgflash Date: Thu, 22 Sep 2022 14:58:47 +0800 Subject: [PATCH] . --- assets/script/game/initialize/bll/InitRes.ts | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/assets/script/game/initialize/bll/InitRes.ts b/assets/script/game/initialize/bll/InitRes.ts index ee2803a..16a7e44 100644 --- a/assets/script/game/initialize/bll/InitRes.ts +++ b/assets/script/game/initialize/bll/InitRes.ts @@ -2,10 +2,9 @@ * @Author: dgflash * @Date: 2022-07-22 17:06:22 * @LastEditors: dgflash - * @LastEditTime: 2022-08-05 10:16:40 + * @LastEditTime: 2022-09-22 14:41:58 */ -import { resLoader } from "../../../../../extensions/oops-plugin-framework/assets/core/common/loader/ResLoader"; 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"; @@ -44,7 +43,7 @@ export class InitResSystem extends ecs.ComblockSystem implements ecs.IEntityEnte private loadCustom(queue: AsyncQueue) { queue.push(async (next: NextFunction, params: any, args: any) => { // 加载多语言对应字体 - resLoader.load("language/font/" + oops.language.current, next); + oops.res.load("language/font/" + oops.language.current, next); }); } @@ -69,7 +68,7 @@ export class InitResSystem extends ecs.ComblockSystem implements ecs.IEntityEnte /** 加载公共资源(必备) */ private loadCommon(queue: AsyncQueue) { queue.push((next: NextFunction, params: any, args: any) => { - resLoader.loadDir("common", next); + oops.res.loadDir("common", next); }); } @@ -77,7 +76,7 @@ export class InitResSystem extends ecs.ComblockSystem implements ecs.IEntityEnte private onComplete(queue: AsyncQueue, e: Initialize) { queue.complete = async () => { var node = await oops.gui.openAsync(UIID.Loading); - if (node) e.add(node.getComponent(LoadingViewComp) as ecs.Comp); + if (node) e.add(node.getComponent(LoadingViewComp) as ecs.Comp); e.remove(InitResComp); }; }