From 5c3176d147f5bf48845251a9d35868cfe8511375 Mon Sep 17 00:00:00 2001 From: dgflash Date: Mon, 22 Sep 2025 16:56:04 +0800 Subject: [PATCH] =?UTF-8?q?=E8=87=AA=E5=8A=A8=E9=81=8D=E5=8E=86zip?= =?UTF-8?q?=E5=8C=85=E4=B8=AD=E7=9A=84json=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- assets/core/utils/JsonUtil.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/assets/core/utils/JsonUtil.ts b/assets/core/utils/JsonUtil.ts index 3e638d8..7985648 100644 --- a/assets/core/utils/JsonUtil.ts +++ b/assets/core/utils/JsonUtil.ts @@ -46,7 +46,7 @@ export class JsonUtil { content = await ZipLoader.getJson(pathZip, `${name}.json`); } else { - content = await resLoader.load(url, JsonAsset); + content = await resLoader.loadAsync(url, JsonAsset); } if (content) { @@ -71,6 +71,7 @@ export class JsonUtil { if (this.zip) { let zip = await ZipLoader.load(pathZip); for (let key in zip.files) { + let f = zip.files[key]; let name = key.replace(".json", ""); data.set(name, ZipLoader.getJson(pathZip, `${name}.json`)); }