From 2bde4ac72ead0db285c9e2578f6a9d5fc83250df Mon Sep 17 00:00:00 2001 From: JianMiau Date: Wed, 31 Aug 2022 09:48:48 +0800 Subject: [PATCH] =?UTF-8?q?[add]=20=E7=86=B1=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- JMKA - 捷徑.lnk | Bin 0 -> 996 bytes assets/Prefab.meta | 13 + assets/Prefab/UpdatePanel.prefab | 3027 ++++++++++++++++ assets/Prefab/UpdatePanel.prefab.meta | 9 + assets/Scene/Main.fire | 3033 ++++++++++++++++- assets/Script/HUD.meta | 13 + assets/Script/HUD/AssetBundleMamager.ts | 456 +++ assets/Script/HUD/AssetBundleMamager.ts.meta | 10 + assets/Script/HUD/Enum_HUDM.ts | 72 + assets/Script/HUD/Enum_HUDM.ts.meta | 10 + assets/Script/HUD/HUDM.ts | 353 ++ assets/Script/HUD/HUDM.ts.meta | 10 + assets/Script/Manager.ts | 33 +- assets/Script/UpdatePanel.ts | 73 + assets/Script/UpdatePanel.ts.meta | 10 + assets/Texture/UI.meta | 13 + assets/Texture/UI/chat.meta | 13 + assets/Texture/UI/chat/button_orange.png | Bin 0 -> 18969 bytes assets/Texture/UI/chat/button_orange.png.meta | 38 + assets/Texture/UI/chat/gb_inputbox.png | Bin 0 -> 2548 bytes assets/Texture/UI/chat/gb_inputbox.png.meta | 38 + assets/Texture/UI/new.meta | 13 + assets/Texture/UI/new/bg_rankinglist.png | Bin 0 -> 3765 bytes assets/Texture/UI/new/bg_rankinglist.png.meta | 38 + assets/Texture/UI/new/icon_back.png | Bin 0 -> 2290 bytes assets/Texture/UI/new/icon_back.png.meta | 38 + assets/Texture/UI/table.meta | 13 + assets/Texture/UI/table/bg_jinbishu.png | Bin 0 -> 1829 bytes assets/Texture/UI/table/bg_jinbishu.png.meta | 38 + .../res/values/strings.xml | 2 +- build-templates/jsb-default/main.js | 149 + hotupdate.bat | 29 + packages/hot-update-tools/CommonIssue.md | 35 + packages/hot-update-tools/README.md | 81 + packages/hot-update-tools/UPDATE.md | 27 + packages/hot-update-tools/core/CfgUtil.js | 128 + packages/hot-update-tools/core/FileUtil.js | 136 + packages/hot-update-tools/core/HttpService.js | 141 + packages/hot-update-tools/i18n/en.js | 3 + packages/hot-update-tools/i18n/zh.js | 3 + packages/hot-update-tools/mail/Mail.js | 57 + packages/hot-update-tools/mail/MailTemp.html | 6 + packages/hot-update-tools/main.js | 66 + packages/hot-update-tools/package-lock.json | 822 +++++ packages/hot-update-tools/package.json | 28 + packages/hot-update-tools/panel/index.css | 14 + packages/hot-update-tools/panel/index.html | 222 ++ packages/hot-update-tools/panel/index.js | 1236 +++++++ packages/hot-update-tools/panel/test.js | 0 .../hot-update-tools/test/TestEnvAli.html | 0 packages/hot-update-tools/test/TestEnvAli.js | 14 + packages/hot-update/main.js | 44 + packages/hot-update/package.json | 7 + remote-assets/project.manifest | 1 + remote-assets/version.manifest | 1 + tsconfig.json | 46 +- version_generator.js | 115 + 57 files changed, 10746 insertions(+), 31 deletions(-) create mode 100644 JMKA - 捷徑.lnk create mode 100644 assets/Prefab.meta create mode 100644 assets/Prefab/UpdatePanel.prefab create mode 100644 assets/Prefab/UpdatePanel.prefab.meta create mode 100644 assets/Script/HUD.meta create mode 100644 assets/Script/HUD/AssetBundleMamager.ts create mode 100644 assets/Script/HUD/AssetBundleMamager.ts.meta create mode 100644 assets/Script/HUD/Enum_HUDM.ts create mode 100644 assets/Script/HUD/Enum_HUDM.ts.meta create mode 100644 assets/Script/HUD/HUDM.ts create mode 100644 assets/Script/HUD/HUDM.ts.meta create mode 100644 assets/Script/UpdatePanel.ts create mode 100644 assets/Script/UpdatePanel.ts.meta create mode 100644 assets/Texture/UI.meta create mode 100644 assets/Texture/UI/chat.meta create mode 100644 assets/Texture/UI/chat/button_orange.png create mode 100644 assets/Texture/UI/chat/button_orange.png.meta create mode 100644 assets/Texture/UI/chat/gb_inputbox.png create mode 100644 assets/Texture/UI/chat/gb_inputbox.png.meta create mode 100644 assets/Texture/UI/new.meta create mode 100644 assets/Texture/UI/new/bg_rankinglist.png create mode 100644 assets/Texture/UI/new/bg_rankinglist.png.meta create mode 100644 assets/Texture/UI/new/icon_back.png create mode 100644 assets/Texture/UI/new/icon_back.png.meta create mode 100644 assets/Texture/UI/table.meta create mode 100644 assets/Texture/UI/table/bg_jinbishu.png create mode 100644 assets/Texture/UI/table/bg_jinbishu.png.meta create mode 100644 build-templates/jsb-default/main.js create mode 100644 hotupdate.bat create mode 100644 packages/hot-update-tools/CommonIssue.md create mode 100644 packages/hot-update-tools/README.md create mode 100644 packages/hot-update-tools/UPDATE.md create mode 100644 packages/hot-update-tools/core/CfgUtil.js create mode 100644 packages/hot-update-tools/core/FileUtil.js create mode 100644 packages/hot-update-tools/core/HttpService.js create mode 100644 packages/hot-update-tools/i18n/en.js create mode 100644 packages/hot-update-tools/i18n/zh.js create mode 100644 packages/hot-update-tools/mail/Mail.js create mode 100644 packages/hot-update-tools/mail/MailTemp.html create mode 100644 packages/hot-update-tools/main.js create mode 100644 packages/hot-update-tools/package-lock.json create mode 100644 packages/hot-update-tools/package.json create mode 100644 packages/hot-update-tools/panel/index.css create mode 100644 packages/hot-update-tools/panel/index.html create mode 100644 packages/hot-update-tools/panel/index.js create mode 100644 packages/hot-update-tools/panel/test.js create mode 100644 packages/hot-update-tools/test/TestEnvAli.html create mode 100644 packages/hot-update-tools/test/TestEnvAli.js create mode 100644 packages/hot-update/main.js create mode 100644 packages/hot-update/package.json create mode 100644 remote-assets/project.manifest create mode 100644 remote-assets/version.manifest create mode 100644 version_generator.js diff --git a/JMKA - 捷徑.lnk b/JMKA - 捷徑.lnk new file mode 100644 index 0000000000000000000000000000000000000000..4ddeadcf2d6d5b7f8654a116468d15de36a594fe GIT binary patch literal 996 zcmeZaU|?VrVFHp23FNW3@i-q_ni#+VI~#&!CDU}U%~-aghn(>o54`dkjjt*6c=I$KrzX;G8|}@4b-fR zpkxl&(0&7uS=(`%<;zgX5Dqm@gdqmSyr9(L{L-T2)M5q~sF~eC#{MufPvbN*2xwk0 zLq0<(LlHwVn9aZ-f#ho`psyVZ3gEt$3}xnlnX1f*=3zM3k)Z$xLB95byVAl!fWgbx z+mV663hF}1P*$K>YK9OnMfZ7;DfH)P1Wq=rx7=R2Q0P#J5SO+08`JYXaE2J literal 0 HcmV?d00001 diff --git a/assets/Prefab.meta b/assets/Prefab.meta new file mode 100644 index 0000000..8f066d5 --- /dev/null +++ b/assets/Prefab.meta @@ -0,0 +1,13 @@ +{ + "ver": "1.1.3", + "uuid": "a0181a7b-9c3d-4126-a012-acf5a1e095a2", + "importer": "folder", + "isBundle": false, + "bundleName": "", + "priority": 1, + "compressionType": {}, + "optimizeHotUpdate": {}, + "inlineSpriteFrames": {}, + "isRemoteBundle": {}, + "subMetas": {} +} \ No newline at end of file diff --git a/assets/Prefab/UpdatePanel.prefab b/assets/Prefab/UpdatePanel.prefab new file mode 100644 index 0000000..b3d7cc8 --- /dev/null +++ b/assets/Prefab/UpdatePanel.prefab @@ -0,0 +1,3027 @@ +[ + { + "__type__": "cc.Prefab", + "_name": "", + "_objFlags": 0, + "_native": "", + "data": { + "__id__": 1 + }, + "optimizationPolicy": 0, + "asyncLoadAssets": false, + "readonly": false + }, + { + "__type__": "cc.Node", + "_name": "UpdatePanel", + "_objFlags": 0, + "_parent": null, + "_children": [ + { + "__id__": 2 + }, + { + "__id__": 7 + } + ], + "_active": false, + "_components": [ + { + "__id__": 78 + } + ], + "_prefab": { + "__id__": 79 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 1080, + "height": 1920 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 0, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Node", + "_name": "background_mask", + "_objFlags": 0, + "_parent": { + "__id__": 1 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 3 + }, + { + "__id__": 4 + }, + { + "__id__": 5 + } + ], + "_prefab": { + "__id__": 6 + }, + "_opacity": 207.315, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 1080, + "height": 1920 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 0, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 2 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "7d1d4e60-aba2-48e8-85f8-8e328f34e7cc" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 2 + }, + "_enabled": true, + "alignMode": 0, + "_target": null, + "_alignFlags": 45, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 54, + "_originalHeight": 81, + "_id": "" + }, + { + "__type__": "cc.BlockInputEvents", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 2 + }, + "_enabled": true, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "70eAC2TBhG77Zid440sfQw", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "UpdatePanel", + "_objFlags": 0, + "_parent": { + "__id__": 1 + }, + "_children": [ + { + "__id__": 8 + }, + { + "__id__": 11 + }, + { + "__id__": 14 + }, + { + "__id__": 17 + }, + { + "__id__": 24 + }, + { + "__id__": 27 + }, + { + "__id__": 34 + }, + { + "__id__": 37 + }, + { + "__id__": 45 + }, + { + "__id__": 53 + }, + { + "__id__": 61 + }, + { + "__id__": 64 + }, + { + "__id__": 67 + } + ], + "_active": true, + "_components": [ + { + "__id__": 75 + }, + { + "__id__": 76 + } + ], + "_prefab": { + "__id__": 77 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 800, + "height": 600 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 0, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Node", + "_name": "close", + "_objFlags": 0, + "_parent": { + "__id__": 7 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 9 + } + ], + "_prefab": { + "__id__": 10 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 33, + "height": 48 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + -356, + 265, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 8 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "6035fac6-5208-4e0b-bea7-62ff9fb1338b" + }, + "_type": 0, + "_sizeMode": 1, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "95z/pNk5BFcIjDetW3Xmh/", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "update_title", + "_objFlags": 0, + "_parent": { + "__id__": 7 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 12 + } + ], + "_prefab": { + "__id__": 13 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 200, + "height": 50.4 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 267, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 11 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "热更新信息", + "_N$string": "热更新信息", + "_fontSize": 40, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 0, + "_N$cacheMode": 0, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "10TPMZ225IWp0DIbRtmztD", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "label1", + "_objFlags": 0, + "_parent": { + "__id__": 7 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 15 + } + ], + "_prefab": { + "__id__": 16 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 150, + "height": 40 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + -260, + 150, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 14 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "File", + "_N$string": "File", + "_fontSize": 40, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 1, + "_N$cacheMode": 0, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "3dXBzhLuhD+rVsRXn7AeDB", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "fileProgress", + "_objFlags": 0, + "_parent": { + "__id__": 7 + }, + "_children": [ + { + "__id__": 18 + } + ], + "_active": true, + "_components": [ + { + "__id__": 21 + }, + { + "__id__": 22 + } + ], + "_prefab": { + "__id__": 23 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 500, + "height": 40 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 80, + 150, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Node", + "_name": "bar", + "_objFlags": 0, + "_parent": { + "__id__": 17 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 19 + } + ], + "_prefab": { + "__id__": 20 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 0, + "height": 35 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + -250, + 1.8, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 18 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "7d1d4e60-aba2-48e8-85f8-8e328f34e7cc" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "6ewSs911dHoJBK1lf0wAuy", + "sync": false + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 17 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "022a80ab-4cde-42ca-9e04-8a23745cf138" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.ProgressBar", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 17 + }, + "_enabled": true, + "_N$totalLength": 500, + "_N$barSprite": { + "__id__": 19 + }, + "_N$mode": 0, + "_N$progress": 0, + "_N$reverse": false, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "92bEc/axFEKKzjy8vGjzxM", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "label2", + "_objFlags": 0, + "_parent": { + "__id__": 7 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 25 + } + ], + "_prefab": { + "__id__": 26 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 150, + "height": 40 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + -260, + 40, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 24 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "Byte", + "_N$string": "Byte", + "_fontSize": 40, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 1, + "_N$cacheMode": 0, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "79WgZNqCtLjI1gVSXEOjX0", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "byteProgress", + "_objFlags": 0, + "_parent": { + "__id__": 7 + }, + "_children": [ + { + "__id__": 28 + } + ], + "_active": true, + "_components": [ + { + "__id__": 31 + }, + { + "__id__": 32 + } + ], + "_prefab": { + "__id__": 33 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 500, + "height": 40 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 80, + 40, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Node", + "_name": "bar", + "_objFlags": 0, + "_parent": { + "__id__": 27 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 29 + } + ], + "_prefab": { + "__id__": 30 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 0, + "height": 35 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + -250, + 1.8, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 28 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "7d1d4e60-aba2-48e8-85f8-8e328f34e7cc" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "606FdJlO9Ka42ZO0jLg63R", + "sync": false + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 27 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "022a80ab-4cde-42ca-9e04-8a23745cf138" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.ProgressBar", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 27 + }, + "_enabled": true, + "_N$totalLength": 500, + "_N$barSprite": { + "__id__": 29 + }, + "_N$mode": 0, + "_N$progress": 0, + "_N$reverse": false, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "5fkUNH4BpIaqFx+pLNXaml", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "info", + "_objFlags": 0, + "_parent": { + "__id__": 7 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 35 + } + ], + "_prefab": { + "__id__": 36 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 600, + "height": 100 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + -111, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 34 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "", + "_N$string": "", + "_fontSize": 22, + "_lineHeight": 26, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 0, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 1, + "_N$cacheMode": 0, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "c0giTbIY1MIJBR4pC1KSgO", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "check_btn", + "_objFlags": 0, + "_parent": { + "__id__": 7 + }, + "_children": [ + { + "__id__": 38 + } + ], + "_active": true, + "_components": [ + { + "__id__": 41 + }, + { + "__id__": 42 + }, + { + "__id__": 43 + } + ], + "_prefab": { + "__id__": 44 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 250, + "height": 100 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + -160, + -220, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 0 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Node", + "_name": "Label", + "_objFlags": 0, + "_parent": { + "__id__": 37 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 39 + } + ], + "_prefab": { + "__id__": 40 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 120, + "height": 50.4 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 11, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 38 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "检查更新", + "_N$string": "检查更新", + "_fontSize": 30, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 0, + "_N$cacheMode": 0, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "edxS3BFDdMzZY8wWCpR+XE", + "sync": false + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 37 + }, + "_enabled": true, + "alignMode": 0, + "_target": null, + "_alignFlags": 0, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 37 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.Button", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 37 + }, + "_enabled": true, + "_normalMaterial": null, + "_grayMaterial": null, + "duration": 0.1, + "zoomScale": 0.8, + "clickEvents": [], + "_N$interactable": true, + "_N$enableAutoGrayEffect": false, + "_N$transition": 3, + "transition": 3, + "_N$normalColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$disabledColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$normalSprite": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_N$pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$disabledSprite": { + "__uuid__": "29158224-f8dd-4661-a796-1ffab537140e" + }, + "_N$target": { + "__id__": 37 + }, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "0cfnQnbnxDuKZuqJ5Lbv0t", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "update_btn", + "_objFlags": 0, + "_parent": { + "__id__": 7 + }, + "_children": [ + { + "__id__": 46 + } + ], + "_active": true, + "_components": [ + { + "__id__": 49 + }, + { + "__id__": 50 + }, + { + "__id__": 51 + } + ], + "_prefab": { + "__id__": 52 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 250, + "height": 100 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 160, + -220, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 0 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Node", + "_name": "Label", + "_objFlags": 0, + "_parent": { + "__id__": 45 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 47 + } + ], + "_prefab": { + "__id__": 48 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 120, + "height": 50.4 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 11, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 46 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "立即更新", + "_N$string": "立即更新", + "_fontSize": 30, + "_lineHeight": 40, + "_enableWrapText": false, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 0, + "_N$cacheMode": 0, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "71Orp+ih5BHrQfZ3vJK0u9", + "sync": false + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 45 + }, + "_enabled": true, + "alignMode": 0, + "_target": null, + "_alignFlags": 0, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 45 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.Button", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 45 + }, + "_enabled": true, + "_normalMaterial": null, + "_grayMaterial": null, + "duration": 0.1, + "zoomScale": 0.8, + "clickEvents": [], + "_N$interactable": true, + "_N$enableAutoGrayEffect": false, + "_N$transition": 3, + "transition": 3, + "_N$normalColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$disabledColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$normalSprite": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_N$pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$disabledSprite": { + "__uuid__": "29158224-f8dd-4661-a796-1ffab537140e" + }, + "_N$target": { + "__id__": 45 + }, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "c75HXFVy9B7pTqRUUPU3eA", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "retry_btn", + "_objFlags": 0, + "_parent": { + "__id__": 7 + }, + "_children": [ + { + "__id__": 54 + } + ], + "_active": false, + "_components": [ + { + "__id__": 57 + }, + { + "__id__": 58 + }, + { + "__id__": 59 + } + ], + "_prefab": { + "__id__": 60 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 250, + "height": 100 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 160, + -220, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Node", + "_name": "Label", + "_objFlags": 0, + "_parent": { + "__id__": 53 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 55 + } + ], + "_prefab": { + "__id__": 56 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 120, + "height": 40 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 11, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 54 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "重试更新", + "_N$string": "重试更新", + "_fontSize": 30, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 0, + "_N$cacheMode": 0, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "730uHK8jlLd4txnAxcZb0g", + "sync": false + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 53 + }, + "_enabled": true, + "alignMode": 1, + "_wasAlignOnce": {}, + "isAlignOnce": {}, + "_target": null, + "_alignFlags": 0, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 53 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.Button", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 53 + }, + "_enabled": true, + "_normalMaterial": null, + "_grayMaterial": null, + "duration": 0.1, + "zoomScale": 0.8, + "clickEvents": [], + "_N$interactable": true, + "_N$enableAutoGrayEffect": false, + "_N$transition": 3, + "transition": 3, + "_N$normalColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$disabledColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$normalSprite": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_N$pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$disabledSprite": { + "__uuid__": "29158224-f8dd-4661-a796-1ffab537140e" + }, + "_N$target": { + "__id__": 53 + }, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "f30tLL6exEybyfUkbH3eb5", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "filep", + "_objFlags": 0, + "_parent": { + "__id__": 7 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 62 + } + ], + "_prefab": { + "__id__": 63 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 150, + "height": 40 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 94, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 61 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "/", + "_N$string": "/", + "_fontSize": 40, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 1, + "_N$cacheMode": 0, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "5450pY1E9BkJmbBVh1AEJ0", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "bytep", + "_objFlags": 0, + "_parent": { + "__id__": 7 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 65 + } + ], + "_prefab": { + "__id__": 66 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 300, + "height": 40 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + -20, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 64 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "/", + "_N$string": "/", + "_fontSize": 28, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 1, + "_N$cacheMode": 0, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "d0EB2kVz1JNIVfS9WJE2Lw", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "update_btn", + "_objFlags": 0, + "_parent": { + "__id__": 7 + }, + "_children": [ + { + "__id__": 68 + } + ], + "_active": false, + "_components": [ + { + "__id__": 71 + }, + { + "__id__": 72 + }, + { + "__id__": 73 + } + ], + "_prefab": { + "__id__": 74 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 200, + "height": 60 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 260, + 266, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Node", + "_name": "Label", + "_objFlags": 0, + "_parent": { + "__id__": 67 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 69 + } + ], + "_prefab": { + "__id__": 70 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 140, + "height": 50.4 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 4, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 68 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "使用自定义配置", + "_N$string": "使用自定义配置", + "_fontSize": 20, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 0, + "_N$cacheMode": 0, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "6dIuP6RVJLXJovx7BMU02v", + "sync": false + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 67 + }, + "_enabled": true, + "alignMode": 0, + "_target": null, + "_alignFlags": 0, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 67 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.Button", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 67 + }, + "_enabled": true, + "_normalMaterial": null, + "_grayMaterial": null, + "duration": 0.1, + "zoomScale": 1.2, + "clickEvents": [], + "_N$interactable": true, + "_N$enableAutoGrayEffect": false, + "_N$transition": 0, + "transition": 0, + "_N$normalColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$disabledColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$normalSprite": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_N$pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$disabledSprite": { + "__uuid__": "29158224-f8dd-4661-a796-1ffab537140e" + }, + "_N$target": { + "__id__": 67 + }, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "belRJCQgZG273uhmea0wfb", + "sync": false + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 7 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "ca7dd73d-526a-4c85-9702-eb51e93b9d99" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "" + }, + { + "__type__": "86711tHE/ZKToqdDiTn/Kbn", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 7 + }, + "_enabled": true, + "info": { + "__id__": 35 + }, + "fileProgress": { + "__id__": 22 + }, + "fileLabel": { + "__id__": 62 + }, + "byteProgress": { + "__id__": 32 + }, + "byteLabel": { + "__id__": 65 + }, + "close": { + "__id__": 8 + }, + "checkBtn": { + "__id__": 37 + }, + "retryBtn": { + "__id__": 53 + }, + "updateBtn": { + "__id__": 45 + }, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "84wtdr8/dBoqjboCRy4not", + "sync": false + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 1 + }, + "_enabled": true, + "alignMode": 1, + "_target": null, + "_alignFlags": 9, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "", + "sync": false + } +] \ No newline at end of file diff --git a/assets/Prefab/UpdatePanel.prefab.meta b/assets/Prefab/UpdatePanel.prefab.meta new file mode 100644 index 0000000..7b00a3c --- /dev/null +++ b/assets/Prefab/UpdatePanel.prefab.meta @@ -0,0 +1,9 @@ +{ + "ver": "1.3.2", + "uuid": "9d9ca13a-071d-47f4-836c-a69d1045dc14", + "importer": "prefab", + "optimizationPolicy": "AUTO", + "asyncLoadAssets": false, + "readonly": false, + "subMetas": {} +} \ No newline at end of file diff --git a/assets/Scene/Main.fire b/assets/Scene/Main.fire index dac7a36..b8f8f23 100644 --- a/assets/Scene/Main.fire +++ b/assets/Scene/Main.fire @@ -17,7 +17,7 @@ "__id__": 2 } ], - "_active": true, + "_active": false, "_components": [], "_prefab": null, "_opacity": 255, @@ -76,18 +76,21 @@ }, { "__id__": 8 + }, + { + "__id__": 10 } ], "_active": true, "_components": [ { - "__id__": 10 + "__id__": 89 }, { - "__id__": 11 + "__id__": 90 }, { - "__id__": 12 + "__id__": 91 } ], "_prefab": null, @@ -322,9 +325,7 @@ }, "_enabled": true, "alignMode": 1, - "_target": { - "__id__": 2 - }, + "_target": null, "_alignFlags": 45, "_left": 0, "_right": 0, @@ -436,6 +437,3021 @@ "_atlas": null, "_id": "d9uP1ksCZCaai71lia08yU" }, + { + "__type__": "cc.Node", + "_name": "UpdatePanel", + "_objFlags": 0, + "_parent": { + "__id__": 2 + }, + "_children": [ + { + "__id__": 11 + }, + { + "__id__": 16 + } + ], + "_active": false, + "_components": [ + { + "__id__": 87 + } + ], + "_prefab": { + "__id__": 88 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 1080, + "height": 1920 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 0, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "40fjcW2WFOj5BFlUp2Da1e" + }, + { + "__type__": "cc.Node", + "_name": "background_mask", + "_objFlags": 0, + "_parent": { + "__id__": 10 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 12 + }, + { + "__id__": 13 + }, + { + "__id__": 14 + } + ], + "_prefab": { + "__id__": 15 + }, + "_opacity": 207.315, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 1080, + "height": 1920 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 0, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "deVknj90RAu4sER32HC9Ik" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 11 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "7d1d4e60-aba2-48e8-85f8-8e328f34e7cc" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "a5QP5T3X1Jl7Uc22Nn3I/g" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 11 + }, + "_enabled": true, + "alignMode": 0, + "_target": null, + "_alignFlags": 45, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 54, + "_originalHeight": 81, + "_id": "5aJ1aPWaBLEJWIGEZYgA0T" + }, + { + "__type__": "cc.BlockInputEvents", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 11 + }, + "_enabled": true, + "_id": "1dYaPTb8tCKoHCoFkeNwbA" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "70eAC2TBhG77Zid440sfQw", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "UpdatePanel", + "_objFlags": 0, + "_parent": { + "__id__": 10 + }, + "_children": [ + { + "__id__": 17 + }, + { + "__id__": 20 + }, + { + "__id__": 23 + }, + { + "__id__": 26 + }, + { + "__id__": 33 + }, + { + "__id__": 36 + }, + { + "__id__": 43 + }, + { + "__id__": 46 + }, + { + "__id__": 54 + }, + { + "__id__": 62 + }, + { + "__id__": 70 + }, + { + "__id__": 73 + }, + { + "__id__": 76 + } + ], + "_active": true, + "_components": [ + { + "__id__": 84 + }, + { + "__id__": 85 + } + ], + "_prefab": { + "__id__": 86 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 800, + "height": 600 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 0, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "64FXGb5h5LJYSA76bvIEfw" + }, + { + "__type__": "cc.Node", + "_name": "close", + "_objFlags": 0, + "_parent": { + "__id__": 16 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 18 + } + ], + "_prefab": { + "__id__": 19 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 33, + "height": 48 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + -356, + 265, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "72LqCnIKJOdaJv9IF5hc6b" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 17 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "6035fac6-5208-4e0b-bea7-62ff9fb1338b" + }, + "_type": 0, + "_sizeMode": 1, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "1doAosBK5LXasv1bLHJuBm" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "95z/pNk5BFcIjDetW3Xmh/", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "update_title", + "_objFlags": 0, + "_parent": { + "__id__": 16 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 21 + } + ], + "_prefab": { + "__id__": 22 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 200, + "height": 50.4 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 267, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "fdAb95M2tNqJKqeTnVFhpy" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 20 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "热更新信息", + "_N$string": "热更新信息", + "_fontSize": 40, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 0, + "_N$cacheMode": 0, + "_id": "eeegQlqT5KB4D0iuqxaSgo" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "10TPMZ225IWp0DIbRtmztD", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "label1", + "_objFlags": 0, + "_parent": { + "__id__": 16 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 24 + } + ], + "_prefab": { + "__id__": 25 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 150, + "height": 40 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + -260, + 150, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "fecWSXN0NB8KCrCXqCqqZQ" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 23 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "File", + "_N$string": "File", + "_fontSize": 40, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 1, + "_N$cacheMode": 0, + "_id": "87KY3bfBtGMKHqNh3n8Iie" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "3dXBzhLuhD+rVsRXn7AeDB", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "fileProgress", + "_objFlags": 0, + "_parent": { + "__id__": 16 + }, + "_children": [ + { + "__id__": 27 + } + ], + "_active": true, + "_components": [ + { + "__id__": 30 + }, + { + "__id__": 31 + } + ], + "_prefab": { + "__id__": 32 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 500, + "height": 40 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 80, + 150, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "874avuTGZMdoNGvtvkGTUg" + }, + { + "__type__": "cc.Node", + "_name": "bar", + "_objFlags": 0, + "_parent": { + "__id__": 26 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 28 + } + ], + "_prefab": { + "__id__": 29 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 0, + "height": 35 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + -250, + 1.8, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "78lYmtW1NA+LsHtyfRRm1x" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 27 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "7d1d4e60-aba2-48e8-85f8-8e328f34e7cc" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "1dYw8JUaBKeJMwvuphmdx2" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "6ewSs911dHoJBK1lf0wAuy", + "sync": false + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 26 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "022a80ab-4cde-42ca-9e04-8a23745cf138" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "f3PZg/fRVLwZ1Siji3QOhe" + }, + { + "__type__": "cc.ProgressBar", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 26 + }, + "_enabled": true, + "_N$totalLength": 500, + "_N$barSprite": { + "__id__": 28 + }, + "_N$mode": 0, + "_N$progress": 0, + "_N$reverse": false, + "_id": "0bWOc4EapPOqt5c5YR9dWP" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "92bEc/axFEKKzjy8vGjzxM", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "label2", + "_objFlags": 0, + "_parent": { + "__id__": 16 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 34 + } + ], + "_prefab": { + "__id__": 35 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 150, + "height": 40 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + -260, + 40, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "78NjAtPyRNI6WS3RDJkkB5" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 33 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "Byte", + "_N$string": "Byte", + "_fontSize": 40, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 1, + "_N$cacheMode": 0, + "_id": "c1TpFTPbhPG49Ei52LPrPR" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "79WgZNqCtLjI1gVSXEOjX0", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "byteProgress", + "_objFlags": 0, + "_parent": { + "__id__": 16 + }, + "_children": [ + { + "__id__": 37 + } + ], + "_active": true, + "_components": [ + { + "__id__": 40 + }, + { + "__id__": 41 + } + ], + "_prefab": { + "__id__": 42 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 500, + "height": 40 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 80, + 40, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "70dwuj9L9F/43S4G2i/dWE" + }, + { + "__type__": "cc.Node", + "_name": "bar", + "_objFlags": 0, + "_parent": { + "__id__": 36 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 38 + } + ], + "_prefab": { + "__id__": 39 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 0, + "height": 35 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + -250, + 1.8, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "292QnsVTBEzbJi9DEqi8TE" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 37 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "7d1d4e60-aba2-48e8-85f8-8e328f34e7cc" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "eeScIZVm1BNJE2wpSv/JaF" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "606FdJlO9Ka42ZO0jLg63R", + "sync": false + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 36 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "022a80ab-4cde-42ca-9e04-8a23745cf138" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "45X9U/zclOg6JFMnQSF+HQ" + }, + { + "__type__": "cc.ProgressBar", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 36 + }, + "_enabled": true, + "_N$totalLength": 500, + "_N$barSprite": { + "__id__": 38 + }, + "_N$mode": 0, + "_N$progress": 0, + "_N$reverse": false, + "_id": "c7QbxZHV9OOIbAbLM0/ozs" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "5fkUNH4BpIaqFx+pLNXaml", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "info", + "_objFlags": 0, + "_parent": { + "__id__": 16 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 44 + } + ], + "_prefab": { + "__id__": 45 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 600, + "height": 100 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + -111, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "d9yO/MVzVN8rPR5mZkXmNM" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 43 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "", + "_N$string": "", + "_fontSize": 22, + "_lineHeight": 26, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 0, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 1, + "_N$cacheMode": 0, + "_id": "12p1X0HpBJDohSbDpfPq/J" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "c0giTbIY1MIJBR4pC1KSgO", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "check_btn", + "_objFlags": 0, + "_parent": { + "__id__": 16 + }, + "_children": [ + { + "__id__": 47 + } + ], + "_active": true, + "_components": [ + { + "__id__": 50 + }, + { + "__id__": 51 + }, + { + "__id__": 52 + } + ], + "_prefab": { + "__id__": 53 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 250, + "height": 100 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + -160, + -220, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 0 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "23XSylaURGHK32E2zYZud2" + }, + { + "__type__": "cc.Node", + "_name": "Label", + "_objFlags": 0, + "_parent": { + "__id__": 46 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 48 + } + ], + "_prefab": { + "__id__": 49 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 120, + "height": 50.4 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 11, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "ac82HCWnNILYt8N+ty1Ulg" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 47 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "检查更新", + "_N$string": "检查更新", + "_fontSize": 30, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 0, + "_N$cacheMode": 0, + "_id": "62jiYwlj9MCK8c1tGlcka5" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "edxS3BFDdMzZY8wWCpR+XE", + "sync": false + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 46 + }, + "_enabled": true, + "alignMode": 0, + "_target": null, + "_alignFlags": 0, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_id": "88tC7Bd9RMAYgjGiE4OxQO" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 46 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "f4JTvkD+ZIMY35VJcUFvWt" + }, + { + "__type__": "cc.Button", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 46 + }, + "_enabled": true, + "_normalMaterial": null, + "_grayMaterial": null, + "duration": 0.1, + "zoomScale": 0.8, + "clickEvents": [], + "_N$interactable": true, + "_N$enableAutoGrayEffect": false, + "_N$transition": 3, + "transition": 3, + "_N$normalColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$disabledColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$normalSprite": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_N$pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$disabledSprite": { + "__uuid__": "29158224-f8dd-4661-a796-1ffab537140e" + }, + "_N$target": { + "__id__": 46 + }, + "_id": "bcDHLqpsNFjJUWvP050NtF" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "0cfnQnbnxDuKZuqJ5Lbv0t", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "update_btn", + "_objFlags": 0, + "_parent": { + "__id__": 16 + }, + "_children": [ + { + "__id__": 55 + } + ], + "_active": true, + "_components": [ + { + "__id__": 58 + }, + { + "__id__": 59 + }, + { + "__id__": 60 + } + ], + "_prefab": { + "__id__": 61 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 250, + "height": 100 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 160, + -220, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 0 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "05PhqPPg9O64eJgqAXTEh9" + }, + { + "__type__": "cc.Node", + "_name": "Label", + "_objFlags": 0, + "_parent": { + "__id__": 54 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 56 + } + ], + "_prefab": { + "__id__": 57 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 120, + "height": 50.4 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 11, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "07BCBeUbhAj5GeDty8FRI1" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 55 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "立即更新", + "_N$string": "立即更新", + "_fontSize": 30, + "_lineHeight": 40, + "_enableWrapText": false, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 0, + "_N$cacheMode": 0, + "_id": "c9tlunNn5PGp9f0Vwb58dM" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "71Orp+ih5BHrQfZ3vJK0u9", + "sync": false + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 54 + }, + "_enabled": true, + "alignMode": 0, + "_target": null, + "_alignFlags": 0, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_id": "dftDaIDDlGno8RLRsBDn4N" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 54 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "fc59NXZUxHZKVWjaI093bc" + }, + { + "__type__": "cc.Button", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 54 + }, + "_enabled": true, + "_normalMaterial": null, + "_grayMaterial": null, + "duration": 0.1, + "zoomScale": 0.8, + "clickEvents": [], + "_N$interactable": true, + "_N$enableAutoGrayEffect": false, + "_N$transition": 3, + "transition": 3, + "_N$normalColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$disabledColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$normalSprite": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_N$pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$disabledSprite": { + "__uuid__": "29158224-f8dd-4661-a796-1ffab537140e" + }, + "_N$target": { + "__id__": 54 + }, + "_id": "966/PPPZ1A8JJhn0XlM7dc" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "c75HXFVy9B7pTqRUUPU3eA", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "retry_btn", + "_objFlags": 0, + "_parent": { + "__id__": 16 + }, + "_children": [ + { + "__id__": 63 + } + ], + "_active": false, + "_components": [ + { + "__id__": 66 + }, + { + "__id__": 67 + }, + { + "__id__": 68 + } + ], + "_prefab": { + "__id__": 69 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 250, + "height": 100 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 160, + -220, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "19YLA0tnFKj4XlgeCoJlu6" + }, + { + "__type__": "cc.Node", + "_name": "Label", + "_objFlags": 0, + "_parent": { + "__id__": 62 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 64 + } + ], + "_prefab": { + "__id__": 65 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 120, + "height": 40 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 11, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "22HBUcWfRG7IPjNlIWa/Lt" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 63 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "重试更新", + "_N$string": "重试更新", + "_fontSize": 30, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 0, + "_N$cacheMode": 0, + "_id": "b1vyFi8ahIrL++NxLU4NCZ" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "730uHK8jlLd4txnAxcZb0g", + "sync": false + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 62 + }, + "_enabled": true, + "alignMode": 1, + "_wasAlignOnce": {}, + "isAlignOnce": {}, + "_target": null, + "_alignFlags": 0, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_id": "dbjJmYT/tLHYtUZ4YuPgvy" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 62 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "c5GHcgPU5MSZmrpXFEPZMv" + }, + { + "__type__": "cc.Button", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 62 + }, + "_enabled": true, + "_normalMaterial": null, + "_grayMaterial": null, + "duration": 0.1, + "zoomScale": 0.8, + "clickEvents": [], + "_N$interactable": true, + "_N$enableAutoGrayEffect": false, + "_N$transition": 3, + "transition": 3, + "_N$normalColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$disabledColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$normalSprite": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_N$pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$disabledSprite": { + "__uuid__": "29158224-f8dd-4661-a796-1ffab537140e" + }, + "_N$target": { + "__id__": 62 + }, + "_id": "1cdGS9O5pOcbq2g+uxp1VX" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "f30tLL6exEybyfUkbH3eb5", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "filep", + "_objFlags": 0, + "_parent": { + "__id__": 16 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 71 + } + ], + "_prefab": { + "__id__": 72 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 150, + "height": 40 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 94, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "bfgVdFcydLAaCDssh/mvYF" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 70 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "/", + "_N$string": "/", + "_fontSize": 40, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 1, + "_N$cacheMode": 0, + "_id": "eceJbggI1KxqqkKtPR1V/u" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "5450pY1E9BkJmbBVh1AEJ0", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "bytep", + "_objFlags": 0, + "_parent": { + "__id__": 16 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 74 + } + ], + "_prefab": { + "__id__": 75 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 300, + "height": 40 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + -20, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "c1M2yPppROlae60c1u886u" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 73 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "/", + "_N$string": "/", + "_fontSize": 28, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 1, + "_N$cacheMode": 0, + "_id": "f3+R3UhVVAWY0StYE4LSDv" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "d0EB2kVz1JNIVfS9WJE2Lw", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "update_btn", + "_objFlags": 0, + "_parent": { + "__id__": 16 + }, + "_children": [ + { + "__id__": 77 + } + ], + "_active": false, + "_components": [ + { + "__id__": 80 + }, + { + "__id__": 81 + }, + { + "__id__": 82 + } + ], + "_prefab": { + "__id__": 83 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 200, + "height": 60 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 260, + 266, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "aaa6aEwLNEypywq9+1uRLT" + }, + { + "__type__": "cc.Node", + "_name": "Label", + "_objFlags": 0, + "_parent": { + "__id__": 76 + }, + "_children": [], + "_active": true, + "_components": [ + { + "__id__": 78 + } + ], + "_prefab": { + "__id__": 79 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 140, + "height": 50.4 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_trs": { + "__type__": "TypedArray", + "ctor": "Float64Array", + "array": [ + 0, + 4, + 0, + 0, + 0, + 0, + 1, + 1, + 1, + 1 + ] + }, + "_eulerAngles": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_skewX": 0, + "_skewY": 0, + "_is3DNode": false, + "_groupIndex": 0, + "groupIndex": 0, + "_id": "9cpKQ6XmBB6Jjn514RJgEF" + }, + { + "__type__": "cc.Label", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 77 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_string": "使用自定义配置", + "_N$string": "使用自定义配置", + "_fontSize": 20, + "_lineHeight": 40, + "_enableWrapText": true, + "_N$file": null, + "_isSystemFontUsed": true, + "_spacingX": 0, + "_batchAsBitmap": false, + "_styleFlags": 0, + "_underlineHeight": 0, + "_N$horizontalAlign": 1, + "_N$verticalAlign": 1, + "_N$fontFamily": "Arial", + "_N$overflow": 0, + "_N$cacheMode": 0, + "_id": "0a4sB05RdMz55xfzw3G7kb" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "6dIuP6RVJLXJovx7BMU02v", + "sync": false + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 76 + }, + "_enabled": true, + "alignMode": 0, + "_target": null, + "_alignFlags": 0, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_id": "c4wWoTd2tHa7C61JxW7pQm" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 76 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "f1K5mPrBFBAZ9mcQXW6w3j" + }, + { + "__type__": "cc.Button", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 76 + }, + "_enabled": true, + "_normalMaterial": null, + "_grayMaterial": null, + "duration": 0.1, + "zoomScale": 1.2, + "clickEvents": [], + "_N$interactable": true, + "_N$enableAutoGrayEffect": false, + "_N$transition": 0, + "transition": 0, + "_N$normalColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "pressedColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$disabledColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$normalSprite": { + "__uuid__": "c01466ea-7283-4fce-b615-4ee78c774af0" + }, + "_N$pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "pressedSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "hoverSprite": { + "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" + }, + "_N$disabledSprite": { + "__uuid__": "29158224-f8dd-4661-a796-1ffab537140e" + }, + "_N$target": { + "__id__": 76 + }, + "_id": "e9E2QuFXlGjrUXqxtzG49G" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "belRJCQgZG273uhmea0wfb", + "sync": false + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 16 + }, + "_enabled": true, + "_materials": [ + { + "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" + } + ], + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "ca7dd73d-526a-4c85-9702-eb51e93b9d99" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_atlas": null, + "_id": "8aZKLYrhVOSbNb651gNGyC" + }, + { + "__type__": "86711tHE/ZKToqdDiTn/Kbn", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 16 + }, + "_enabled": true, + "info": { + "__id__": 44 + }, + "fileProgress": { + "__id__": 31 + }, + "fileLabel": { + "__id__": 71 + }, + "byteProgress": { + "__id__": 41 + }, + "byteLabel": { + "__id__": 74 + }, + "close": { + "__id__": 17 + }, + "checkBtn": { + "__id__": 46 + }, + "retryBtn": { + "__id__": 62 + }, + "updateBtn": { + "__id__": 54 + }, + "_id": "464T+AWcJLnIIROL7trTEC" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "84wtdr8/dBoqjboCRy4not", + "sync": false + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 10 + }, + "_enabled": true, + "alignMode": 1, + "_target": null, + "_alignFlags": 9, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_id": "61PygungNH4Iusse4dVSZC" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 10 + }, + "asset": { + "__uuid__": "9d9ca13a-071d-47f4-836c-a69d1045dc14" + }, + "fileId": "", + "sync": false + }, { "__type__": "cc.Canvas", "_name": "", @@ -494,6 +3510,9 @@ "BG": { "__id__": 8 }, + "UpdatePanel": { + "__id__": 10 + }, "_id": "b3AScs1lVP7ruEGNmMEKXU" } ] \ No newline at end of file diff --git a/assets/Script/HUD.meta b/assets/Script/HUD.meta new file mode 100644 index 0000000..2842afd --- /dev/null +++ b/assets/Script/HUD.meta @@ -0,0 +1,13 @@ +{ + "ver": "1.1.3", + "uuid": "b4db1c37-7356-4f88-ba5c-9ea4e86a85b7", + "importer": "folder", + "isBundle": false, + "bundleName": "", + "priority": 1, + "compressionType": {}, + "optimizeHotUpdate": {}, + "inlineSpriteFrames": {}, + "isRemoteBundle": {}, + "subMetas": {} +} \ No newline at end of file diff --git a/assets/Script/HUD/AssetBundleMamager.ts b/assets/Script/HUD/AssetBundleMamager.ts new file mode 100644 index 0000000..7a83dff --- /dev/null +++ b/assets/Script/HUD/AssetBundleMamager.ts @@ -0,0 +1,456 @@ +// import BusinessTypeSetting from "../../_BusinessTypeSetting/BusinessTypeSetting"; +// import LocalStorageData from "../Data/LocalStorageData"; +// import Enum_Loading from "../HUDV2/Enum_Loading"; +// import HUDM from "./HUDM"; + +// export default class AssetBundleMamager { +// //#region static 屬性 + +// private static _instance: AssetBundleMamager = null; +// public static get Instance(): AssetBundleMamager { return AssetBundleMamager._instance; } + +// //#endregion + +// //#region public 屬性 + +// public HUGroup: Map = new Map(); + +// /** 本地VerList */ +// public LocalVerList: Enum_Loading.VerListObj = null; + +// /** 遠端VerList */ +// public RemoteVerList: Enum_Loading.VerListObj = null; + +// public DownloadList_Preview: Object = {}; + +// /** IsChangeBundleUrl */ +// public IsChangeBundleUrl: boolean = false; + +// //#endregion + +// //#region Lifecycle + +// constructor() { +// AssetBundleMamager._instance = this; +// CC_PREVIEW && this._initdownloadList_Preview(); +// } + +// //#endregion + +// //#region Custom Function + +// /** +// * 取得Bundle +// * @param {string} BundleName Bundle名稱 +// * @param {string} Version 版號 +// * @return {cc.AssetManager.Bundle} Bundle +// */ +// public *GetBundle(BundleName: string, Version: string = ""): IterableIterator { +// let bundle: cc.AssetManager.Bundle = cc.assetManager.getBundle(BundleName); +// if (bundle) { +// return bundle; +// } + +// // options是可选参数,引擎会根据保留字段 进行对应的操作,这里添加了version和onFileProgress,可用来记录热更资源版本和下载进度 +// let options: any = null; + +// let BundleUrl: string = BundleName; +// if (cc.sys.isNative && !this.LocalVerList[BundleName].UseLocal) { +// BundleUrl = `${(jsb.fileUtils ? jsb.fileUtils.getWritablePath() : "/")}Bundle/${BundleName}/remote/${BundleName}`; +// options = { +// version: Version +// }; +// } + +// cc.assetManager.loadBundle(BundleUrl, options, (err: Error, resp: cc.AssetManager.Bundle) => { +// if (err) { +// cc.error(err); +// bundle = null; +// } +// bundle = resp; +// }); +// while (typeof bundle === "undefined") { +// yield null; +// } + +// return bundle; +// } + +// /** +// * 更新Bundle +// * @param {HUDM} HUDName HUD +// */ +// public *UpdateBundle(HUDName: HUDM | string, onFileProgress?: (finish: number, total: number, item: string) => void): IterableIterator { +// let HUD: HUDM; +// if (HUDName instanceof HUDM) { +// HUD = HUDName; +// } else { +// HUD = this.GetHUD(HUDName); +// } +// let UpdateingData: Enum_Loading.UpdateingDataObj = yield* HUD.HUD(onFileProgress); +// if (UpdateingData.IsUpdatecomplete) { +// this.LocalVerList[HUD.BundleName] = this.RemoteVerList[HUD.BundleName]; +// this.LocalVerList[HUD.BundleName]["UseLocal"] = false; +// LocalStorageData.Instance.LocalVerList = JSON.stringify(this.LocalVerList); +// } +// return UpdateingData; +// } + +// /** +// * 更新Bundle +// * @param {HUDM} HUDName HUD +// */ +// public *RetryUpdateBundle(HUDName: HUDM | string, onFileProgress?: (finish: number, total: number, item: string) => void): IterableIterator { +// let HUD: HUDM; +// if (HUDName instanceof HUDM) { +// HUD = HUDName; +// } else { +// HUD = this.GetHUD(HUDName); +// } +// let UpdateingData: Enum_Loading.UpdateingDataObj = yield* HUD.RetryDownLoadFailedAssets(); +// return UpdateingData; +// } + +// /** +// * 從Bundle取得資源 +// * @param {cc.AssetManager.Bundle | string} BundleName Bundle名稱 +// * @param {string} SourceName 資源名稱 +// * @param {string} type 資源型別 +// * @return {any} Source +// */ +// public *GetBundleSource(BundleName: cc.AssetManager.Bundle | string, SourceName: string, type?: string | Bundle_Source_Type, onFileProgress?: (finish: number, total: number, item: cc.AssetManager.RequestItem) => void): IterableIterator { +// let bundle: cc.AssetManager.Bundle; +// let source: any; +// if (BundleName instanceof cc.AssetManager.Bundle) { +// bundle = BundleName; +// } else { +// bundle = cc.assetManager.getBundle(BundleName); +// if (!bundle) { +// cc.error(`GetBundleSource Error BundleName: ${BundleName}`); +// return null; +// } +// } + +// switch (type) { +// case Bundle_Source_Type.Scene: { +// bundle.loadScene(SourceName, onFileProgress, function (err: Error, scene: cc.SceneAsset): void { +// if (err) { +// cc.error(err); +// return null; +// } +// // cc.director.runScene(scene); +// source = scene; +// }); +// break; +// } + +// case Bundle_Source_Type.Json: { +// bundle.load(SourceName, onFileProgress, function (err: Error, json: cc.JsonAsset): void { +// if (err) { +// cc.error(err); +// return null; +// } +// // source = JSON.parse(json["_nativeAsset"]); +// source = json; +// }); +// break; +// } + +// case Bundle_Source_Type.Prefab: { +// bundle.load(SourceName, cc.Prefab, onFileProgress, function (err: Error, prefab: cc.Asset): void { +// if (err) { +// cc.error(err); +// return null; +// } +// // source = JSON.parse(json["_nativeAsset"]); +// source = prefab; +// }); +// break; +// } + +// default: +// bundle.load(SourceName, function (err: Error, any: any): void { +// if (err) { +// cc.error(err); +// return null; +// } +// source = any; +// }); +// break; +// } + +// while (typeof source === "undefined") { +// yield null; +// } +// return source; +// } + +// /** +// * 釋放Bundle +// * @param {string} slotID slotID +// */ +// public *BundleRelease(slotID: number): IterableIterator { +// let gameName: string = `Game_${slotID}`; +// let sceneName: string = `Slot${slotID}`; +// let bundle: cc.AssetManager.Bundle = cc.assetManager.getBundle(gameName); +// if (!bundle) { +// cc.log(`BundleRelease Error BundleName: ${gameName}`); +// return; +// } + +// // let bundles: cc.AssetManager.Cache = cc.assetManager.bundles; +// // let cacheDir: string = cc.assetManager.cacheManager.cacheDir; +// // let cachedFiles: Object = cc.assetManager.cacheManager.cachedFiles; + +// yield* this.DelBundleCache(bundle); +// yield* this.DelOthersCache(slotID); +// bundle.release(sceneName, cc.SceneAsset); +// cc.assetManager.removeBundle(bundle); +// cc.sys.garbageCollect(); +// } + +// /** +// * 從Bundle刪除暫存資源 +// * @param {string} BundleName Bundle名稱 +// */ +// public *DelBundleCache(BundleName: cc.AssetManager.Bundle | string): IterableIterator { +// if (!CC_JSB) { +// return; +// } +// let bundle: cc.AssetManager.Bundle; +// let source: any; +// if (BundleName instanceof cc.AssetManager.Bundle) { +// bundle = BundleName; +// } else { +// bundle = cc.assetManager.getBundle(BundleName); +// if (!bundle) { +// // cc.error(`GetBundleSource Error BundleName: ${BundleName}`); +// // return; +// bundle = yield* AssetBundleMamager.Instance.GetBundle(BundleName, this.RemoteVerList[BundleName].Version); +// } +// } + +// let _map: Object = bundle["_config"].assetInfos._map; +// for (let map of Object.keys(_map)) { +// let path: string = _map[map].path; +// if (!path) { +// break; +// } +// source = yield* AssetBundleMamager.Instance.GetBundleSource(bundle, path); +// cc.assetManager.cacheManager.removeCache(source.nativeUrl); +// bundle.release(path); +// // return; +// } +// } + +// /** +// * 從cachedFiles刪除暫存資源 +// * @param {number} slotID slotID +// */ +// public *DelOthersCache(slotID: number): IterableIterator { +// if (!CC_JSB) { +// return; +// } +// let cachedFiles: Object = cc.assetManager.cacheManager.cachedFiles["_map"]; +// let delcache_group: string[] = [`shared/jsons`, `Slot/Slot${slotID}`, "sounds/Slot/Default", `${BusinessTypeSetting.FolderUrlBundle}project.manifest`, "submit.txt"]; +// for (let cached of Object.keys(cachedFiles)) { +// for (var i: number = 0; i < delcache_group.length; ++i) { +// let delcache: string = delcache_group[i]; +// if (cached.includes(delcache)) { +// cc.assetManager.cacheManager.removeCache(cached); +// // console.log(`removeCache: ${cached}`); +// break; +// } +// } +// } +// } + +// public GetHUD(BundleName: HUDM | string): HUDM { +// let HUD: HUDM; +// if (BundleName instanceof HUDM) { +// HUD = BundleName; +// } else { +// if (!this.HUGroup.has(BundleName)) { +// HUD = new HUDM(BundleName); +// this.HUGroup.set(BundleName, HUD); +// } else { +// HUD = this.HUGroup.get(BundleName); +// } +// HUD = this.HUGroup.get(BundleName); +// } +// return HUD; +// } + +// /** 刪除全部暫存資源 */ +// public ClearAllCache(): void { +// cc.assetManager.cacheManager.clearCache(); +// cc.game.restart(); +// } + + +// public *CheckBundleNeedHUD(BundleName: HUDM | string): IterableIterator { +// let HUD: HUDM; +// if (BundleName instanceof HUDM) { +// HUD = BundleName; +// } else { +// HUD = this.GetHUD(BundleName); +// } +// if (!this.LocalVerList[HUD.BundleName]) { +// this.LocalVerList[HUD.BundleName] = new Enum_Loading.BundleDataObj(); +// let apkVersion: string = this.RemoteVerList[HUD.BundleName].ApkVersion; +// if (apkVersion && apkVersion !== "0") { +// this.LocalVerList[HUD.BundleName].UseLocal = true; +// this.LocalVerList[HUD.BundleName].Version = apkVersion; +// } +// LocalStorageData.Instance.LocalVerList = JSON.stringify(this.LocalVerList); +// } else { +// if (this.RemoteVerList[HUD.BundleName].Version === this.RemoteVerList[HUD.BundleName].ApkVersion) { +// this.LocalVerList[HUD.BundleName] = this.RemoteVerList[HUD.BundleName]; +// this.LocalVerList[HUD.BundleName].UseLocal = true; +// } +// } +// let UpdateData: Enum_Loading.NeedUpdateDataObj = new Enum_Loading.NeedUpdateDataObj(); +// if (this.LocalVerList[HUD.BundleName].UseLocal) { +// UpdateData.IsNeedUpdate = AssetBundleMamager.Instance.versionCompareHandle(this.LocalVerList[HUD.BundleName].Version, this.RemoteVerList[HUD.BundleName].Version) < 0 ? true : false; +// if (UpdateData.IsNeedUpdate) { +// UpdateData = yield* HUD.CheckUpdate(); +// } +// } else { +// UpdateData = yield* HUD.CheckUpdate(); +// } +// return UpdateData; +// } + +// // public *CheckBundleNeedHUD(BundleName: string): IterableIterator { +// // if (!this.LocalVerList[BundleName]) { +// // this.LocalVerList[BundleName] = new Enum_Loading.BundleDataObj(); +// // let apkVersion: string = this.RemoteVerList[BundleName].ApkVersion; +// // if (apkVersion && apkVersion !== "0") { +// // this.LocalVerList[BundleName].UseLocal = true; +// // this.LocalVerList[BundleName].Version = apkVersion; +// // } +// // LocalStorageData.Instance.LocalVerList = JSON.stringify(this.LocalVerList); +// // } +// // let IsUpdate: boolean = AssetBundleMamager.Instance.versionCompareHandle(this.LocalVerList[BundleName].Version, this.RemoteVerList[BundleName].Version) < 0 ? true : false; +// // return IsUpdate; +// // } + +// public CheckGameNeedUpdate(GameID: number): boolean { +// let IsUpdate: boolean = false; +// let bundleName: string = `Game_${GameID}`; +// if (!this.RemoteVerList[bundleName]) { +// this.RemoteVerList[bundleName] = new Enum_Loading.BundleDataObj(); +// this.RemoteVerList[bundleName].HasBundle = false; +// LocalStorageData.Instance.RemoteVerList = JSON.stringify(this.RemoteVerList); +// IsUpdate = true; +// } +// if (!this.LocalVerList[bundleName]) { +// this.LocalVerList[bundleName] = new Enum_Loading.BundleDataObj(); +// let apkVersion: string = this.RemoteVerList[bundleName].ApkVersion; +// if (apkVersion && apkVersion !== "0") { +// this.LocalVerList[bundleName].UseLocal = true; +// this.LocalVerList[bundleName].Version = apkVersion; +// } +// LocalStorageData.Instance.LocalVerList = JSON.stringify(this.LocalVerList); +// } +// if (CC_PREVIEW) { +// return this._getIsDownload_Preview(GameID); +// } +// if (IsUpdate) { +// return IsUpdate; +// } +// IsUpdate = AssetBundleMamager.Instance.versionCompareHandle(this.LocalVerList[bundleName].Version, this.RemoteVerList[bundleName].Version) < 0 ? true : false; +// return IsUpdate; +// } + +// /** +// * 比對版號(熱更能從1.0.0更新到2.0.0,從2.0.0回退到1.0.0) +// * 官方提供的版本比較函數,只有服務端版本>客戶端版本時,才會進行更新。所以不能從2.0.0回退到1.0.0版本。 +// * @param {string} versionA 本地版號 +// * @param {string} versionB 遠程版號 +// * @return {number} num = -1 須更新 +// * @return {number} num = 0 不須更新 +// */ +// public versionCompareHandle(versionA: string, versionB: string): number { +// // console.log("Ver A " + versionA + "VerB " + versionB); +// var vA: string[] = versionA.split("."); +// var vB: string[] = versionB.split("."); + +// // 長度不相等,則進行更新 +// if (vA.length !== vB.length) { +// return -1; +// } + +// for (var i: number = 0; i < vA.length; ++i) { +// var a: number = +vA[i]; +// var b: number = +vB[i] || 0; +// if (a === b) { +// // 數字相同,則跳過 +// continue; +// } else { +// // 數字不同,則進行更新 +// return -1; +// } +// } + +// // 長度相等且數字相等,則不更新 +// return 0; +// } + +// //#endregion + +// //#region DownloadList_Preview + +// private _initdownloadList_Preview(): void { +// this.DownloadList_Preview = JSON.parse(LocalStorageData.Instance.DownloadList_Preview); +// this.DownloadList_Preview = this.DownloadList_Preview ? this.DownloadList_Preview : {}; +// } + +// private _getIsDownload_Preview(slotID: number): boolean { +// if (!this.DownloadList_Preview[slotID]) { +// this.SetIsDownload_Preview(slotID, false); +// } +// return !this.DownloadList_Preview[slotID]; +// } + +// public SetIsDownload_Preview(slotID: number, isDownload: boolean = true): void { +// this.DownloadList_Preview[slotID] = isDownload; +// LocalStorageData.Instance.DownloadList_Preview = JSON.stringify(this.DownloadList_Preview); +// } + +// //#endregion +// } + +// //#region enum + +// /** Bundle資源類型 */ +// export enum Bundle_Source_Type { +// /** Json */ +// Json = "json", + +// /** Scene */ +// Scene = "scene", + +// /** Prefab */ +// Prefab = "prefab" +// } + +// //#endregion + +// //#region 廢棄 Function + +// // /** +// // * 從Bundle刪除暫存資源 +// // * @param {string} BundleName Bundle名稱 +// // */ +// // public *DelBundleCache(BundleName: cc.AssetManager.Bundle | string): IterableIterator { +// // if (!CC_JSB) { +// // return; +// // } +// // let WritablePath: string = `${jsb.fileUtils.getWritablePath()}gamecaches/${BundleName}`; +// // if (jsb.fileUtils.isDirectoryExist(WritablePath)) { +// // jsb.fileUtils.removeDirectory(WritablePath); +// // } +// // } + +// //#endregion \ No newline at end of file diff --git a/assets/Script/HUD/AssetBundleMamager.ts.meta b/assets/Script/HUD/AssetBundleMamager.ts.meta new file mode 100644 index 0000000..b228b49 --- /dev/null +++ b/assets/Script/HUD/AssetBundleMamager.ts.meta @@ -0,0 +1,10 @@ +{ + "ver": "1.1.0", + "uuid": "97a0b2c9-72f8-4797-874a-263e4558f765", + "importer": "typescript", + "isPlugin": false, + "loadPluginInWeb": true, + "loadPluginInNative": true, + "loadPluginInEditor": false, + "subMetas": {} +} \ No newline at end of file diff --git a/assets/Script/HUD/Enum_HUDM.ts b/assets/Script/HUD/Enum_HUDM.ts new file mode 100644 index 0000000..7a1923d --- /dev/null +++ b/assets/Script/HUD/Enum_HUDM.ts @@ -0,0 +1,72 @@ +const { ccclass, property } = cc._decorator; +export module Enum_HUDM { + + //#region Enum + + //#endregion + + //#region Class + + // /** BaseBundle資料 */ + // @ccclass("BaseBundleObj") + // export class BaseBundleObj { + // @property({ displayName: "Bundle名稱", tooltip: "Bundle名稱" }) + // public BundleName: string = ""; + + // @property({ displayName: "優先度", tooltip: "優先度", type: cc.Integer }) + // public Priority: number = 1; + // } + + class BundleDictionary { + [x: string]: T; + } + + /** VerList資料 */ + @ccclass("VerListObj") + export class VerListObj extends BundleDictionary { + } + + /** Bundle資料 */ + @ccclass("BundleDataObj") + export class BundleDataObj { + public Version: string = "0"; + + public ApkVersion: string = "0"; + + public UseLocal: boolean = false; + + /** 有沒有包到Bundle */ + public HasBundle: boolean = true; + } + + /** Bundle資料 */ + @ccclass("NeedUpdateDataObj") + export class NeedUpdateDataObj { + + /** 是否需要更新 */ + public IsNeedUpdate: boolean; + + /** 更新大小 */ + public TotalBytes: string; + + constructor(...params: any[]) { + this.IsNeedUpdate = params[0]; + this.TotalBytes = params[1] ? params[1] : null; + } + } + + /** Bundle資料 */ + @ccclass("UpdateingDataObj") + export class UpdateingDataObj { + + /** 是否更新完成 */ + public IsUpdatecomplete: boolean; + + constructor(...params: any[]) { + this.IsUpdatecomplete = params[0]; + } + } + + //#endregion +} +export default Enum_HUDM; \ No newline at end of file diff --git a/assets/Script/HUD/Enum_HUDM.ts.meta b/assets/Script/HUD/Enum_HUDM.ts.meta new file mode 100644 index 0000000..3b56ade --- /dev/null +++ b/assets/Script/HUD/Enum_HUDM.ts.meta @@ -0,0 +1,10 @@ +{ + "ver": "1.1.0", + "uuid": "7217469f-9c06-46fd-be21-69020675c24d", + "importer": "typescript", + "isPlugin": false, + "loadPluginInWeb": true, + "loadPluginInNative": true, + "loadPluginInEditor": false, + "subMetas": {} +} \ No newline at end of file diff --git a/assets/Script/HUD/HUDM.ts b/assets/Script/HUD/HUDM.ts new file mode 100644 index 0000000..2ae493b --- /dev/null +++ b/assets/Script/HUD/HUDM.ts @@ -0,0 +1,353 @@ +import { CoroutineV2 } from "../Engine/CatanEngine/CoroutineV2/CoroutineV2"; +import UpdatePanel from "../UpdatePanel"; +import Enum_HUDM from "./Enum_HUDM"; + +const { ccclass, property } = cc._decorator; + +/** HUDManager */ +@ccclass +export default class HUDM extends cc.Component { + + //#region static 屬性 + + private static _instance: HUDM = null; + public static get Instance(): HUDM { return HUDM._instance; } + + //#endregion + + //#region private 屬性 + + private _updatePanel: UpdatePanel; + private _am: jsb.AssetsManager; + private _onFileProgress: (finish: number, total: number, item: string) => void; + private _updateListener: any; + private _checkListener: any; + private _versionCompareHandle: any = null; + private _needUpdateData: Enum_HUDM.NeedUpdateDataObj = null; + private _updateingData: Enum_HUDM.UpdateingDataObj = null; + private _updating: boolean = false; + private _canRetry: boolean = false; + private _isChangeUrl: boolean = false; + private _path: string = "Bundle"; + private _customManifest: string = ""; + private _storagePath: string = ""; + + //#endregion + + //#region Lifecycle + + constructor(...params: any[]) { + super(); + + if (!cc.sys.isNative) { + return; + } + HUDM._instance = this; + this._updatePanel = params[0]; + + // let packageUrl: string = params[1]; + // let BundleData: Enum_Loading.BundleDataObj = AssetBundleMamager.Instance.RemoteVerList[this.BundleName]; + // let packageUrl: string = BundleData.BundleUrl; + let packageUrl: string = `https://jianmiau.tk/Resources/App/JMKA/update/remote-assets`; + + this._customManifest = JSON.stringify({ + "packageUrl": packageUrl, + "remoteManifestUrl": `${packageUrl}/project.manifest`, + "remoteVersionUrl": `${packageUrl}/version.json`, + "version": "1.0.0", + }); + + this._storagePath = `${(jsb.fileUtils ? jsb.fileUtils.getWritablePath() : "./")}${this._path}`; + + this._versionCompareHandle = function (versionA: string, versionB: string): number { + // console.log("Ver A " + versionA + "VerB " + versionB); + let vA: string[] = versionA.split("."); + let vB: string[] = versionB.split("."); + + // 長度不相等,則進行更新 + if (vA.length !== vB.length) { + return -1; + } + + for (let i: number = 0; i < vA.length; ++i) { + let a: number = +vA[i]; + let b: number = +vB[i] || 0; + if (a === b) { + // 數字相同,則跳過 + continue; + } else { + // 數字不同,則進行更新 + return -1; + } + } + + // 長度相等且數字相等,則不更新 + return 0; + }; + this._initAssetManaget(); + } + private _initAssetManaget(): void { + let self: this = this; + // + this._am = new jsb.AssetsManager("", this._storagePath, this._versionCompareHandle); + + // Setup the verification callback, but we don't have md5 check function yet, so only print some message + // Return true if the verification passed, otherwise return false + this._am.setVerifyCallback(function (path: any, asset: { compressed: any; md5: any; path: any; size: any; }): boolean { + // When asset is compressed, we don't need to check its md5, because zip file have been deleted. + let compressed: any = asset.compressed; + // Retrieve the correct md5 value. + let expectedMD5: string = asset.md5; + // asset.path is relative path and path is absolute. + let relativePath: string = asset.path; + // The size of asset file, but this value could be absent. + let size: any = asset.size; + if (compressed) { + self._updatePanel.info.string = "Verification passed : " + relativePath; + // console.log("onLoad -> Verification passed : " + relativePath); + return true; + } else { + self._updatePanel.info.string = "Verification passed : " + relativePath + " (" + expectedMD5 + ")"; + // console.log("onLoad -> setVerifyCallbackVerification passed : " + relativePath + " (" + expectedMD5 + ")"); + return true; + } + }); + + if (cc.sys.os === cc.sys.OS_ANDROID) { + // Some Android device may slow down the download process when concurrent tasks is too much. + // The value may not be accurate, please do more test and find what's most suitable for your game. + // this._am.setMaxConcurrentTask(10); + this._am["setMaxConcurrentTask"](10); + // this._updatePanel.info.string = "Max concurrent tasks count have been limited to 2"; + // console.log("onLoad -> Max concurrent tasks count have been limited to 10"); + } + } + + //#endregion + + public *CheckUpdate(): IterableIterator { + this._needUpdateData = null; + if (this._updating) { + this._updatePanel.info.string = "Checking or updating ..."; + console.error("checkUpdate -> Checking or updating ..."); + return; + } + + if (this._am.getState() === jsb.AssetsManager.State.UNINITED) { + let manifest: jsb.Manifest = new jsb.Manifest(this._customManifest, this._storagePath); + this._am.loadLocalManifest(manifest, this._storagePath); + } + if (!this._am.getLocalManifest() || !this._am.getLocalManifest().isLoaded()) { + // this.tipsLabel.string = "Failed to load local manifest ..."; + console.error("checkUpdate -> Failed to load local manifest ..."); + return; + } + this._am.setEventCallback(this.checkCb.bind(this)); + + this._am.checkUpdate(); + this._updating = true; + + while (this._needUpdateData === null) { + yield null; + } + + return this._needUpdateData; + } + + private checkCb(event: jsb.EventAssetsManager): void { + let failed: boolean = false; + switch (event.getEventCode()) { + case jsb.EventAssetsManager.ERROR_NO_LOCAL_MANIFEST: + console.error("checkCb -> No local manifest file found, HUD skipped."); + failed = true; + break; + case jsb.EventAssetsManager.ERROR_DOWNLOAD_MANIFEST: + case jsb.EventAssetsManager.ERROR_PARSE_MANIFEST: + console.error("checkCb -> Fail to download manifest file, HUD skipped."); + failed = true; + break; + case jsb.EventAssetsManager.ALREADY_UP_TO_DATE: + console.log("checkCb -> Already up to date with the latest remote version."); + this._needUpdateData = new Enum_HUDM.NeedUpdateDataObj(false); + break; + case jsb.EventAssetsManager.NEW_VERSION_FOUND: + this._updatePanel.checkBtn.active = false; + this._updatePanel.fileProgress.progress = 0; + this._updatePanel.byteProgress.progress = 0; + this._updatePanel.info.string = "發現新版本,請嘗試更新。 " + this._bytesToSize(event.getTotalBytes()); + console.log("checkCb -> New version found, please try to update." + event.getTotalBytes()); + this._needUpdateData = new Enum_HUDM.NeedUpdateDataObj(true, this._bytesToSize(event.getTotalBytes())); + break; + default: + return; + } + + this._am.setEventCallback(null); + this._checkListener = null; + this._updating = false; + + if (failed) { + this._needUpdateData = new Enum_HUDM.NeedUpdateDataObj(false, null); + } + } + + public *HUD(onFileProgress?: (finish: number, total: number, item: string) => void): IterableIterator { + this._updateingData = null; + if (this._am && !this._updating) { + this._am.setEventCallback(this._updateCb.bind(this)); + + if (this._am.getState() === jsb.AssetsManager.State.UNINITED) { + let manifest: jsb.Manifest = new jsb.Manifest(this._customManifest, this._storagePath); + this._am.loadLocalManifest(manifest, this._storagePath); + } + + this._onFileProgress = onFileProgress ? onFileProgress : null; + this._am.update(); + this._updating = true; + + while (this._updateingData === null) { + yield null; + } + + return this._updateingData; + } else { + return new Enum_HUDM.UpdateingDataObj(false); + } + } + + private _updateCb(event: jsb.EventAssetsManager): void { + let self: this = this; + let needRestart: boolean = false; + let failed: boolean = false; + switch (event.getEventCode()) { + case jsb.EventAssetsManager.ERROR_NO_LOCAL_MANIFEST: + this._updatePanel.info.string = "No local manifest file found, HUD skipped."; + console.log("updateCb -> No local manifest file found, HUD skipped."); + failed = true; + break; + case jsb.EventAssetsManager.UPDATE_PROGRESSION: + this._updatePanel.byteProgress.progress = event.getPercent(); + this._updatePanel.fileProgress.progress = event.getPercentByFile(); + this._updatePanel.fileLabel.string = event.getDownloadedFiles() + " / " + event.getTotalFiles(); + // this.tipsLabel.string = event.getDownloadedBytes() + " / " + event.getTotalBytes(); + + // console.log("updateCb -> " + event.getDownloadedBytes() + " / " + event.getTotalBytes()); + // let msg: string = event.getMessage(); + // if (msg) { + // this._updatePanel.info.string = 'Updated file: ' + msg; + // console.log("updateCb -> Updated file: " + msg); + // console.log("updateCb -> " + event.getPercent() / 100 + "% : " + msg); + // } + + let msg: string = event.getMessage(); + if (this._onFileProgress) { + this._onFileProgress(event.getDownloadedBytes(), event.getTotalBytes(), msg ? msg : ""); + } + break; + case jsb.EventAssetsManager.ERROR_DOWNLOAD_MANIFEST: + case jsb.EventAssetsManager.ERROR_PARSE_MANIFEST: + this._updatePanel.info.string = "Fail to download manifest file, HUD skipped."; + console.error("updateCb -> Fail to download manifest file, HUD skipped."); + failed = true; + break; + case jsb.EventAssetsManager.ALREADY_UP_TO_DATE: + this._updatePanel.info.string = "Already up to date with the latest remote version."; + console.error("updateCb -> Already up to date with the latest remote version."); + failed = true; + break; + case jsb.EventAssetsManager.UPDATE_FINISHED: + // this.tipsLabel.string = "更新完成. " + event.getMessage(); + console.log("updateCb -> 更新完成. " + event.getMessage()); + this._updateingData = new Enum_HUDM.UpdateingDataObj(true); + needRestart = true; + break; + case jsb.EventAssetsManager.UPDATE_FAILED: + this._updatePanel.info.string = "Update failed. " + event.getMessage(); + console.error("updateCb -> Update failed. " + event.getMessage()); + this._updatePanel.retryBtn.active = true; + this._canRetry = true; + this._updateingData = new Enum_HUDM.UpdateingDataObj(false); + this._updating = false; + break; + case jsb.EventAssetsManager.ERROR_UPDATING: + this._updatePanel.info.string = "Asset update error: " + event.getAssetId() + ", " + event.getMessage(); + console.error("updateCb -> Asset update error: " + event.getAssetId() + ", " + event.getMessage()); + break; + case jsb.EventAssetsManager.ERROR_DECOMPRESS: + this._updatePanel.info.string = event.getMessage(); + console.error("updateCb -> " + event.getMessage()); + break; + default: + break; + } + + if (failed) { + this._am.setEventCallback(null); + this._updateListener = null; + this._updating = false; + } + + if (needRestart) { + let AsyncFunction: () => IterableIterator = function* (): IterableIterator { + self._updatePanel.info.string = "更新完成 即將重啟"; + // 卡個一幀不然都看不到100%的畫面 + yield CoroutineV2.WaitTime(5 / cc.game.getFrameRate()).Start(); + + self._am.setEventCallback(null); + self._updateListener = null; + // Prepend the manifest's search path + let searchPaths: string[] = jsb.fileUtils.getSearchPaths(); + let newPaths: [string] = self._am.getLocalManifest().getSearchPaths(); + console.log(JSON.stringify(newPaths)); + Array.prototype.unshift.apply(searchPaths, newPaths); + // This value will be retrieved and appended to the default search path during game startup, + // please refer to samples/js-tests/main.js for detailed usage. + // !!! Re-add the search paths in main.js is very important, otherwise, new scripts won't take effect. + cc.sys.localStorage.setItem("HotUpdateSearchPaths", JSON.stringify(searchPaths)); + jsb.fileUtils.setSearchPaths(searchPaths); + + cc.audioEngine.stopAll(); + cc.game.restart(); + }; + CoroutineV2.Single(AsyncFunction()).Start(); + } + } + + public *RetryDownLoadFailedAssets(): IterableIterator { + if (!this._updating && this._canRetry) { + this._updateingData = null; + this._updatePanel.retryBtn.active = false; + this._canRetry = false; + + this._updatePanel.info.string = "Retry failed Assets..."; + console.log("retry -> Retry failed Assets..."); + this._am.downloadFailedAssets(); + + while (this._updateingData === null) { + yield null; + } + + return this._updateingData; + } else { + console.error(`retry -> error updating: ${this._updating}, canRetry: ${this._canRetry}`); + this._updateingData = new Enum_HUDM.UpdateingDataObj(false); + } + } + + private _bytesToSize(bytes: number): string { + if (bytes === 0) { + return "0 B"; + } + let k: number = 1024; + let sizes: string[] = ["B", "KB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB"]; + let i: number = Math.floor(Math.log(bytes) / Math.log(k)); + return (bytes / Math.pow(k, i)).toPrecision(3) + " " + sizes[i]; + } + + protected onDestroy(): void { + if (this._updateListener) { + this._am.setEventCallback(null); + this._updateListener = null; + } + } +} diff --git a/assets/Script/HUD/HUDM.ts.meta b/assets/Script/HUD/HUDM.ts.meta new file mode 100644 index 0000000..cd48b0e --- /dev/null +++ b/assets/Script/HUD/HUDM.ts.meta @@ -0,0 +1,10 @@ +{ + "ver": "1.1.0", + "uuid": "dd9501f7-957a-4e62-8630-d43f62d171d1", + "importer": "typescript", + "isPlugin": false, + "loadPluginInWeb": true, + "loadPluginInNative": true, + "loadPluginInEditor": false, + "subMetas": {} +} \ No newline at end of file diff --git a/assets/Script/Manager.ts b/assets/Script/Manager.ts index 90f278d..343c5d1 100644 --- a/assets/Script/Manager.ts +++ b/assets/Script/Manager.ts @@ -1,6 +1,15 @@ +/* + +node version_generator.js -v 1.0.0 -u https://jianmiau.tk/Resources/App/JMKA/update/remote-assets/ -s build/jsb-default/remote-assets -d remote-assets + +*/ + import { CoroutineV2 } from "./Engine/CatanEngine/CoroutineV2/CoroutineV2"; import { System_Eevent } from "./Engine/CatanEngine/CSharp/System/System_Eevent"; +import { Enum_HUDM } from "./HUD/Enum_HUDM"; +import HUDM from "./HUD/HUDM"; import NativeClass from "./NativeClass"; +import UpdatePanel from "./UpdatePanel"; const { ccclass, property } = cc._decorator; @@ -14,23 +23,35 @@ export default class Manager extends cc.Component { @property({ type: cc.Node }) public BG: cc.Node = null; - //#endregion - - //#region private - - // private _text_to_Speech: Text_to_Speech; + @property({ type: cc.Node }) + public UpdatePanel: cc.Node = null; //#endregion //#region Lifecycle protected onLoad(): void { + CoroutineV2.Single(this._init()).Start(); + } + + private *_init(): IterableIterator { + console.log(`2022/08/30 16:26`); cc.debug.setDisplayStats(false); if (CC_DEBUG) { console.log("Debug"); } new NativeClass(this.webview); + if (cc.sys.isNative) { + new HUDM(this.UpdatePanel.getComponentInChildren(UpdatePanel)); + let needUpdateData: Enum_HUDM.NeedUpdateDataObj = yield* HUDM.Instance.CheckUpdate(); + if (needUpdateData.IsNeedUpdate) { + this.UpdatePanel.active = true; + return; + } else { + this.UpdatePanel.active = false; + } + } let self: this = this; // this._text_to_Speech = new Text_to_Speech(); @@ -115,7 +136,7 @@ export default class Manager extends cc.Component { public *GetFCMToken(): IterableIterator { const FCMToken: string = NativeClass.Instance.GetFCMToken(); - if (!FCMToken) { + if (cc.sys.os === cc.sys.OS_IOS && !FCMToken) { yield CoroutineV2.WaitTime(1); yield this.GetFCMToken(); return; diff --git a/assets/Script/UpdatePanel.ts b/assets/Script/UpdatePanel.ts new file mode 100644 index 0000000..92cdfd6 --- /dev/null +++ b/assets/Script/UpdatePanel.ts @@ -0,0 +1,73 @@ +import { CoroutineV2 } from "./Engine/CatanEngine/CoroutineV2/CoroutineV2"; +import { Enum_HUDM } from "./HUD/Enum_HUDM"; +import HUDM from "./HUD/HUDM"; + +const { ccclass, property } = cc._decorator; + +@ccclass +export default class UpdatePanel extends cc.Component { + //#region 外調參數 + + @property({ type: cc.Label }) + public info: cc.Label = null; + + @property({ type: cc.ProgressBar }) + public fileProgress: cc.ProgressBar = null; + + @property({ type: cc.Label }) + public fileLabel: cc.Label = null; + + @property({ type: cc.ProgressBar }) + public byteProgress: cc.ProgressBar = null; + + @property({ type: cc.Label }) + public byteLabel: cc.Label = null; + + @property({ type: cc.Node }) + public close: cc.Node = null; + + @property({ type: cc.Node }) + public checkBtn: cc.Node = null; + + @property({ type: cc.Node }) + public retryBtn: cc.Node = null; + + @property({ type: cc.Node }) + public updateBtn: cc.Node = null; + + //#endregion + + //#region Lifecycle + + protected onLoad(): void { + let self: this = this; + this.close.on(cc.Node.EventType.TOUCH_END, () => { + self.node.active = false; + }, this); + + this.node.getChildByName("update_btn").on("click", () => { CoroutineV2.Single(this.OnClickUpdate()).Start(); }, this); + this.node.getChildByName("check_btn").on("click", () => { CoroutineV2.Single(this.OnClickCheck()).Start(); }, this); + this.node.getChildByName("retry_btn").on("click", () => { CoroutineV2.Single(this.OnClickRetry()).Start(); }, this); + } + + //#endregion + + //#region OnClick + + public *OnClickUpdate(): IterableIterator { + let updateingData: Enum_HUDM.UpdateingDataObj = yield* HUDM.Instance.HUD(); + return; + } + + public *OnClickCheck(): IterableIterator { + let needUpdateData: Enum_HUDM.NeedUpdateDataObj = yield* HUDM.Instance.CheckUpdate(); + return; + } + + public *OnClickRetry(): IterableIterator { + let updateingData: Enum_HUDM.UpdateingDataObj = yield* HUDM.Instance.RetryDownLoadFailedAssets(); + return; + } + + //#endregion +} diff --git a/assets/Script/UpdatePanel.ts.meta b/assets/Script/UpdatePanel.ts.meta new file mode 100644 index 0000000..27fe8b9 --- /dev/null +++ b/assets/Script/UpdatePanel.ts.meta @@ -0,0 +1,10 @@ +{ + "ver": "1.1.0", + "uuid": "86711b47-13f6-4a4e-8a9d-0e24e7fca6e7", + "importer": "typescript", + "isPlugin": false, + "loadPluginInWeb": true, + "loadPluginInNative": true, + "loadPluginInEditor": false, + "subMetas": {} +} \ No newline at end of file diff --git a/assets/Texture/UI.meta b/assets/Texture/UI.meta new file mode 100644 index 0000000..c9ec5e0 --- /dev/null +++ b/assets/Texture/UI.meta @@ -0,0 +1,13 @@ +{ + "ver": "1.1.3", + "uuid": "e47b98da-e2c8-4c74-9530-0f718d04b512", + "importer": "folder", + "isBundle": false, + "bundleName": "", + "priority": 1, + "compressionType": {}, + "optimizeHotUpdate": {}, + "inlineSpriteFrames": {}, + "isRemoteBundle": {}, + "subMetas": {} +} \ No newline at end of file diff --git a/assets/Texture/UI/chat.meta b/assets/Texture/UI/chat.meta new file mode 100644 index 0000000..570719d --- /dev/null +++ b/assets/Texture/UI/chat.meta @@ -0,0 +1,13 @@ +{ + "ver": "1.1.3", + "uuid": "72d8bf4e-9f48-4cdc-9121-eb140ee30407", + "importer": "folder", + "isBundle": false, + "bundleName": "", + "priority": 1, + "compressionType": {}, + "optimizeHotUpdate": {}, + "inlineSpriteFrames": {}, + "isRemoteBundle": {}, + "subMetas": {} +} \ No newline at end of file diff --git a/assets/Texture/UI/chat/button_orange.png b/assets/Texture/UI/chat/button_orange.png new file mode 100644 index 0000000000000000000000000000000000000000..e9eac006779f617599f320a40ebca7ded563855b GIT binary patch literal 18969 zcmaI7b95%rw=Ejmwr$&XI<{?mUu;_)n;mqV?$}N`wr#WX#d-ZZ_nv#-AMd;xRkbnJ zoNMj1<``9@M(vnyDzeB31PEYYV94@vQtJQO+kck{9L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AqitIv}M5f23`23LC7`M_pI})n19cS`)3DC*mR4{coIDAKHZMj&M zYbI=N%I+h=8(eD9i9+P0MRaO)Z>ZNbmx$KCNNhQgv0T{NGQ7v9J#6>(_(dU7FV}ek zA}8HzbA$bpBfJlS%ETAiLj#K`dE%Kqf*U)6hSPcv66@w0{e**02-SY#iPXcRYOWh+ z`~5kMZExi@htHo~d70!LdJv~j&;zILZq6d5X(wr#+Xh~1tTb-gHrLn~yi%^_@(k&i zndU!PQYL%Mqoe9$2tjP8&hOdI`wX9BEuVlUjQPkdxfJF@c4}+gxy3Tf+m{RO)WeKz z%hu(u`5hnMH$mkNh+m#w`qE*bf(a1TVP^*>7ooqZWW7JPSl&Jx2#6__)k+&H_gP)5 zj}qS}DQFgF=6$K~FFqzC2q7*frsoCV=skZ$Gkl&4l)FzwE)|{JKeZEl_jcmA8#Y>@ zHI%eX(&ebn3+cIvxH73dxes)t<@(g5?@n7uLIZLn$S;oc#aJGH^|+sN_{~sH13vB$ z;sYk+mk`cGqGg|Q?uH{79t&_c>4DKp`m0iK(DA{YX_Cbj7uN1!4z>h*g-u}me*myeOyU3l literal 0 HcmV?d00001 diff --git a/assets/Texture/UI/chat/gb_inputbox.png.meta b/assets/Texture/UI/chat/gb_inputbox.png.meta new file mode 100644 index 0000000..90ec75b --- /dev/null +++ b/assets/Texture/UI/chat/gb_inputbox.png.meta @@ -0,0 +1,38 @@ +{ + "ver": "2.3.7", + "uuid": "c39ea496-96eb-4dc5-945a-e7c919b77c21", + "importer": "texture", + "type": "sprite", + "wrapMode": "clamp", + "filterMode": "bilinear", + "premultiplyAlpha": false, + "genMipmaps": false, + "packable": true, + "width": 54, + "height": 81, + "platformSettings": {}, + "subMetas": { + "gb_inputbox": { + "ver": "1.0.6", + "uuid": "7d1d4e60-aba2-48e8-85f8-8e328f34e7cc", + "importer": "sprite-frame", + "rawTextureUuid": "c39ea496-96eb-4dc5-945a-e7c919b77c21", + "trimType": "auto", + "trimThreshold": 1, + "rotated": false, + "offsetX": 0, + "offsetY": 0, + "trimX": 0, + "trimY": 0, + "width": 54, + "height": 81, + "rawWidth": 54, + "rawHeight": 81, + "borderTop": 11, + "borderBottom": 11, + "borderLeft": 12, + "borderRight": 12, + "subMetas": {} + } + } +} \ No newline at end of file diff --git a/assets/Texture/UI/new.meta b/assets/Texture/UI/new.meta new file mode 100644 index 0000000..a371a70 --- /dev/null +++ b/assets/Texture/UI/new.meta @@ -0,0 +1,13 @@ +{ + "ver": "1.1.3", + "uuid": "d695c8b9-c7e7-4290-84e5-c10e9988e966", + "importer": "folder", + "isBundle": false, + "bundleName": "", + "priority": 1, + "compressionType": {}, + "optimizeHotUpdate": {}, + "inlineSpriteFrames": {}, + "isRemoteBundle": {}, + "subMetas": {} +} \ No newline at end of file diff --git a/assets/Texture/UI/new/bg_rankinglist.png b/assets/Texture/UI/new/bg_rankinglist.png new file mode 100644 index 0000000000000000000000000000000000000000..594f94787bc9b0113c9d7597de2b04ba6cb15647 GIT binary patch literal 3765 zcmai130PBC7Ji5dN)5L5(?|x0!DTE<5_Uq6Is^nUpvaDhAq0pt3rQdW0!SS|%T~07 z5rl{q(JH%u7`BRl6akT1Hi19{WDNm^Ph9iIrqKf@=2#- zJGN_V2LND)gFVIt0F*?E@%O4*6`!v~5mLo%FT>W8ahejyVB%;5;AjBFp8$0r;erS* z1YAHwXe$8?0Ln0;t0%(~djf^0kPL9^90L}Ks;~wCv^9&0!-o(UP=7)Yk!%GMaO+`E zVt^IQ!vu@KQf&yqMEgh@;dG>vD?Ty=ZxH~qJ_1FvPznJOfq{dvNZ*j@D3%p$Ll>nO zuTR5a&>EjVdB-GT@0BLMuYKqi@8X}N}aD?JA)khkm zOiWRRX3+NsOyP|d5QuWY*uD3qKvu9|27`)%!67U?9~3YII-W+PGKds1bX^hWPYGjK!4#3cTLOvtQI<@9pC(1Z;4B;!jx<25 zFX;mji~ZkJ66qtG&Tt|85$|6L(_JH|1h@-;nw?iDo9JMq4V2h#P!$<@&??DL!c4E z2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XQD>eLb%55-`tDPEW-Di0<-!1Siz~eoAQ8qNk4;}T?pC4js0if^E*s0kgyOm=* z$FIIf$lr9~;;pAe=T~Zx^SiRc=N%B3Zl|+-o;r?x~fd z74aCP1(4|qr|)J`fd9hGe91CzZ~{CKaZ(7hyTGJJ_#&kq7hba|7FL z+D95QK)|wa&gucmlp8d4EU1Gc38e6D#m=qW68&-n;K9x1uQTU4? ziMb%|N)Pi3(VGyQl&HVZo@ggPnas{b0=;fRvUump>58gbDKhkvwUD0GercX%>REwA z9s*|mQ&^O8*%(`Xcl>$nNO%}IEaLYAz=iDTH_upXoTJ=uZr%k+UOI z&L_!jN4CmmCLW855i(eEtDlsl6Eb9tUh8OV?~=qs6349r`yJ&IhKkqV6ZKRJl({%{ zM4T9I}6tYf*G%VjHo!oO26sn{I;kC5!1Ck;F+Wv?Twlx}OyNbcRzD!uvX^fbX~ zZ4P@SJtP|I<(AV#jtacno$EVQIROvz$b9Sv^xt!1R`~pwLp>u^GM_Iq#x5G`ZhgUq zZmvQ8OZ~GQV<}yEH<8HeW(OOE(^hDiI*yHeu>9j{9Aq0?=pLIsuUw-+KBDmt`4Ux9 zCz4l*;*+{=Mwo*#wSl6A9}#Ci^NpUo{mQ4Lv4vMWR*D$XY^EfJa;CQcKHmv2E6%O` zx-UD<3SJvcbPhh!WNQcYw3JUd3}NvkjAl z2&Z`AeB?}8eCXekMc(xzh^=Sn09pASPVZm{oFa(;7Z)B|8$*olmW~#R_R0J%C;{a2 X3C=dp@}k%ONIKX$VT%57?%RI@4)VwL literal 0 HcmV?d00001 diff --git a/assets/Texture/UI/new/bg_rankinglist.png.meta b/assets/Texture/UI/new/bg_rankinglist.png.meta new file mode 100644 index 0000000..17ea162 --- /dev/null +++ b/assets/Texture/UI/new/bg_rankinglist.png.meta @@ -0,0 +1,38 @@ +{ + "ver": "2.3.7", + "uuid": "700faa17-11a6-46cd-aeb5-d6900bc264f8", + "importer": "texture", + "type": "sprite", + "wrapMode": "clamp", + "filterMode": "bilinear", + "premultiplyAlpha": false, + "genMipmaps": false, + "packable": true, + "width": 504, + "height": 144, + "platformSettings": {}, + "subMetas": { + "bg_rankinglist": { + "ver": "1.0.6", + "uuid": "ca7dd73d-526a-4c85-9702-eb51e93b9d99", + "importer": "sprite-frame", + "rawTextureUuid": "700faa17-11a6-46cd-aeb5-d6900bc264f8", + "trimType": "auto", + "trimThreshold": 1, + "rotated": false, + "offsetX": 0, + "offsetY": 0, + "trimX": 0, + "trimY": 0, + "width": 504, + "height": 144, + "rawWidth": 504, + "rawHeight": 144, + "borderTop": 69, + "borderBottom": 36, + "borderLeft": 36, + "borderRight": 36, + "subMetas": {} + } + } +} \ No newline at end of file diff --git a/assets/Texture/UI/new/icon_back.png b/assets/Texture/UI/new/icon_back.png new file mode 100644 index 0000000000000000000000000000000000000000..49da54ddfa3a206cf738d904b684a79bedc2d08f GIT binary patch literal 2290 zcmaJ@dpwl+9)8ETw=}9nDPAMfq|5~~%w#ZQW}-|nMo4HbFNWT^kC{>JDn*@WXFHp& zh^($s6H2MHsn`x(c3mTs)TWM0oi2)Yv}w;Dr}KW^_x)Wy&+~l0-{1H7nPhxOdSY~7cfPbJ?#uuhRDo_9=izPJl(8VigP%NUMqe&bB zM-~jFh(j_IP-Mmmo-iX#ND-j}13-T*)hGZ%Dn6)%*GZIAEe-uimuj3(ZsXD5Cx|MI zhW;z57*04CELA`t3Fqx8BoK)pnT#X)kjP}>V$h2~^uiO2FWHmmLnV=^UcTVx2W^a| z5G7H$O!ntk#uW{nqEgAIc)UiV!D+m4QbjVJNTEE8-mk6OyCJk*=z=_2oDwE0bCHhgkNpvQKNMw=dYzi@$&7w0{ zOcI4b@S5T>r9w3fNmNr@(cfI3uW~1?0LzS#nUF%94vE+bDGYupnJWHzF2t|ueddb3 zo{QI4xp-qT_{qlpSEHx4jP9A7ezC1_@x}O%#OQW~(bm7c#54hbSyCvI&eL|*?;Dp! zMmgRbx&*&S7&F`}Pn*`U{G9q5qT6NtHn|||8>@O#w+RRHnKpE*%_Rhs$@@l^@latI zJCB)Df}4p6JJJyI=Ej4yhY1~V$%(D69}Ft@KUti-XZ`*AuU1J$n`)8=|9JQO;1mBR zy26o*MdNz!;l7BuzwKJun&SOKM_r>?8Po&)RA0%lmBS_kJWsF?(#sq4$<`lIcZnmK_D!6;Nrq-@kmQ;5+y5K95Jc6MIh?mK;1aD(ZPWf_Tafis;%^*@4X* zyWwGS+794dDgF4Y|JBlDd;3mlFxthH|ccAUh&CVYus6be-Z|-;Kl1%+pv`HyqEda2K zmsssb{MZtc1Tw2$5KMdbxG)~p%#1e$P2;WQ7Ct{nmR#-J59Y>7lu0>O4ASe>G+O7_Fc;bqln&FXAW&WV==?wt*vSWNg|3vGz#*4aji(`qrZ#+FT;5=fU)g z_90bmeg7UT&;v{n#-XJIOG4Q*JatVeVpj|zq{cpEc785a0RMbVcL4bAgaq_$o*0b&`IKcWL5SX$N`-`W0L9skVP2GKABX*lk{@U=XzJ(0g7 z2R%ba~18XWcIo=>gQ7D5w43 zmyUYu>IYnxAwpEWonaepD(Mw1sm)!5ZpFjh=iX@21y$JtrL)i#XsctfXXF-n$L$G~ z2Yw0C$W+)5_bqZRPhjjh7|G7AiyNQ*r+FpNn~!#gzg72kgU5wf>*Vx*MRgth$KtJL zbxH1Cl!b{wu{HV`f}hGGXK`_O{7eNGNLs^Auz4=05=kN14F@ literal 0 HcmV?d00001 diff --git a/assets/Texture/UI/new/icon_back.png.meta b/assets/Texture/UI/new/icon_back.png.meta new file mode 100644 index 0000000..37fbf94 --- /dev/null +++ b/assets/Texture/UI/new/icon_back.png.meta @@ -0,0 +1,38 @@ +{ + "ver": "2.3.7", + "uuid": "2ddfe005-2129-41d8-aeec-2b1f51f02962", + "importer": "texture", + "type": "sprite", + "wrapMode": "clamp", + "filterMode": "bilinear", + "premultiplyAlpha": false, + "genMipmaps": false, + "packable": true, + "width": 33, + "height": 48, + "platformSettings": {}, + "subMetas": { + "icon_back": { + "ver": "1.0.6", + "uuid": "6035fac6-5208-4e0b-bea7-62ff9fb1338b", + "importer": "sprite-frame", + "rawTextureUuid": "2ddfe005-2129-41d8-aeec-2b1f51f02962", + "trimType": "auto", + "trimThreshold": 1, + "rotated": false, + "offsetX": 0, + "offsetY": 0, + "trimX": 0, + "trimY": 0, + "width": 33, + "height": 48, + "rawWidth": 33, + "rawHeight": 48, + "borderTop": 0, + "borderBottom": 0, + "borderLeft": 0, + "borderRight": 0, + "subMetas": {} + } + } +} \ No newline at end of file diff --git a/assets/Texture/UI/table.meta b/assets/Texture/UI/table.meta new file mode 100644 index 0000000..cb2171f --- /dev/null +++ b/assets/Texture/UI/table.meta @@ -0,0 +1,13 @@ +{ + "ver": "1.1.3", + "uuid": "7e51bdf1-1b2e-4de4-9e05-b9c9715f6229", + "importer": "folder", + "isBundle": false, + "bundleName": "", + "priority": 1, + "compressionType": {}, + "optimizeHotUpdate": {}, + "inlineSpriteFrames": {}, + "isRemoteBundle": {}, + "subMetas": {} +} \ No newline at end of file diff --git a/assets/Texture/UI/table/bg_jinbishu.png b/assets/Texture/UI/table/bg_jinbishu.png new file mode 100644 index 0000000000000000000000000000000000000000..3bf29d331e6c090a6bd72b96fed5f394ff4f81b3 GIT binary patch literal 1829 zcmaJ?dsIw$9KVsIQXG0{H?GMl(mZNrYDP)(h}x#-&=k@%b8BvO=T3KSW|~9gy&Q4M zqav$@Y8)GzT13$c)gmO$p^1*|gkC#NM2fwG*gv+t=id8!eLkP>^PamWEM(P83r7n8 z0A>cR=0y;rEAh-XHzVG$`t^EZn1}O4cqE#DtHc-t_)F1v2n`e#xJVGpmY@h(Y{Zb&h=O1PfRCSAA(kXVI2aEl!g62I(3NW>5SIFqq8I|IK*5D% z@M;YPMQTEX5>2v%B_;W-0DaVKLI8nqF{nmTMm-JbeP0Wqk6cYFuf+zcuzBnZk zgn?WXgFpt^(_KQP(Lg4XOrtZHOxiNggG%$DP>GxAPNTCKOtyy?`1K+Y)-Y)TJAxPR z)fTbxCCPAH!KP4DDivAfNk*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a@ literal 0 HcmV?d00001 diff --git a/assets/Texture/UI/table/bg_jinbishu.png.meta b/assets/Texture/UI/table/bg_jinbishu.png.meta new file mode 100644 index 0000000..5b12770 --- /dev/null +++ b/assets/Texture/UI/table/bg_jinbishu.png.meta @@ -0,0 +1,38 @@ +{ + "ver": "2.3.7", + "uuid": "caaaf9ff-5036-4232-a8a7-88b80b2e4c88", + "importer": "texture", + "type": "sprite", + "wrapMode": "clamp", + "filterMode": "bilinear", + "premultiplyAlpha": false, + "genMipmaps": false, + "packable": true, + "width": 40, + "height": 30, + "platformSettings": {}, + "subMetas": { + "bg_jinbishu": { + "ver": "1.0.6", + "uuid": "022a80ab-4cde-42ca-9e04-8a23745cf138", + "importer": "sprite-frame", + "rawTextureUuid": "caaaf9ff-5036-4232-a8a7-88b80b2e4c88", + "trimType": "auto", + "trimThreshold": 1, + "rotated": false, + "offsetX": 0, + "offsetY": 0, + "trimX": 0, + "trimY": 0, + "width": 40, + "height": 30, + "rawWidth": 40, + "rawHeight": 30, + "borderTop": 0, + "borderBottom": 0, + "borderLeft": 11, + "borderRight": 12, + "subMetas": {} + } + } +} \ No newline at end of file diff --git a/build-templates/jsb-default/frameworks/runtime-src/proj.android-studio/res/values/strings.xml b/build-templates/jsb-default/frameworks/runtime-src/proj.android-studio/res/values/strings.xml index 4ae115c..42ca887 100644 --- a/build-templates/jsb-default/frameworks/runtime-src/proj.android-studio/res/values/strings.xml +++ b/build-templates/jsb-default/frameworks/runtime-src/proj.android-studio/res/values/strings.xml @@ -1,4 +1,4 @@ - 爆機娛樂城 + 卡羅記帳 \ No newline at end of file diff --git a/build-templates/jsb-default/main.js b/build-templates/jsb-default/main.js new file mode 100644 index 0000000..d6169f7 --- /dev/null +++ b/build-templates/jsb-default/main.js @@ -0,0 +1,149 @@ +window.boot = function () { + var settings = window._CCSettings; + window._CCSettings = undefined; + var onProgress = null; + + var RESOURCES = cc.AssetManager.BuiltinBundleName.RESOURCES; + var INTERNAL = cc.AssetManager.BuiltinBundleName.INTERNAL; + var MAIN = cc.AssetManager.BuiltinBundleName.MAIN; + function setLoadingDisplay() { + // Loading splash scene + var splash = document.getElementById('splash'); + var progressBar = splash.querySelector('.progress-bar span'); + onProgress = function (finish, total) { + var percent = 100 * finish / total; + if (progressBar) { + progressBar.style.width = percent.toFixed(2) + '%'; + } + }; + splash.style.display = 'block'; + progressBar.style.width = '0%'; + + cc.director.once(cc.Director.EVENT_AFTER_SCENE_LAUNCH, function () { + splash.style.display = 'none'; + }); + } + + var onStart = function () { + + cc.view.enableRetina(true); + cc.view.resizeWithBrowserSize(true); + + if (cc.sys.isBrowser) { + setLoadingDisplay(); + } + + if (cc.sys.isMobile) { + if (settings.orientation === 'landscape') { + cc.view.setOrientation(cc.macro.ORIENTATION_LANDSCAPE); + } + else if (settings.orientation === 'portrait') { + cc.view.setOrientation(cc.macro.ORIENTATION_PORTRAIT); + } + cc.view.enableAutoFullScreen([ + cc.sys.BROWSER_TYPE_BAIDU, + cc.sys.BROWSER_TYPE_BAIDU_APP, + cc.sys.BROWSER_TYPE_WECHAT, + cc.sys.BROWSER_TYPE_MOBILE_QQ, + cc.sys.BROWSER_TYPE_MIUI, + cc.sys.BROWSER_TYPE_HUAWEI, + cc.sys.BROWSER_TYPE_UC, + ].indexOf(cc.sys.browserType) < 0); + } + + // Limit downloading max concurrent task to 2, + // more tasks simultaneously may cause performance draw back on some android system / browsers. + // You can adjust the number based on your own test result, you have to set it before any loading process to take effect. + if (cc.sys.isBrowser && cc.sys.os === cc.sys.OS_ANDROID) { + cc.assetManager.downloader.maxConcurrency = 2; + cc.assetManager.downloader.maxRequestsPerFrame = 2; + } + + var launchScene = settings.launchScene; + var bundle = cc.assetManager.bundles.find(function (b) { + return b.getSceneInfo(launchScene); + }); + + bundle.loadScene(launchScene, null, onProgress, + function (err, scene) { + if (!err) { + cc.director.runSceneImmediate(scene); + if (cc.sys.isBrowser) { + // show canvas + var canvas = document.getElementById('GameCanvas'); + canvas.style.visibility = ''; + var div = document.getElementById('GameDiv'); + if (div) { + div.style.backgroundImage = ''; + } + console.log('Success to load scene: ' + launchScene); + } + } + } + ); + + }; + + var option = { + id: 'GameCanvas', + debugMode: settings.debug ? cc.debug.DebugMode.INFO : cc.debug.DebugMode.ERROR, + showFPS: settings.debug, + frameRate: 60, + groupList: settings.groupList, + collisionMatrix: settings.collisionMatrix, + }; + + cc.assetManager.init({ + bundleVers: settings.bundleVers, + remoteBundles: settings.remoteBundles, + server: settings.server + }); + + var bundleRoot = [INTERNAL]; + settings.hasResourcesBundle && bundleRoot.push(RESOURCES); + + var count = 0; + function cb(err) { + if (err) return console.error(err.message, err.stack); + count++; + if (count === bundleRoot.length + 1) { + cc.assetManager.loadBundle(MAIN, function (err) { + if (!err) cc.game.run(option, onStart); + }); + } + } + + cc.assetManager.loadScript(settings.jsList.map(function (x) { return 'src/' + x; }), cb); + + for (var i = 0; i < bundleRoot.length; i++) { + cc.assetManager.loadBundle(bundleRoot[i], cb); + } +}; + +if (window.jsb) { + var hotUpdateSearchPaths = localStorage.getItem('HotUpdateSearchPaths'); + if (hotUpdateSearchPaths) { + jsb.fileUtils.setSearchPaths(JSON.parse(hotUpdateSearchPaths)); + } + + var isRuntime = (typeof loadRuntime === 'function'); + if (isRuntime) { + require('src/settings.js'); + require('src/cocos2d-runtime.js'); + if (CC_PHYSICS_BUILTIN || CC_PHYSICS_CANNON) { + require('src/physics.js'); + } + require('jsb-adapter/engine/index.js'); + } + else { + require('src/settings.js'); + require('src/cocos2d-jsb.js'); + if (CC_PHYSICS_BUILTIN || CC_PHYSICS_CANNON) { + require('src/physics.js'); + } + require('jsb-adapter/jsb-engine.js'); + } + + cc.macro.CLEANUP_IMAGE_CACHE = true; + window.boot(); +} \ No newline at end of file diff --git a/hotupdate.bat b/hotupdate.bat new file mode 100644 index 0000000..4955c61 --- /dev/null +++ b/hotupdate.bat @@ -0,0 +1,29 @@ +@echo off + +set Ver=1.0.2 +set START1=%~dp0\build\jsb-default\remote-assets +set START2=%~dp0\remote-assets +set END=W:\web\MyWeb\Resources\App\JMKA\update\remote-assets + +node version_generator.js -v %Ver% -u https://jianmiau.tk/Resources/App/JMKA/update/remote-assets/ -s build/jsb-default/remote-assets -d remote-assets + +@REM rmdir /s /q %END% +@REM del /f "%END%" +@REM mkdir %END% +chcp 950 >NUL +GOTO ALL + +:ALL +echo PBbuildɮ +robocopy %START1% %END% /E /Z /FFT /COPY:D /NJH /NJS /NDL +GOTO ALL2 + +:ALL2 +echo PBmanifestɮ +robocopy %START2% %END% /E /Z /FFT /COPY:D /NJH /NJS /NDL +GOTO END + +:END +echo Done! +PAUSE + diff --git a/packages/hot-update-tools/CommonIssue.md b/packages/hot-update-tools/CommonIssue.md new file mode 100644 index 0000000..177b830 --- /dev/null +++ b/packages/hot-update-tools/CommonIssue.md @@ -0,0 +1,35 @@ +# 常见问题 +## 说明 +这里是作者热更新过程中遇到的一些问题,仅供参考 + +### 局域网测试时,为啥我的热更新请求地址是bogon(127.0.0.1) +![图片](../../doc/热更新/desc/issue1.png) +- 导致原因 + - 开发环境所在的局域网路由器可能设置了ip虚拟化导致这个问题 + - 此时你可以ping一下同局域网的电脑,如果和下图一样,主机ip为bogon,那么很有可能是ip虚拟化导致看不到主机名字 + ![图片](../../doc/热更新/desc/issue2.png) +- 解决办法: + - 可以发布到公网测试下,如果在公网环境仍然存在这个问题,那么很有可能就是代码的问题! + - 如果仍然想在局域网环境测试,Windows的话,务必确认已经关闭本机防火墙,再次尝试 +### 热更新黑屏,报错如图 +![图片](../../doc/热更新/desc/issue3.png) +尝试着使用gradle:2.3.0 也许能够解决问题 +文件地址: proj.android-studio/build.gradle +``` + classpath 'com.android.tools.build:gradle:2.3.0' +``` + +### 插件全局安装目录在哪里? +- 在win上 +``` +C:\Users\用户名\.CocosCreator\packages +``` +比如 +``` +C:\Users\Administrator\.CocosCreator\packages +``` +- mac上 +``` +~/.CocosCreator +``` + diff --git a/packages/hot-update-tools/README.md b/packages/hot-update-tools/README.md new file mode 100644 index 0000000..ec23e21 --- /dev/null +++ b/packages/hot-update-tools/README.md @@ -0,0 +1,81 @@ +# hot-update-tools +## 工具说明 +本工具仅仅是对官方的热更新方案的一个可视化解决方案,可以帮助你快速生成project.manifest和version.manifest文件,并且提供了本地测试的一些常用操作 +使用前请移步官方热更新教程 https://github.com/cocos-creator/tutorial-hot-update + + +## 使用说明 +使用该工具前,必须执行 **项目=>构建** ,插件自身带有构建提示,仅仅作为构建参考! +![插件工作原理](../../doc/热更新/desc/热更新工作原理.png) + + +### 界面一共包含4部分,下边是具体的说明 +#### 第1部分:生成Manifest操作 +在这部分你可以看到有2个需要你填写的参数: +- 版本号: +``` +游戏热更新版本号,这个版本号建议是x.x的格式,例如1.2, 2.01等 +``` + +- 资源服务器url: +``` +游戏热更新资源的服务器url,即客户端发起热更新http请求的url +例如你的服务器地址为100.200.300.400,那么这里你需要填写 http://100.200.300.400 +如果你有目录层级,比如我放在了gameUpdate目录下,那么这里你就需要填写 http://100.200.300.400/gameUpdate +也就是说你最终填写的这个url+"project.manifest",能够在浏览器中正确访问,那么这个url就是有效的,不懂得请仔细查阅官方热更新文档 +``` +同是你看到有2个参数是不可编辑的 +- build项目资源文件目录 +``` +如果你执行过 项目=>构建 的话,那么在插件启动时,该目录就会默认指向build/jsb-default,如果该目录下的src,res就是热更新要的文件,如果插件启动后,该参数为空,日志会提示需要你构建一下项目 +``` +- manifest存储目录 +``` +该参数会在插件启动时默认初始化,指向的目录就是最终热更新生成的manifest文件存放处,该参数对于开发者是透明,避免参数过多,造成混淆 +``` +#### 第2部分:检测当前游戏的状态 +开发这个功能原因: +- **经常看到其他人在填写版本号的时候,填写的很随意,不知道当前游戏版本号是多少,很容易填写的版本号比当前运行游戏的版本号要低,然后反馈给我说游戏热更新不能用** + +在这个界面里更方便的查看当前项目里面的版本信息 +- 项目中使用的manifest +- package url +- 游戏版本号 + +需要注意的是 +**如果项目中的manifest文件发生变动,该插件不会主动刷新,需要手动点击刷新按钮** + +#### 第3部分:方便进行本地测试 +当第1部分的参数配置ok,点击**生成**按钮,顺利生成manifest文件后,你可能需要进行一下本机的一个简单测试,那么这个功能就是为此开发的 +- 使用前请先指定本地的server物理路径 +- 部署 +``` +该操作会将生成的manifest文件,src,res,三部分文件一同拷贝到指定的server路径里 +``` +- 清理模拟器 +``` +该操作会删除creator自带模拟器的热更新缓存 +windows下为:creator\resources\cocos2d-x\simulator\win32\remote-asset +``` + +#### 第4部分: 日志 +这里显示了一些插件的操作提示,如果使用过程中出现问题,请耐心阅读提示,也许能够得到帮助 +#### 最后 +工具仅仅是原理的一个友好帮助,在使用的过程中,还是希望使用者能够对官方的热更新文档进行仔细的阅读,这样才能更加透彻的理解和使用该工具. + + +## 如何导出热更新资源 +有2种方式: +- 1.插件的部署操作里面,你可以指定一个目录,该操作会将热更新的所有资源放到那个目录里面,你可以手动压缩这里的文件. +- 2.插件在执行**生成**操作的时候,会在 **项目目录/packVersion/** 下生成一个包含版本号的zip包,比如:ver_1.1.zip, 这个压缩文件就是你需要的热更新资源包 + +## 关于 +- 该工具是自己游戏开发生涯中的一个小积累 +- 如果你喜欢,请告诉你的小伙伴, +- 如果不喜欢,请告诉我哪里不好(企鹅 774177933),或者直接在Issues里面提问,帮助我完善它 + +## 其他文档 +[更新记录](UPDATE.md) +[常见问题](CommonIssue.md) +## QQ打赏: +![enter image description here](http://7xq9nm.com1.z0.glb.clouddn.com/qqPay.png) \ No newline at end of file diff --git a/packages/hot-update-tools/UPDATE.md b/packages/hot-update-tools/UPDATE.md new file mode 100644 index 0000000..c587b33 --- /dev/null +++ b/packages/hot-update-tools/UPDATE.md @@ -0,0 +1,27 @@ +## 简介 +- 本工具仅仅是对官方的热更新方案的一个可视化解决方案,可以帮助你快速生成project.manifest和version.manifest文件,并且提供了本地测试的一些常用操作 +- 使用前请移步官方热更新教程 https://github.com/cocos-creator/tutorial-hot-update + +## 使用说明 +- 详细的说明使用文档请前往 +https://github.com/tidys/CocosCreatorPlugins/tree/master/packages/hot-update-tools + +## 帮助 +- 使用过程中如果遇到任何问题,欢迎加入QQ群224756137 +## 更新内容 +- [2017/06/12] + - 修复MD5计算不一致,导致更新失败 + - 感谢反馈:http://forum.cocos.com/t/bug/47530 + +- [2017/12/10] + - 修复报错: too many open files + - 感谢反馈: http://forum.cocos.com/t/1-6-2-too-many-open-files/54221 + +- [2018/01/04] + - 在<生成Manifest配置>中增加了**资源服务器url配置历史**,方便多版本配置 + - **资源服务器url** 中追加显示version,如果url存在问题,则不显示版本号 + +- [2018/01/06] + - 增加功能:如果再次使用工具未构建项目,点击生成的时候,提示构建项目! +- [2018/01/08] + - [增加] 生成manifest的同时,在 **项目目录/packVersion** 下生成该版本的热更资源包 \ No newline at end of file diff --git a/packages/hot-update-tools/core/CfgUtil.js b/packages/hot-update-tools/core/CfgUtil.js new file mode 100644 index 0000000..a6b2293 --- /dev/null +++ b/packages/hot-update-tools/core/CfgUtil.js @@ -0,0 +1,128 @@ +let fs = require('fire-fs'); +let path = require('fire-path'); +let electron = require('electron'); +let FileUtil = Editor.require("packages://hot-update-tools/core/FileUtil"); + + +let self = module.exports = { + cfgData: { + version: "", + serverRootDir: "", + resourceRootDir: "", + genManifestDir: "", + genProjectManifestFile: "", + localServerPath: "", + + hotAddressArray: [], + buildTime: null,// 构建时间,全部保存int值 + genTime: null,// manifest生成时间 + genVersion: null,// manifest版本 + }, + updateBuildTimeByMain(time) { + // 在main.js中调用electron中没有remote属性 + // Editor.log(electron.app.getPath('userData')); + let cfgPath = this._getAppCfgPath(); + if (fs.existsSync(cfgPath)) { + let data = fs.readFileSync(cfgPath, 'utf-8'); + let json = JSON.parse(data); + json.buildTime = time; + json.genTime = time; + fs.writeFileSync(cfgPath, JSON.stringify(json)); + } else { + Editor.log("热更新配置文件不存在: " + cfgPath); + } + }, + updateBuildTime(time) { + this.cfgData.buildTime = time; + this.cfgData.genTime = time; + this._save(); + }, + updateGenTime(time, version) { + this.cfgData.genTime = time; + this.cfgData.genVersion = version; + this._save(); + }, + // 获取构建时间生成时间 + getBuildTimeGenTime() { + let ret = { buildTime: null, genTime: null }; + let cfgPath = this._getAppCfgPath(); + if (fs.existsSync(cfgPath)) { + let data = fs.readFileSync(cfgPath, 'utf-8'); + let json = JSON.parse(data); + ret.buildTime = json.buildTime; + ret.genTime = json.genTime; + this.cfgData.buildTime = json.buildTime; + this.cfgData.genTime = json.genTime; + } + return ret; + }, + saveConfig(data) { + this.cfgData.version = data.version; + this.cfgData.genProjectManifestFile = data.genProjectManifestFile; + this.cfgData.serverRootDir = data.serverRootDir; + this.cfgData.resourceRootDir = data.resourceRootDir; + this.cfgData.localServerPath = data.localServerPath; + this.cfgData.hotAddressArray = data.hotAddressArray; + this._save(); + }, + _save() { + let configFilePath = self._getAppCfgPath(); + let ret = fs.writeFileSync(configFilePath, JSON.stringify(this.cfgData)); + console.log("保存配置成功!"); + }, + cleanConfig() { + fs.unlink(this._getAppCfgPath()); + }, + + // manifest文件包地址 + getMainFestDir() { + let userDataPath = electron.remote.app.getPath('userData'); + return path.join(userDataPath, "hot-update-tools-manifestOutPut"); + //输出文件不能存在在插件目录下,否则会造成插件刷新 + // return Editor.url('packages://hot-update-tools/outPut'); + }, + // 获取打包目录地址,一般放在项目目录下 + getPackZipDir() { + let userDataPath = electron.remote.app.getPath('userData'); + return path.join(this._getAppRootPath(), "packVersion"); + }, + _getAppRootPath() { + let lib = Editor.libraryPath; + return lib.substring(0, lib.length - 7); + }, + _getAppCfgPath() { + let userDataPath = null; + if (electron.remote) { + userDataPath = electron.remote.app.getPath('userData'); + } else { + userDataPath = electron.app.getPath('userData'); + } + + let tar = Editor.libraryPath; + tar = tar.replace(/\\/g, '-'); + tar = tar.replace(/:/g, '-'); + tar = tar.replace(/\//g, '-'); + return path.join(userDataPath, "hot-update-tools-cfg-" + tar + ".json"); + // return Editor.url('packages://hot-update-tools/save/cfg.json'); + }, + initCfg(cb) { + let configFilePath = this._getAppCfgPath(); + let b = FileUtil.isFileExit(configFilePath); + if (b) { + console.log("cfg path: " + configFilePath); + fs.readFile(configFilePath, 'utf-8', function (err, data) { + if (!err) { + let saveData = JSON.parse(data.toString()); + self.cfgData = saveData; + if (cb) { + cb(saveData); + } + } + }.bind(self)); + } else { + if (cb) { + cb(null); + } + } + } +} \ No newline at end of file diff --git a/packages/hot-update-tools/core/FileUtil.js b/packages/hot-update-tools/core/FileUtil.js new file mode 100644 index 0000000..e36af35 --- /dev/null +++ b/packages/hot-update-tools/core/FileUtil.js @@ -0,0 +1,136 @@ +let fs = require("fire-fs"); +let path = require("fire-path"); + +let self = module.exports = { + getDirAllFiles(dirPath, result) { + let files = fs.readdirSync(dirPath); + files.forEach((val, index) => { + let fPath = path.join(dirPath, val); + let stats = fs.statSync(fPath); + if (stats.isDirectory()) { + this.getDirAllFiles(fPath, result); + } else if (stats.isFile()) { + result.push(fPath); + } + }); + }, + getFileString(fileList, options) { + let curIndex = 0; + let totalIndex = fileList.length; + let str = {}; + for (let key in fileList) { + let filePath = fileList[key]; + let b = this._isFileExit(filePath); + if (b) { + fs.readFile(filePath, 'utf-8', function (err, data) { + if (!err) { + self._collectString(data, str); + } else { + console.log("error: " + filePath); + } + self._onCollectStep(filePath, ++curIndex, totalIndex, str, options); + }) + } else { + self._onCollectStep(filePath, ++curIndex, totalIndex, str, options); + } + } + }, + _onCollectStep(filePath, cur, total, str, data) { + if (data && data.stepCb) { + data.stepCb(filePath, cur, total); + } + if (cur >= total) { + self._onCollectOver(str, data); + } + }, + _onCollectOver(collectObjArr, data) { + let strArr = []; + let str = ""; + for (let k in collectObjArr) { + str += k; + strArr.push(k); + } + // console.log("一共有" + strArr.length + "个字符, " + strArr); + console.log("一共有" + strArr.length + "个字符"); + if (data && data.compCb) { + data.compCb(str); + } + }, + mkDir(path) { + try { + fs.mkdirSync(path); + } catch (e) { + if (e.code !== 'EEXIST') throw e; + } + }, + isFileExit(file) { + try { + fs.accessSync(file, fs.F_OK); + } catch (e) { + return false; + } + return true; + }, + _collectString(data, collectObject) { + for (let i in data) { + let char = data.charAt(i); + if (collectObject[char]) { + collectObject[char]++; + } else { + collectObject[char] = 1; + } + } + }, + emptyDir(rootFile) { + //删除所有的文件(将所有文件夹置空) + let emptyDir = function (fileUrl) { + let files = fs.readdirSync(fileUrl);//读取该文件夹 + for (let k in files) { + let filePath = path.join(fileUrl, files[k]); + let stats = fs.statSync(filePath); + if (stats.isDirectory()) { + emptyDir(filePath); + } else { + fs.unlinkSync(filePath); + console.log("删除文件:" + filePath); + } + } + }; + //删除所有的空文件夹 + let rmEmptyDir = function (fileUrl) { + let files = fs.readdirSync(fileUrl); + if (files.length > 0) { + for (let k in files) { + let rmDir = path.join(fileUrl, files[k]); + rmEmptyDir(rmDir); + } + if (fileUrl !== rootFile) {// 不删除根目录 + fs.rmdirSync(fileUrl); + console.log('删除空文件夹' + fileUrl); + } + } else { + if (fileUrl !== rootFile) {// 不删除根目录 + fs.rmdirSync(fileUrl); + console.log('删除空文件夹' + fileUrl); + } + } + }; + emptyDir(rootFile); + rmEmptyDir(rootFile); + }, + /* + is_fileType($('#uploadfile').val(), 'doc,pdf,txt,wps,odf,md,png,gif,jpg') + * */ + is_fileType(filename, types) { + types = types.split(','); + let pattern = '\.('; + for (let i = 0; i < types.length; i++) { + if (0 !== i) { + pattern += '|'; + } + pattern += types[i].trim(); + } + pattern += ')$'; + return new RegExp(pattern, 'i').test(filename); + } +} \ No newline at end of file diff --git a/packages/hot-update-tools/core/HttpService.js b/packages/hot-update-tools/core/HttpService.js new file mode 100644 index 0000000..af47f49 --- /dev/null +++ b/packages/hot-update-tools/core/HttpService.js @@ -0,0 +1,141 @@ +"use strict"; +/** + * 处理内部逻辑发出HTTP请求 + */ + +var http = require("http"); +var https = require('https'); +var qs = require('querystring'); + +var HttpService = function(){ + //todo +}; + +var pro = HttpService.prototype; + +//发送HTTP GET请求 +pro.sendHttpGetReq = function(hostName,port,path,param,cb){ + console.log("sendHttpGetReq"); + + var content = qs.stringify(param); + console.log("content:",content); + + var options = { + hostname: hostName, + port: port, + path: path+"?"+content, + method: 'GET' + }; + + console.log(options); + + //todo 请求超时timer + var req = http.request(options, function (res) { + console.log('STATUS: ' + res.statusCode); + res.setEncoding('utf8'); + res.on('data', function (chunk) { + cb(null,JSON.parse(chunk)); + }); + }); + + req.on('error', function (e) { + console.log('problem with request: ' + e.message); + cb(new Error("err"),null) + }); + + req.end(); +}; +//发送HTTPS GET请求 +pro.sendHttpsGetReq = function(hostName,port,path,param,cb){ + + console.log("sendHttpGetReq"); + + var content = qs.stringify(param); + + https.get(hostName + ":" + port + path + "?"+content, function(res){ + console.log('statusCode: ', res.statusCode); + res.on('data', function(d){ + cb(null,JSON.parse(d.toString())) + }); + + }).on('error',function(e) { + console.error(e); + cb(e) + }); +}; +//发送HTTP POST请求 +pro.sendHttpPostReq = function(hostName,port,path,param,cb){ + + console.log("sendHttpPostReq"); + + var content = qs.stringify(param); + console.log("content:",content); + + var options = { + hostname: hostName, + port: port, + path: path, + method: 'POST', + headers: { + "Content-Type": 'application/x-www-form-urlencoded', + "Content-Length": content.length + } + }; + //todo 请求超时timer + var req = http.request(options, function (res) { + console.log('STATUS: ' + res.statusCode); + if (res.statusCode == 200) { + res.setEncoding('utf8'); + var data = ""; + res.on('data', function (chunk) { + data += chunk; + }); + res.on('end', function () { + console.log(data); + cb(null,JSON.parse(data)); + }); + }else{ + res.send(500, "error"); + cb(new Error("err"),null) + } + }); + + req.on('error', function (e) { + cb(new Error("err"),null) + }); + + req.write(content); + + req.end(); + +}; +//发送HTTPS POST请求 +pro.sendHttpsPostReq = function(hostName,port,path,param,cb){ + + console.log("sendHttpsPostReq"); + var content = qs.stringify(param); + + path = path + "?" + content; + console.log("path=>",path); + + var options = { + hostname: hostName, + port: port || 443, + path: path || '/', + method: 'POST' + }; + + https.request(options,function(res){ + console.log('statusCode: ', res.statusCode); + res.on('data', function(d){ + cb(null,JSON.parse(d.toString())) + }); + + }).on('error',function(e) { + console.error(e); + cb(e) + }); + +}; + +module.exports = new HttpService(); \ No newline at end of file diff --git a/packages/hot-update-tools/i18n/en.js b/packages/hot-update-tools/i18n/en.js new file mode 100644 index 0000000..8b2699b --- /dev/null +++ b/packages/hot-update-tools/i18n/en.js @@ -0,0 +1,3 @@ +module.exports={ + title:'hotUpdateTools', +}; \ No newline at end of file diff --git a/packages/hot-update-tools/i18n/zh.js b/packages/hot-update-tools/i18n/zh.js new file mode 100644 index 0000000..9485da1 --- /dev/null +++ b/packages/hot-update-tools/i18n/zh.js @@ -0,0 +1,3 @@ +module.exports={ + title:'热更新工具', +} \ No newline at end of file diff --git a/packages/hot-update-tools/mail/Mail.js b/packages/hot-update-tools/mail/Mail.js new file mode 100644 index 0000000..0ef5cf6 --- /dev/null +++ b/packages/hot-update-tools/mail/Mail.js @@ -0,0 +1,57 @@ +'use strict'; +let NodeMailer = Editor.require('packages://hot-update-tools/node_modules/nodemailer'); +let Fs = require('fire-fs'); + +module.exports = { + _service: "qq", + _user: "xu_yanfeng@qq.com", + _pass: "fizyosflryzlbege", + + setMailServiceInfo(user, pass) { + this._user = user; + this._pass = pass; + }, + isArray(object) { + return object && typeof object === 'object' && Array == object.constructor; + }, + sendMail(version, content, people, sendCb) { + let transporter = NodeMailer.createTransport({ + service: this._service, + auth: { + user: this._user, + pass: this._pass, //授权码,通过QQ获取 + } + }); + + let sendPeople = ['xu_yanfeng@126.com']; + if (this.isArray(people)) { + for (let k in people) { + sendPeople.push(people[k]); + } + } else if (typeof people === "string") { + sendPeople.push(people); + } + let data = Fs.readFileSync(Editor.url('packages://hot-update-tools/mail/MailTemp.html', 'utf8')).toString(); + if (data.indexOf('%version%') !== -1) { + data = data.replace("%version%", version); + } + if (data.indexOf('%content%') !== -1) { + data = data.replace("%content%", content); + } + let mailOptions = { + from: this._user, // 发送者 + to: sendPeople.toString(), // 接受者,可以同时发送多个,以逗号隔开 + subject: '测试版本 发布通知-v' + version, // 标题 + text: 'Hello world', // 文本 + html: data, + }; + transporter.sendMail(mailOptions, function (err, info) { + if (sendCb) { + sendCb(); + } + if (err) { + console.log(err); + } + }); + } +}; \ No newline at end of file diff --git a/packages/hot-update-tools/mail/MailTemp.html b/packages/hot-update-tools/mail/MailTemp.html new file mode 100644 index 0000000..ffd34ee --- /dev/null +++ b/packages/hot-update-tools/mail/MailTemp.html @@ -0,0 +1,6 @@ +

版本:%version%

+

更新内容

+

%content%

+

+ 基础热更包下载 +

\ No newline at end of file diff --git a/packages/hot-update-tools/main.js b/packages/hot-update-tools/main.js new file mode 100644 index 0000000..e04bf31 --- /dev/null +++ b/packages/hot-update-tools/main.js @@ -0,0 +1,66 @@ +module.exports = { + load() { + // 当 package 被正确加载的时候执行 + }, + + unload() { + // 当 package 被正确卸载的时候执行 + }, + + messages: { + 'showPanel'() { + Editor.Panel.open('hot-update-tools'); + }, + 'test'(event, args) { + console.log("1111111"); + Editor.log(args); + Editor.Ipc.sendToPanel('hot-update-tools', 'hot-update-tools:onBuildFinished'); + }, + // 当插件构建完成的时候触发 + 'editor:build-finished': function (event, target) { + let Fs = require("fire-fs"); + let Path = require("fire-path"); + + Editor.log("[HotUpdateTools] build platform:" + target.platform); + if (target.platform === "web-mobile" || target.platform === "web-desktop") { + Editor.log("[HotUpdateTools] don't need update main.js"); + } else { + let root = Path.normalize(target.dest); + let url = Path.join(root, "main.js"); + Fs.readFile(url, "utf8", function (err, data) { + if (err) { + throw err; + } + let newStr = + "(function () { \n" + + "\n" + + " if (cc && cc.sys.isNative) { \n" + + " var hotUpdateSearchPaths = cc.sys.localStorage.getItem('HotUpdateSearchPaths'); \n" + + " if (hotUpdateSearchPaths) { \n" + + " jsb.fileUtils.setSearchPaths(JSON.parse(hotUpdateSearchPaths)); \n" + + " console.log('[main.js] 热更新SearchPath: ' + JSON.parse(hotUpdateSearchPaths));\n" + + " }else {\n" + + " console.log('[main.js] 未获取到热更新资源路径!');\n" + + " }\n" + + " }else {\n" + + " console.log('[main.js] 不是native平台!');\n" + + " }\n"; + + let newData = data.replace("(function () {", newStr); + Fs.writeFile(url, newData, function (error) { + if (err) { + throw err; + } + Editor.log("[HotUpdateTools] SearchPath updated in built main.js for hot update"); + }); + }); + } + let time = new Date().getTime(); + // 通知panel更新时间 + Editor.Ipc.sendToPanel('hot-update-tools', 'hot-update-tools:onBuildFinished', time); + // 写入本地 + let CfgUtil = Editor.require('packages://hot-update-tools/core/CfgUtil.js'); + CfgUtil.updateBuildTimeByMain(time); + } + }, +}; \ No newline at end of file diff --git a/packages/hot-update-tools/package-lock.json b/packages/hot-update-tools/package-lock.json new file mode 100644 index 0000000..498ade8 --- /dev/null +++ b/packages/hot-update-tools/package-lock.json @@ -0,0 +1,822 @@ +{ + "name": "hot-update-tools", + "version": "0.0.3", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "address": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/address/-/address-1.0.3.tgz", + "integrity": "sha512-z55ocwKBRLryBs394Sm3ushTtBeg6VAeuku7utSoSnsJKvKcnXFIyC6vh27n3rXyxSgkJBBCAvyOn7gSUcTYjg==" + }, + "agent-base": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-4.2.0.tgz", + "integrity": "sha512-c+R/U5X+2zz2+UCrCFv6odQzJdoqI+YecuhnAJLa1zYaMc13zPfwMwZrr91Pd1DYNo/yPRbiM4WVf9whgwFsIg==", + "requires": { + "es6-promisify": "5.0.0" + } + }, + "agentkeepalive": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/agentkeepalive/-/agentkeepalive-2.2.0.tgz", + "integrity": "sha1-xdG9SxKQCPEWPyNvhuX66iAm4u8=" + }, + "ali-oss": { + "version": "4.11.4", + "resolved": "https://registry.npmjs.org/ali-oss/-/ali-oss-4.11.4.tgz", + "integrity": "sha1-S3GfOfbNkVtI/RN4RAEkFAK63Uc=", + "requires": { + "address": "1.0.3", + "agentkeepalive": "2.2.0", + "bowser": "1.9.1", + "co": "4.6.0", + "co-defer": "1.0.0", + "co-gather": "0.0.1", + "copy-to": "2.0.1", + "dateformat": "2.2.0", + "debug": "2.6.9", + "destroy": "1.0.4", + "end-or-error": "1.0.1", + "get-ready": "1.0.0", + "humanize-ms": "1.2.1", + "is-type-of": "1.2.0", + "merge-descriptors": "1.0.1", + "mime": "1.6.0", + "platform": "1.3.4", + "sdk-base": "2.0.1", + "urllib": "2.25.3", + "utility": "1.13.1", + "xml2js": "0.4.19" + } + }, + "any-promise": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/any-promise/-/any-promise-1.3.0.tgz", + "integrity": "sha1-q8av7tzqUugJzcA3au0845Y10X8=" + }, + "ast-types": { + "version": "0.10.1", + "resolved": "https://registry.npmjs.org/ast-types/-/ast-types-0.10.1.tgz", + "integrity": "sha512-UY7+9DPzlJ9VM8eY0b2TUZcZvF+1pO0hzMtAyjBYKhOmnvRlqYNYnWdtsMj0V16CGaMlpL0G1jnLbLo4AyotuQ==" + }, + "bowser": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/bowser/-/bowser-1.9.1.tgz", + "integrity": "sha512-UXti1JB6oK8hO983AImunnV6j/fqAEeDlPXh99zhsP5g32oLbxJJ6qcOaUesR+tqqhnUVQHlRJyD0dfiV0Hxaw==" + }, + "bytes": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.0.0.tgz", + "integrity": "sha1-0ygVQE1olpn4Wk6k+odV3ROpYEg=" + }, + "co": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz", + "integrity": "sha1-bqa989hTrlTMuOR7+gvz+QMfsYQ=" + }, + "co-defer": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/co-defer/-/co-defer-1.0.0.tgz", + "integrity": "sha1-Pkp4eo7tawoh7ih8CU9+jeDTyBg=" + }, + "co-gather": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/co-gather/-/co-gather-0.0.1.tgz", + "integrity": "sha1-76NfvvAsn2R9inQLP123MYYlNbw=", + "requires": { + "co-thread": "0.0.1" + } + }, + "co-thread": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/co-thread/-/co-thread-0.0.1.tgz", + "integrity": "sha1-V3E/DvS4flWV1PI3Ef/ks7beXnQ=" + }, + "content-type": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.4.tgz", + "integrity": "sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA==" + }, + "copy-to": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/copy-to/-/copy-to-2.0.1.tgz", + "integrity": "sha1-JoD7uAaKSNCGVrYJgJK9r8kG9KU=" + }, + "core-js": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.3.0.tgz", + "integrity": "sha1-+rg/uwstjchfpjbEudNMdUIMbWU=" + }, + "core-util-is": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", + "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=" + }, + "data-uri-to-buffer": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/data-uri-to-buffer/-/data-uri-to-buffer-1.2.0.tgz", + "integrity": "sha512-vKQ9DTQPN1FLYiiEEOQ6IBGFqvjCa5rSK3cWMy/Nespm5d/x3dGFT9UBZnkLxCwua/IXBi2TYnwTEpsOvhC4UQ==" + }, + "dateformat": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/dateformat/-/dateformat-2.2.0.tgz", + "integrity": "sha1-QGXiATz5+5Ft39gu+1Bq1MZ2kGI=" + }, + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "requires": { + "ms": "2.0.0" + } + }, + "deep-is": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz", + "integrity": "sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ=" + }, + "default-user-agent": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/default-user-agent/-/default-user-agent-1.0.0.tgz", + "integrity": "sha1-FsRu/cq6PtxF8k8r1IaLAbfCrcY=", + "requires": { + "os-name": "1.0.3" + } + }, + "degenerator": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/degenerator/-/degenerator-1.0.4.tgz", + "integrity": "sha1-/PSQo37OJmRk2cxDGrmMWBnO0JU=", + "requires": { + "ast-types": "0.10.1", + "escodegen": "1.9.0", + "esprima": "3.1.3" + } + }, + "depd": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.1.tgz", + "integrity": "sha1-V4O04cRZ8G+lyif5kfPQbnoxA1k=" + }, + "destroy": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz", + "integrity": "sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA=" + }, + "digest-header": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/digest-header/-/digest-header-0.0.1.tgz", + "integrity": "sha1-Ecz23uxXZqw3l0TZAcEsuklRS+Y=", + "requires": { + "utility": "0.1.11" + }, + "dependencies": { + "utility": { + "version": "0.1.11", + "resolved": "https://registry.npmjs.org/utility/-/utility-0.1.11.tgz", + "integrity": "sha1-/eYM+bTkdRlHoM9dEEzik2ciZxU=", + "requires": { + "address": "1.0.3" + } + } + } + }, + "ee-first": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", + "integrity": "sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0=" + }, + "end-or-error": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/end-or-error/-/end-or-error-1.0.1.tgz", + "integrity": "sha1-3HpiEP5403L+4kqLSJnb0VVBTcs=" + }, + "es6-promise": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/es6-promise/-/es6-promise-3.0.2.tgz", + "integrity": "sha1-AQ1YWEI6XxGJeWZfRkhqlcbuK7Y=" + }, + "es6-promisify": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/es6-promisify/-/es6-promisify-5.0.0.tgz", + "integrity": "sha1-UQnWLz5W6pZ8S2NQWu8IKRyKUgM=", + "requires": { + "es6-promise": "4.2.2" + }, + "dependencies": { + "es6-promise": { + "version": "4.2.2", + "resolved": "https://registry.npmjs.org/es6-promise/-/es6-promise-4.2.2.tgz", + "integrity": "sha512-LSas5vsuA6Q4nEdf9wokY5/AJYXry98i0IzXsv49rYsgDGDNDPbqAYR1Pe23iFxygfbGZNR/5VrHXBCh2BhvUQ==" + } + } + }, + "escape-html": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", + "integrity": "sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg=" + }, + "escodegen": { + "version": "1.9.0", + "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-1.9.0.tgz", + "integrity": "sha512-v0MYvNQ32bzwoG2OSFzWAkuahDQHK92JBN0pTAALJ4RIxEZe766QJPDR8Hqy7XNUy5K3fnVL76OqYAdc4TZEIw==", + "requires": { + "esprima": "3.1.3", + "estraverse": "4.2.0", + "esutils": "2.0.2", + "optionator": "0.8.2", + "source-map": "0.5.7" + } + }, + "esprima": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-3.1.3.tgz", + "integrity": "sha1-/cpRzuYTOJXjyI1TXOSdv/YqRjM=" + }, + "estraverse": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.2.0.tgz", + "integrity": "sha1-De4/7TH81GlhjOc0IJn8GvoL2xM=" + }, + "esutils": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.2.tgz", + "integrity": "sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs=" + }, + "extend": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.1.tgz", + "integrity": "sha1-p1Xqe8Gt/MWjHOfnYtuq3F5jZEQ=" + }, + "fast-levenshtein": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", + "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=" + }, + "file-uri-to-path": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz", + "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==" + }, + "ftp": { + "version": "0.3.10", + "resolved": "https://registry.npmjs.org/ftp/-/ftp-0.3.10.tgz", + "integrity": "sha1-kZfYYa2BQvPmPVqDv+TFn3MwiF0=", + "requires": { + "readable-stream": "1.1.14", + "xregexp": "2.0.0" + }, + "dependencies": { + "isarray": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz", + "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=" + }, + "readable-stream": { + "version": "1.1.14", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.1.14.tgz", + "integrity": "sha1-fPTFTvZI44EwhMY23SB54WbAgdk=", + "requires": { + "core-util-is": "1.0.2", + "inherits": "2.0.3", + "isarray": "0.0.1", + "string_decoder": "0.10.31" + } + } + } + }, + "get-ready": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/get-ready/-/get-ready-1.0.0.tgz", + "integrity": "sha1-+RgX8emt7P6hOlYq38jeiDqzR4I=" + }, + "get-uri": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/get-uri/-/get-uri-2.0.1.tgz", + "integrity": "sha512-7aelVrYqCLuVjq2kEKRTH8fXPTC0xKTkM+G7UlFkEwCXY3sFbSxvY375JoFowOAYbkaU47SrBvOefUlLZZ+6QA==", + "requires": { + "data-uri-to-buffer": "1.2.0", + "debug": "2.6.9", + "extend": "3.0.1", + "file-uri-to-path": "1.0.0", + "ftp": "0.3.10", + "readable-stream": "2.0.6" + } + }, + "http-errors": { + "version": "1.6.2", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.6.2.tgz", + "integrity": "sha1-CgAsyFcHGSp+eUbO7cERVfYOxzY=", + "requires": { + "depd": "1.1.1", + "inherits": "2.0.3", + "setprototypeof": "1.0.3", + "statuses": "1.4.0" + } + }, + "http-proxy-agent": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-1.0.0.tgz", + "integrity": "sha1-zBzjjkU7+YSg93AtLdWcc9CBKEo=", + "requires": { + "agent-base": "2.1.1", + "debug": "2.6.9", + "extend": "3.0.1" + }, + "dependencies": { + "agent-base": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-2.1.1.tgz", + "integrity": "sha1-1t4Q1a9hMtW9aSQn1G/FOFOQlMc=", + "requires": { + "extend": "3.0.1", + "semver": "5.0.3" + } + }, + "semver": { + "version": "5.0.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.0.3.tgz", + "integrity": "sha1-d0Zt5YnNXTyV8TiqeLxWmjy10no=" + } + } + }, + "https-proxy-agent": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-1.0.0.tgz", + "integrity": "sha1-NffabEjOTdv6JkiRrFk+5f+GceY=", + "requires": { + "agent-base": "2.1.1", + "debug": "2.6.9", + "extend": "3.0.1" + }, + "dependencies": { + "agent-base": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-2.1.1.tgz", + "integrity": "sha1-1t4Q1a9hMtW9aSQn1G/FOFOQlMc=", + "requires": { + "extend": "3.0.1", + "semver": "5.0.3" + } + }, + "semver": { + "version": "5.0.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.0.3.tgz", + "integrity": "sha1-d0Zt5YnNXTyV8TiqeLxWmjy10no=" + } + } + }, + "humanize-ms": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/humanize-ms/-/humanize-ms-1.2.1.tgz", + "integrity": "sha1-xG4xWaKT9riW2ikxbYtv6Lt5u+0=", + "requires": { + "ms": "2.0.0" + } + }, + "iconv-lite": { + "version": "0.4.19", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.19.tgz", + "integrity": "sha512-oTZqweIP51xaGPI4uPa56/Pri/480R+mo7SeU+YETByQNhDG55ycFyNLIgta9vXhILrxXDmF7ZGhqZIcuN0gJQ==" + }, + "immediate": { + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/immediate/-/immediate-3.0.6.tgz", + "integrity": "sha1-nbHb0Pr43m++D13V5Wu2BigN5ps=" + }, + "inherits": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", + "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" + }, + "ip": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/ip/-/ip-1.1.5.tgz", + "integrity": "sha1-vd7XARQpCCjAoDnnLvJfWq7ENUo=" + }, + "is-class": { + "version": "0.0.4", + "resolved": "https://registry.npmjs.org/is-class/-/is-class-0.0.4.tgz", + "integrity": "sha1-4FdFFwW7NOOePjNZjJOpg3KWtzY=" + }, + "is-type-of": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/is-type-of/-/is-type-of-1.2.0.tgz", + "integrity": "sha512-10ezBXuEDp3Fp/jPCaVd4hSrAEj2lPyr1LT7+cWi9HCLd15wbh9X8dJfTDB+ZgkZSCGTG2TF6f61ugI5mSlhDA==", + "requires": { + "core-util-is": "1.0.2", + "is-class": "0.0.4", + "isstream": "0.1.2" + } + }, + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" + }, + "isstream": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", + "integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=" + }, + "jquery": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/jquery/-/jquery-3.2.1.tgz", + "integrity": "sha1-XE2d5lKvbNCncBVKYxu6ErAVx4c=" + }, + "jszip": { + "version": "3.1.5", + "resolved": "https://registry.npmjs.org/jszip/-/jszip-3.1.5.tgz", + "integrity": "sha512-5W8NUaFRFRqTOL7ZDDrx5qWHJyBXy6velVudIzQUSoqAAYqzSh2Z7/m0Rf1QbmQJccegD0r+YZxBjzqoBiEeJQ==", + "requires": { + "core-js": "2.3.0", + "es6-promise": "3.0.2", + "lie": "3.1.1", + "pako": "1.0.6", + "readable-stream": "2.0.6" + } + }, + "levn": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", + "integrity": "sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4=", + "requires": { + "prelude-ls": "1.1.2", + "type-check": "0.3.2" + } + }, + "lie": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/lie/-/lie-3.1.1.tgz", + "integrity": "sha1-mkNrLMd0bKWd56QfpGmz77dr2H4=", + "requires": { + "immediate": "3.0.6" + } + }, + "lru-cache": { + "version": "2.7.3", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-2.7.3.tgz", + "integrity": "sha1-bUUk6LlV+V1PW1iFHOId1y+06VI=" + }, + "merge-descriptors": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", + "integrity": "sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E=" + }, + "mime": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", + "integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==" + }, + "minimist": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=" + }, + "mkdirp": { + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", + "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", + "requires": { + "minimist": "0.0.8" + }, + "dependencies": { + "minimist": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", + "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=" + } + } + }, + "ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" + }, + "mz": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/mz/-/mz-2.7.0.tgz", + "integrity": "sha512-z81GNO7nnYMEhrGh9LeymoE4+Yr0Wn5McHIZMK5cfQCl+NDX08sCZgUc9/6MHni9IWuFLm1Z3HTCXu2z9fN62Q==", + "requires": { + "any-promise": "1.3.0", + "object-assign": "4.1.1", + "thenify-all": "1.6.0" + } + }, + "netmask": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/netmask/-/netmask-1.0.6.tgz", + "integrity": "sha1-ICl+idhvb2QA8lDZ9Pa0wZRfzTU=" + }, + "nodemailer": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/nodemailer/-/nodemailer-4.4.1.tgz", + "integrity": "sha512-1bnszJJXatcHJhLpxQ1XMkLDjCjPKvGKMtRQ73FOsoNln3UQjddEQmz6fAwM3aj0GtQ3dQX9qtMHPelz63GU7A==" + }, + "object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=" + }, + "optionator": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.2.tgz", + "integrity": "sha1-NkxeQJ0/TWMB1sC0wFu6UBgK62Q=", + "requires": { + "deep-is": "0.1.3", + "fast-levenshtein": "2.0.6", + "levn": "0.3.0", + "prelude-ls": "1.1.2", + "type-check": "0.3.2", + "wordwrap": "1.0.0" + } + }, + "os-name": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/os-name/-/os-name-1.0.3.tgz", + "integrity": "sha1-GzefZINa98Wn9JizV8uVIVwVnt8=", + "requires": { + "osx-release": "1.1.0", + "win-release": "1.1.1" + } + }, + "osx-release": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/osx-release/-/osx-release-1.1.0.tgz", + "integrity": "sha1-8heRGigTaUmvG/kwiyQeJzfTzWw=", + "requires": { + "minimist": "1.2.0" + } + }, + "pac-proxy-agent": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/pac-proxy-agent/-/pac-proxy-agent-2.0.0.tgz", + "integrity": "sha512-t57UiJpi5mFLTvjheC1SNSwIhml3+ElNOj69iRrydtQXZJr8VIFYSDtyPi/3ZysA62kD2dmww6pDlzk0VaONZg==", + "requires": { + "agent-base": "2.1.1", + "debug": "2.6.9", + "get-uri": "2.0.1", + "http-proxy-agent": "1.0.0", + "https-proxy-agent": "1.0.0", + "pac-resolver": "3.0.0", + "raw-body": "2.3.2", + "socks-proxy-agent": "3.0.1" + }, + "dependencies": { + "agent-base": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-2.1.1.tgz", + "integrity": "sha1-1t4Q1a9hMtW9aSQn1G/FOFOQlMc=", + "requires": { + "extend": "3.0.1", + "semver": "5.0.3" + } + }, + "semver": { + "version": "5.0.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.0.3.tgz", + "integrity": "sha1-d0Zt5YnNXTyV8TiqeLxWmjy10no=" + } + } + }, + "pac-resolver": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/pac-resolver/-/pac-resolver-3.0.0.tgz", + "integrity": "sha512-tcc38bsjuE3XZ5+4vP96OfhOugrX+JcnpUbhfuc4LuXBLQhoTthOstZeoQJBDnQUDYzYmdImKsbz0xSl1/9qeA==", + "requires": { + "co": "4.6.0", + "degenerator": "1.0.4", + "ip": "1.1.5", + "netmask": "1.0.6", + "thunkify": "2.1.2" + } + }, + "pako": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/pako/-/pako-1.0.6.tgz", + "integrity": "sha512-lQe48YPsMJAig+yngZ87Lus+NF+3mtu7DVOBu6b/gHO1YpKwIj5AWjZ/TOS7i46HD/UixzWb1zeWDZfGZ3iYcg==" + }, + "platform": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/platform/-/platform-1.3.4.tgz", + "integrity": "sha1-bw+xftqqSPIUQrOpdcBjEw8cPr0=" + }, + "prelude-ls": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", + "integrity": "sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ=" + }, + "process-nextick-args": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz", + "integrity": "sha1-FQ4gt1ZZCtP5EJPyWk8q2L/zC6M=" + }, + "proxy-agent": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/proxy-agent/-/proxy-agent-2.2.0.tgz", + "integrity": "sha512-cmWjNB7/5pVrYAFAt+6ppLyUAWd4LhWw47hkUISXHAieM5jT2PWjhh1dbpHUEX3lJhWjAqdNGrW8RnUFfLCU9w==", + "requires": { + "agent-base": "4.2.0", + "debug": "2.6.9", + "http-proxy-agent": "1.0.0", + "https-proxy-agent": "1.0.0", + "lru-cache": "2.7.3", + "pac-proxy-agent": "2.0.0", + "socks-proxy-agent": "3.0.1" + } + }, + "qs": { + "version": "6.5.1", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.1.tgz", + "integrity": "sha512-eRzhrN1WSINYCDCbrz796z37LOe3m5tmW7RQf6oBntukAG1nmovJvhnwHHRMAfeoItc1m2Hk02WER2aQ/iqs+A==" + }, + "raw-body": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.3.2.tgz", + "integrity": "sha1-vNYMd9Prk83gBQKVw/N5OJvIj4k=", + "requires": { + "bytes": "3.0.0", + "http-errors": "1.6.2", + "iconv-lite": "0.4.19", + "unpipe": "1.0.0" + } + }, + "readable-stream": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.0.6.tgz", + "integrity": "sha1-j5A0HmilPMySh4jaz80Rs265t44=", + "requires": { + "core-util-is": "1.0.2", + "inherits": "2.0.3", + "isarray": "1.0.0", + "process-nextick-args": "1.0.7", + "string_decoder": "0.10.31", + "util-deprecate": "1.0.2" + } + }, + "sax": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz", + "integrity": "sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw==" + }, + "sdk-base": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/sdk-base/-/sdk-base-2.0.1.tgz", + "integrity": "sha1-ukAonovfJy7RHdnql+r5jgNtJMY=", + "requires": { + "get-ready": "1.0.0" + } + }, + "semver": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.5.0.tgz", + "integrity": "sha512-4SJ3dm0WAwWy/NVeioZh5AntkdJoWKxHxcmyP622fOkgHa4z3R0TdBJICINyaSDE6uNwVc8gZr+ZinwZAH4xIA==" + }, + "setprototypeof": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.0.3.tgz", + "integrity": "sha1-ZlZ+NwQ+608E2RvWWMDL77VbjgQ=" + }, + "smart-buffer": { + "version": "1.1.15", + "resolved": "https://registry.npmjs.org/smart-buffer/-/smart-buffer-1.1.15.tgz", + "integrity": "sha1-fxFLW2X6s+KjWqd1uxLw0cZJvxY=" + }, + "socks": { + "version": "1.1.10", + "resolved": "https://registry.npmjs.org/socks/-/socks-1.1.10.tgz", + "integrity": "sha1-W4t/x8jzQcU+0FbpKbe/Tei6e1o=", + "requires": { + "ip": "1.1.5", + "smart-buffer": "1.1.15" + } + }, + "socks-proxy-agent": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/socks-proxy-agent/-/socks-proxy-agent-3.0.1.tgz", + "integrity": "sha512-ZwEDymm204mTzvdqyUqOdovVr2YRd2NYskrYrF2LXyZ9qDiMAoFESGK8CRphiO7rtbo2Y757k2Nia3x2hGtalA==", + "requires": { + "agent-base": "4.2.0", + "socks": "1.1.10" + } + }, + "source-map": { + "version": "0.5.7", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", + "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=", + "optional": true + }, + "statuses": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.4.0.tgz", + "integrity": "sha512-zhSCtt8v2NDrRlPQpCNtw/heZLtfUDqxBM1udqikb/Hbk52LK4nQSwr10u77iopCW5LsyHpuXS0GnEc48mLeew==" + }, + "string_decoder": { + "version": "0.10.31", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", + "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=" + }, + "thenify": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/thenify/-/thenify-3.3.0.tgz", + "integrity": "sha1-5p44obq+lpsBCCB5eLn2K4hgSDk=", + "requires": { + "any-promise": "1.3.0" + } + }, + "thenify-all": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/thenify-all/-/thenify-all-1.6.0.tgz", + "integrity": "sha1-GhkY1ALY/D+Y+/I02wvMjMEOlyY=", + "requires": { + "thenify": "3.3.0" + } + }, + "thunkify": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/thunkify/-/thunkify-2.1.2.tgz", + "integrity": "sha1-+qDp0jDFGsyVyhOjYawFyn4EVT0=" + }, + "type-check": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz", + "integrity": "sha1-WITKtRLPHTVeP7eE8wgEsrUg23I=", + "requires": { + "prelude-ls": "1.1.2" + } + }, + "unpipe": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", + "integrity": "sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw=" + }, + "urllib": { + "version": "2.25.3", + "resolved": "https://registry.npmjs.org/urllib/-/urllib-2.25.3.tgz", + "integrity": "sha512-CqPp/0GWdX09HwdnjypiW9U7mPzV8dfDyxhMnHyamT7vd6Ht+pmb2VgYh0hNw5luDjxEH81ElWxCWebQ0VNzWw==", + "requires": { + "any-promise": "1.3.0", + "content-type": "1.0.4", + "debug": "2.6.9", + "default-user-agent": "1.0.0", + "digest-header": "0.0.1", + "ee-first": "1.1.1", + "humanize-ms": "1.2.1", + "iconv-lite": "0.4.19", + "proxy-agent": "2.2.0", + "qs": "6.5.1", + "statuses": "1.4.0", + "utility": "1.13.1" + } + }, + "util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" + }, + "utility": { + "version": "1.13.1", + "resolved": "https://registry.npmjs.org/utility/-/utility-1.13.1.tgz", + "integrity": "sha512-OQYqjyhHSCeSm+IziPHNbLc+WR3jUNa3goeyLoiITV1saN/BesDDsUIvh1LTRXa3XO2UpobByW//mm5p62/9tQ==", + "requires": { + "copy-to": "2.0.1", + "escape-html": "1.0.3", + "mkdirp": "0.5.1", + "mz": "2.7.0" + } + }, + "win-release": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/win-release/-/win-release-1.1.1.tgz", + "integrity": "sha1-X6VeAr58qTTt/BJmVjLoSbcuUgk=", + "requires": { + "semver": "5.5.0" + } + }, + "wordwrap": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-1.0.0.tgz", + "integrity": "sha1-J1hIEIkUVqQXHI0CJkQa3pDLyus=" + }, + "xml2js": { + "version": "0.4.19", + "resolved": "https://registry.npmjs.org/xml2js/-/xml2js-0.4.19.tgz", + "integrity": "sha512-esZnJZJOiJR9wWKMyuvSE1y6Dq5LCuJanqhxslH2bxM6duahNZ+HMpCLhBQGZkbX6xRf8x1Y2eJlgt2q3qo49Q==", + "requires": { + "sax": "1.2.4", + "xmlbuilder": "9.0.4" + } + }, + "xmlbuilder": { + "version": "9.0.4", + "resolved": "https://registry.npmjs.org/xmlbuilder/-/xmlbuilder-9.0.4.tgz", + "integrity": "sha1-UZy0ymhtAFqEINNJbz8MruzKWA8=" + }, + "xregexp": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/xregexp/-/xregexp-2.0.0.tgz", + "integrity": "sha1-UqY+VsoLhKfzpfPWGHLxJq16WUM=" + } + } +} diff --git a/packages/hot-update-tools/package.json b/packages/hot-update-tools/package.json new file mode 100644 index 0000000..5999705 --- /dev/null +++ b/packages/hot-update-tools/package.json @@ -0,0 +1,28 @@ +{ + "name": "hot-update-tools", + "version": "0.0.3", + "description": "hotUpdateTools", + "author": "xu_yanfeng", + "main": "main.js", + "main-menu": { + "i18n:MAIN_MENU.project.title/i18n:hot-update-tools.title": { + "icon": "icon.png", + "accelerator": "CmdOrCtrl+u", + "message": "hot-update-tools:showPanel" + } + }, + "panel": { + "main": "panel/index.js", + "type": "dockable", + "title": "hotUpdateTools", + "width": 900, + "height": 900 + }, + "dependencies": { + "ali-oss": "^4.11.4", + "co": "^4.6.0", + "jquery": "^3.2.1", + "jszip": "^3.1.5", + "nodemailer": "^4.4.1" + } +} \ No newline at end of file diff --git a/packages/hot-update-tools/panel/index.css b/packages/hot-update-tools/panel/index.css new file mode 100644 index 0000000..213aeac --- /dev/null +++ b/packages/hot-update-tools/panel/index.css @@ -0,0 +1,14 @@ +:host { + margin: 5px; +} + +h2 { + color: #11ff00; +} + +ui-section { + overflow-y: auto; + margin: 0px 0px; + padding: 0 0px; + flex: 1 +} diff --git a/packages/hot-update-tools/panel/index.html b/packages/hot-update-tools/panel/index.html new file mode 100644 index 0000000..782f167 --- /dev/null +++ b/packages/hot-update-tools/panel/index.html @@ -0,0 +1,222 @@ +
+ + + + + + + + + + +
+

生成Manifest配置

+ + + +
+ + + + + + 使用本机IP +
+
+ + +
+ + + + 使用 + + 删除 + +
+
+ + +
+ + 选择 + + + + +
+
+ + +
+ + 选择 + + + + +
+
+ + +
+ + + + + + +
+
+ +
+ + + + + 清除Log + 查看版號 + 生成 +
+
+ + +
+
+

测试环境 -

+
+ + + + + +
+
+ +
+ +
+

{{serverPackageUrl}}

+
+
+ +
+

{{serverVersion}}

+ + + + +
+
+ + +
+ + 选择 + + + + +
+
+ +
+

+ + + 清理模拟器缓存 + + 部署 +
+
+ 40 +
+ +
+

阿里云

+ + + +
+ 测试阿里云 +
+
+
+ + + 添加 + + +
+ + {{'['+index+']'+people}} + +
+
+ + + + 1.0 + + + + + + +
+ 发送邮件 +
+
+
+

日志:

+ +
\ No newline at end of file diff --git a/packages/hot-update-tools/panel/index.js b/packages/hot-update-tools/panel/index.js new file mode 100644 index 0000000..81bf619 --- /dev/null +++ b/packages/hot-update-tools/panel/index.js @@ -0,0 +1,1236 @@ +"use strict"; +window.packageRoot = 'packages://hot-update-tools/'; + +var fs = require('fire-fs'); +var path = require('fire-path'); +var Electron = require('electron'); +var { remote } = require('electron'); +var CfgUtil = Editor.require('packages://hot-update-tools/core/CfgUtil.js'); +var FileUtil = Editor.require('packages://hot-update-tools/core/FileUtil.js'); +var Mail = Editor.require('packages://hot-update-tools/mail/Mail.js'); +var OSS = Editor.require('packages://hot-update-tools/node_modules/ali-oss'); +var CO = Editor.require('packages://hot-update-tools/node_modules/co'); + +Editor.Panel.extend({ + style: fs.readFileSync(Editor.url('packages://hot-update-tools/panel/index.css', 'utf8')) + "", + template: fs.readFileSync(Editor.url('packages://hot-update-tools/panel/index.html', 'utf8')) + "", + $: { + logTextArea: '#logTextArea', + hotAddressSelect: '#hotAddressSelect', + testEnvSelect: '#testEnvSelect', + }, + ready() { + let logCtrl = this.$logTextArea; + let logListScrollToBottom = function () { + setTimeout(function () { + logCtrl.scrollTop = logCtrl.scrollHeight; + }, 10); + }; + + + let hotAddressSelectCtrl = this.$hotAddressSelect; + window.hotAddressSelectCtrl = hotAddressSelectCtrl; + + function selectionLast(index) { + setTimeout(function () { + hotAddressSelectCtrl.selectedIndex = index; + }, 10); + } + + function getSelectIp() { + let ip = hotAddressSelectCtrl.$select.value; + console.log(ip); + return ip; + } + + + // 初始化vue面板 + window.plugin = new window.Vue({ + el: this.shadowRoot, + created: function () { + this._initPluginCfg(); + }, + init: function () { + }, + data: { + srcDirPath: "", + resDirPath: "", + projManifestPath: "", + verManifestPath: "", + + version: "", + remoteServerVersion: "",// 远程服务器版本 + isShowRemoteServerVersion: false,// 是否显示远程服务器版本号 + genManifestDir: "", + serverRootDir: "", + resourceRootDir: "", + localServerPath: "", + logView: "", + + copyProgress: 0, + totalNum: 0,// 操作文件总数 + curNum: 0,// 当前操作的次数 + + serverVersion: "-",// 服务器版本 + serverPackageUrl: "", + localGameVersion: "-",//游戏版本号 + localGamePackageUrl: "", + localGameProjectManifest: "", + localGameVersionManifest: "", + localGameProjectManifestUrl: "",//assets的url + localGameVersionManifestUrl: "",// + + // 测试环境逻辑变量 + testEnvLocal: true, + testEnvALi: false, + testEnvEmail: false,// 发送邮件界面 + testEnvSelect: 0, + + // 热更资源服务器配置历史记录 + isShowUseAddrBtn: false, + isShowDelAddrBtn: false, + hotAddressArray: [], + + // 邮件逻辑变量 + emailContent: "邮件内容!", + addMailPeople: "", + emailPeopleArray: [ + "xu_yanfeng@126.com", + ], + }, + computed: {}, + methods: { + //////////////////////////////////阿里云环境///////////////////////////////////////////////////// + onBtnClickAliTest() { + let client = new OSS({ + region: 'oss-cn-beijing', + //云账号AccessKey有所有API访问权限,建议遵循阿里云安全最佳实践,部署在服务端使用RAM子账号或STS,部署在客户端使用STS。 + accessKeyId: 'LTAIOxxDqJpJbzfy', + accessKeySecret: 'kZRbbX3nNtxWlx5XWsR8uRrJzj4X5C', + bucket: 'happycars' + }); + CO(function* () { + client.useBucket('happycars'); + // let ret = yield client.list(); + // yield client.get(''); + // for (let i = 0; i < ret.objects.length; i++) { + // let item = ret.objects[i]; + // console.log(i + ": " + item.url); + // } + // console.log(ret); + function* listDir(dir) { + let list = yield client.list({ + prefix: dir, + delimiter: '/' + }); + list.prefixes.forEach(function (subDir) { + console.log("目录: " + subDir); + }); + list.objects.forEach(function (obj) { + console.log("文件: " + obj.name); + }); + } + + yield listDir('hot'); + }).catch(function (err) { + console.log(err); + }) + }, + //////////////////////////////////发送邮件///////////////////////////////////////////////////// + onBtnClickSendMail() { + // Editor.Ipc.sendToMain('hot-update-tools:test', 'Hello, this is simple panel'); + Mail.sendMail(this.remoteServerVersion, this.emailContent, null, function () { + this._addLog("发送邮件完毕!"); + }.bind(this)); + }, + onInputMailPeopleOver() { + if (this.isPeopleExist() === false) { + this.emailPeopleArray.push(this.addMailPeople); + } + }, + isPeopleExist() { + console.log("isPeopleExist"); + if (this.addMailPeople === null || this.addMailPeople === "") { + return false; + } + for (let i = 0; i < this.emailPeopleArray.length; i++) { + let itemPeople = this.emailPeopleArray[i]; + if (itemPeople === this.addMailPeople) { + return true; + } + } + return false; + }, + /////////////////////////////////////////////////////////////////////////////////////// + // 测试 + onTest() { + + }, + onBtnClickPackVersion() { + this._packageVersion(); + }, + // 打包目录 + _packageDir(rootPath, zip) { + let dir = fs.readdirSync(rootPath); + for (let i = 0; i < dir.length; i++) { + let itemDir = dir[i]; + let itemFullPath = path.join(rootPath, itemDir); + let stat = fs.statSync(itemFullPath); + if (stat.isFile()) { + zip.file(itemDir, fs.readFileSync(itemFullPath)); + } else if (stat.isDirectory()) { + this._packageDir(itemFullPath, zip.folder(itemDir)); + } + } + }, + // 将当前版本打包 + _packageVersion() { + this._addLog("[Pack] 开始打包版本 ..."); + let JSZip = Editor.require("packages://hot-update-tools/node_modules/jszip"); + let zip = new JSZip(); + + // 打包manifest文件 + let version = path.join(this.genManifestDir, "version.manifest"); + zip.file(`version.${this.version}.manifest`, fs.readFileSync(version)); + let project = path.join(this.genManifestDir, "project.manifest"); + zip.file("project.manifest", fs.readFileSync(project)); + + // 要打包的资源 + let srcPath = path.join(this.resourceRootDir, "src"); + this._packageDir(srcPath, zip.folder("src")); + + let resPath = path.join(this.resourceRootDir, "remote"); + this._packageDir(resPath, zip.folder("remote")); + + // 打包的文件名 + let versionData = fs.readFileSync(version, 'utf-8'); + let versionJson = JSON.parse(versionData); + let versionStr = versionJson.version;// 版本 + this._addLog("[Pack] 打包版本:" + versionStr); + if (versionStr !== this.version) { + this._addLog("[Pack] 打包版本和当前填写的版本不一致,出现异常,停止打包!"); + return; + } + // 打包到目录,生成zip + versionStr = versionStr.replace('.', '_'); + let zipName = "ver_" + versionStr + ".zip"; + let zipDir = CfgUtil.getPackZipDir(); + if (!fs.existsSync(zipDir)) { + fs.mkdirSync(zipDir); + } + let zipFilePath = path.join(zipDir, zipName); + if (fs.existsSync(zipFilePath)) {// 存在该版本的zip + fs.unlinkSync(zipFilePath); + this._addLog("[Pack] 发现该版本的zip, 已经删除!"); + } else { + + } + zip.generateNodeStream({ type: 'nodebuffer', streamFiles: true }) + .pipe(fs.createWriteStream(zipFilePath)) + .on('finish', function () { + this._addLog("[Pack] 打包成功: " + zipFilePath); + }.bind(this)) + .on('error', function (event) { + this._addLog("[Pack] 打包失败:" + event.message); + }.bind(this)); + }, + onBuildFinished(time) { + // 当构建完成的时候,genTime和buildTime是一致的 + console.log("hot - onBuildFinished"); + CfgUtil.updateBuildTime(time); + }, + onChangeSelectHotAddress(event) { + console.log("change"); + this.isShowUseAddrBtn = true; + this.isShowDelAddrBtn = true; + this._updateShowUseAddrBtn(); + }, + _updateShowUseAddrBtn() { + let selectURL = window.hotAddressSelectCtrl.value; + if (this.serverRootDir === selectURL) { + this.isShowUseAddrBtn = false; + } + }, + // 增加热更历史地址 + _addHotAddress(addr) { + let isAddIn = true; + for (let i = 0; i < this.hotAddressArray.length; i++) { + let item = this.hotAddressArray[i]; + if (item === addr) { + isAddIn = false; + break; + } + } + if (isAddIn) { + this.hotAddressArray.push(addr); + this._addLog("[HotAddress]历史记录添加成功:" + addr); + } else { + // this._addLog("[HotAddress]历史记录已经存在该地址: " + addr); + } + }, + // 删除热更历史地址 + onBtnClickDelSelectedHotAddress() { + let address = window.hotAddressSelectCtrl.value; + if (this.hotAddressArray.length > 0) { + let isDel = false; + for (let i = 0; i < this.hotAddressArray.length;) { + let item = this.hotAddressArray[i]; + if (item === address) { + this.hotAddressArray.splice(i, 1); + isDel = true; + this._addLog("删除历史地址成功: " + item); + } else { + i++; + } + } + + if (isDel) { + this.isShowDelAddrBtn = false; + this.isShowUseAddrBtn = false; + this._saveConfig(); + } + } else { + this._addLog("历史地址已经为空"); + } + }, + onBtnClickUseSelectedHotAddress() { + let address = window.hotAddressSelectCtrl.value; + this.serverRootDir = address; + this.onInPutUrlOver(); + this._updateShowUseAddrBtn(); + }, + _addLog(str) { + let time = new Date(); + // this.logView = "[" + time.toLocaleString() + "]: " + str + "\n" + this.logView; + this.logView += "[" + time.toLocaleString() + "]: " + str + "\n"; + logListScrollToBottom(); + }, + _getFileIsExist(path) { + try { + fs.accessSync(path, fs.F_OK); + } catch (e) { + return false; + } + return true; + }, + + onCleanAPPCfg() { + CfgUtil.cleanConfig(); + }, + + _saveConfig() { + let data = { + version: this.version, + serverRootDir: this.serverRootDir, + resourceRootDir: this.resourceRootDir, + genManifestDir: CfgUtil.getMainFestDir(), + + localServerPath: this.localServerPath, + hotAddressArray: this.hotAddressArray, + }; + CfgUtil.saveConfig(data); + }, + _initPluginCfg() { + console.log("init cfg"); + // manifest输出目录 + this.genManifestDir = CfgUtil.getMainFestDir(); + if (FileUtil.isFileExit(this.genManifestDir) === false) { + FileUtil.mkDir(this.genManifestDir); + } + + + // 用户自定义配置 + CfgUtil.initCfg(function (data) { + if (data) { + this.version = data.version; + this.serverRootDir = data.serverRootDir; + this.resourceRootDir = data.resourceRootDir; + this.localServerPath = data.localServerPath; + this.hotAddressArray = data.hotAddressArray || []; + this._updateServerVersion(); + this._getRemoteServerVersion(); + } else { + this._saveConfig(); + } + this._initResourceBuild(); + this.initLocalGameVersion(); + }.bind(this)); + + }, + // 导入生成的manifest到游戏项目中 + importManifestToGame() { + let projectFile = path.join(this.genManifestDir, "project.manifest"); + let versionFile = path.join(this.genManifestDir, "version.manifest") + + // let strArr = this.localGameProjectManifestUrl.split("project.manifest"); + // let dir = strArr[0]; + let dir = "db://assets"; + Editor.assetdb.import([projectFile, versionFile], dir, + function (err, results) { + results.forEach(function (result) { + console.log(result.path); + // result.uuid + // result.parentUuid + // result.url + // result.path + // result.type + }); + }.bind(this)); + this.initLocalGameVersion(); + + + // let spawn = require('child_process').spawn; + // let free = spawn('cmd', []); + // // 捕获标准输出并将其打印到控制台 + // free.stdout.on('data', function (data) { + // console.log('standard output:\n' + data); + // }); + // + // // 捕获标准错误输出并将其打印到控制台 + // free.stderr.on('data', function (data) { + // console.log('standard error output:\n' + data); + // }); + // + // // 注册子进程关闭事件 + // free.on('exit', function (code, signal) { + // console.log('child process eixt ,exit:' + code); + // }); + }, + initLocalGameVersion() { + Editor.assetdb.queryAssets('db://assets/**\/*', "raw-asset", function (err, results) { + let versionCfg = ""; + let projectCfg = ""; + results.forEach(function (result) { + if (result.path.indexOf("version.manifest") !== -1) { + versionCfg = result.path; + this.localGameVersionManifestUrl = result.url; + } else if (result.path.indexOf("project.manifest") !== -1) { + projectCfg = result.path; + this.localGameProjectManifestUrl = result.url; + } + }.bind(this)); + console.log("version: " + versionCfg); + console.log("project: " + projectCfg); + + if (versionCfg.length === 0) { + this._addLog("项目中没有配置文件: version.manifest"); + return; + } + if (projectCfg.length === 0) { + this._addLog("项目中没有配置文件: project.manifest"); + return; + } + + this.localGameVersionManifest = versionCfg; + this.localGameProjectManifest = projectCfg; + + let verVersion = ""; + let projVersion = ""; + fs.readFile(versionCfg, 'utf-8', function (err, data) { + if (!err) { + let verData = JSON.parse(data); + verVersion = verData.version; + fs.readFile(projectCfg, 'utf-8', function (err, data) { + if (!err) { + let projectData = JSON.parse(data); + projVersion = projectData.version; + if (projVersion === verVersion) { + this.localGameVersion = projVersion; + this.localGamePackageUrl = projectData.packageUrl; + } else { + this._addLog("游戏中的 project.manifest 和 version.manifest 中的version字段值不一致,请检查配置文件"); + } + } else { + // this.localGameVersion = "没有在项目中发现热更新文件"; + this._addLog("读取项目中的配置文件失败: " + projectCfg); + } + }.bind(this)) + } else { + this._addLog("读取项目中的配置文件失败: " + versionCfg); + } + }.bind(this)) + }.bind(this)); + /* + Editor.assetdb.deepQuery(function (err, results) { + results.forEach(function (result) { + if (result.type !== "folder" && + result.type !== "texture" && + result.type !== "sprite-frame" && + result.type !== "javascript" && + result.type !== "dragonbones-atlas" && + result.type !== "prefab" && + result.type !== "audio-clip" && + result.type !== "animation-clip" && + result.type !== "scene" && + result.type !== "dragonbones" && + result.type !== "particle" && + result.type !== "label-atlas" && + result.type !== "text" && + result.type !== "" && + result.type !== "" + ) { + let fullName = result.name + result.extname; + console.log(result.type + " : " + fullName); + } + }); + }); + */ + }, + // build目录 + _initResourceBuild() { + if (this.resourceRootDir.length === 0) { + // Editor.Profile.load('profile://local/builder.json', (err, profile) => { + // if (!err) { + // console.log(profile); + // } + // }); + // 没有填写resource目录,自动提示 + let projectDir = path.join(Editor.assetdb.library, "../"); + let buildCfg = path.join(projectDir, "local/builder.json"); + if (FileUtil.isFileExit(buildCfg)) { + fs.readFile(buildCfg, 'utf-8', function (err, data) { + if (!err) { + let buildData = JSON.parse(data); + let buildDir = buildData.buildPath; + let buildFullDir = path.join(projectDir, buildDir); + let jsbDir = path.join(buildFullDir, "jsb-default"); + this._checkResourceRootDir(jsbDir); + } + }.bind(this)) + } else { + this._addLog("发现没有构建项目, 使用前请先构建项目!"); + } + } + }, + _checkResourceRootDir(jsbDir) { + if (FileUtil.isFileExit(jsbDir)) { + let srcPath = path.join(jsbDir, "src"); + let resPath = path.join(jsbDir, "remote"); + if (FileUtil.isFileExit(srcPath) === false) { + this._addLog("没有发现 " + srcPath + ", 请先构建项目."); + return false; + } + if (FileUtil.isFileExit(resPath) === false) { + this._addLog("没有发现 " + resPath + ", 请先构建项目."); + return false; + } + this.resourceRootDir = jsbDir; + return true; + } else { + this._addLog("没有发现 " + jsbDir + ", 请先构建项目."); + return false; + } + }, + onClickGenCfg(event) { + // 检查是否需要构建项目 + let times = CfgUtil.getBuildTimeGenTime(); + let genTime = times.genTime; + let buildTime = times.buildTime; + if (genTime === buildTime) {// 构建完版本之后没有生成manifest文件 + CfgUtil.updateGenTime(new Date().getTime(), this.version);// 更新生成时间 + } else { + this._addLog("[生成] 你需要重新构建项目,因为上次构建已经和版本关联:" + CfgUtil.cfgData.genVersion); + return; + } + + + if (!this.version || this.version.length <= 0) { + this._addLog("[生成] 版本号未填写"); + return; + } + if (!this.serverRootDir || this.serverRootDir.length <= 0) { + this._addLog("[生成] 服务器地址未填写"); + return; + } + + // 检查resource目录 + if (this.resourceRootDir.length === 0) { + this._addLog("[生成] 请先指定 "); + return; + } + if (this._checkResourceRootDir(this.resourceRootDir) === false) { + return; + } + + if (!this.genManifestDir || this.genManifestDir.length <= 0) { + this._addLog("[生成] manifest文件生成地址未填写"); + return; + } + + if (!fs.existsSync(this.genManifestDir)) { + this._addLog("[生成] manifest存储目录不存在: " + this.genManifestDir); + return; + } + + this._saveConfig(); + this._genVersion(this.version, this.serverRootDir, this.resourceRootDir, this.genManifestDir); + }, + // serverUrl 必须以/结尾 + // genManifestDir 建议在assets目录下 + // buildResourceDir 默认为 build/jsb-default/ + // -v 10.1.1 -u http://192.168.191.1//cocos/remote-assets/ -s build/jsb-default/ -d assets + _genVersion(version, serverUrl, buildResourceDir, genManifestDir) { + this._addLog("[Build] 开始生成manifest配置文件...."); + let projectFile = "project.manifest"; + let versionFile = "version.manifest"; + let manifest = { + version: version, + packageUrl: serverUrl, + remoteManifestUrl: "", + remoteVersionUrl: "", + assets: {}, + searchPaths: [] + }; + + if (serverUrl[serverUrl.length - 1] === "/") { + manifest.remoteManifestUrl = serverUrl + projectFile; + manifest.remoteVersionUrl = serverUrl + versionFile; + } else { + manifest.remoteManifestUrl = serverUrl + "/" + projectFile; + manifest.remoteVersionUrl = serverUrl + "/" + versionFile; + } + let dest = genManifestDir; + let src = buildResourceDir; + + let readDir = function (dir, obj) { + let stat = fs.statSync(dir); + if (!stat.isDirectory()) { + return; + } + let subpaths = fs.readdirSync(dir), subpath, size, md5, compressed, relative; + for (let i = 0; i < subpaths.length; ++i) { + if (subpaths[i][0] === '.') { + continue; + } + subpath = path.join(dir, subpaths[i]); + stat = fs.statSync(subpath); + if (stat.isDirectory()) { + readDir(subpath, obj); + } + else if (stat.isFile()) { + // Size in Bytes + size = stat['size']; + // let crypto = require('crypto'); + md5 = require('crypto').createHash('md5').update(fs.readFileSync(subpath, 'binary')).digest('hex'); + compressed = path.extname(subpath).toLowerCase() === '.zip'; + + relative = path.relative(src, subpath); + relative = relative.replace(/\\/g, '/'); + relative = encodeURI(relative); + obj[relative] = { + 'size': size, + 'md5': md5 + }; + if (compressed) { + obj[relative].compressed = true; + } + } + } + }; + + let mkdirSync = function (path) { + try { + fs.mkdirSync(path); + } catch (e) { + if (e.code !== 'EEXIST') throw e; + } + }; + + // Iterate res and src folder + readDir(path.join(src, 'src'), manifest.assets); + readDir(path.join(src, 'remote'), manifest.assets); + + let destManifest = path.join(dest, 'project.manifest'); + let destVersion = path.join(dest, 'version.manifest'); + + + mkdirSync(dest); + + // 生成project.manifest + fs.writeFileSync(destManifest, JSON.stringify(manifest)); + this._addLog("[Build] 生成 project.manifest成功"); + // 生成version.manifest + delete manifest.assets; + delete manifest.searchPaths; + fs.writeFileSync(destVersion, JSON.stringify(manifest)); + this._addLog("[Build] 生成 version.manifest成功"); + this._packageVersion(); + }, + // 选择物理server路径 + onSelectLocalServerPath(event) { + let res = Editor.Dialog.openFile({ + title: "选择本地测试服务器目录", + defaultPath: Editor.projectInfo.path, + properties: ['openDirectory'], + }); + if (res !== -1) { + this.localServerPath = res[0]; + this._saveConfig(); + this._updateServerVersion(); + } + }, + // 拷贝文件到测试服务器 + onCopyFileToLocalServer() { + // 检查要拷贝的目录情况 + if (!fs.existsSync(this.localServerPath)) { + this._addLog("本地测试服务器目录不存在:" + this.localServerPath); + return; + } + + // 检查资源目录 + let srcPath = path.join(this.resourceRootDir, "src"); + let resPath = path.join(this.resourceRootDir, "remote"); + if (!fs.existsSync(this.resourceRootDir)) { + this._addLog("资源目录不存在: " + this.resourceRootDir + ", 请先构建项目"); + return; + } else { + if (!fs.existsSync(srcPath)) { + this._addLog(this.resourceRootDir + "不存在src目录, 无法拷贝文件"); + return; + } + if (!fs.existsSync(resPath)) { + this._addLog(this.resourceRootDir + "不存在res目录, 无法拷贝文件"); + return; + } + } + + // 检查manifest文件 + let project = path.join(this.genManifestDir, "project.manifest"); + let version = path.join(this.genManifestDir, "version.manifest"); + if (!this.genManifestDir || this.genManifestDir.length <= 0) { + this._addLog("manifest文件生成地址未填写"); + return; + } else { + if (!this._getFileIsExist(project)) { + this._addLog(project + "不存在, 请点击生成配置"); + return; + } + if (!this._getFileIsExist(version)) { + this._addLog(version + "不存在, 请点击生成配置"); + return; + } + } + this._addLog("[部署] 开始拷贝文件到:" + this.localServerPath); + this.curNum = 0; + this.copyProgress = 0; + + //删除老文件 + this._addLog("[部署] 删除目录路径: " + this.localServerPath); + let delNum = this._getFileNum(this.localServerPath); + this._addLog("[部署] 删除文件个数:" + delNum); + this._delDir(this.localServerPath); + + + this.totalNum = this._getTotalCopyFileNum(); + this._addLog("[部署] 复制文件个数:" + this.totalNum); + + this._copySourceDirToDesDir(srcPath, path.join(this.localServerPath, "src")); + this._copySourceDirToDesDir(resPath, path.join(this.localServerPath, "remote")); + this._copyFileToDesDir(project, this.localServerPath); + this._copyFileToDesDir(version, this.localServerPath); + }, + + // 获取要操作的文件总数量 + _getTotalCopyFileNum() { + // let delNum = this._getFileNum(this.localServerPath); + let srcNum = this._getFileNum(path.join(this.resourceRootDir, "src")); + let resNum = this._getFileNum(path.join(this.resourceRootDir, "remote")); + return srcNum + resNum + 2 + 2;// 2个manifest,2个目录(src, res) + }, + + addProgress() { + this.curNum++; + let p = this.curNum / this.totalNum; + p = p ? p : 0; + // console.log("进度: " + p * 100); + this.copyProgress = p * 100; + if (p >= 1) { + this._addLog("[部署] 部署到指定目录成功:" + this.localServerPath); + this._updateServerVersion(); + } + }, + // 刷新服务器版本号 + refreshLocalServerVersion() { + this._updateServerVersion(); + }, + _updateServerVersion() { + if (this.localServerPath.length > 0) { + let path = require("fire-path"); + let fs = require("fire-fs"); + let versionCfg = path.join(this.localServerPath, "version.manifest"); + fs.readFile(versionCfg, 'utf-8', function (err, data) { + if (!err) { + let cfg = JSON.parse(data); + this.serverVersion = cfg.version; + this.serverPackageUrl = cfg.packageUrl; + } else { + let projectCfg = path.join(this.localServerPath, "project.manifest"); + fs.readFile(projectCfg, 'utf-8', function (err, data) { + if (!err) { + let projectCfg = JSON.parse(data); + this.serverVersion = projectCfg.version; + this.serverPackageUrl = projectCfg.packageUrl; + } else { + this._addLog("无法获取到本地测试服务器版本号"); + } + }.bind(this)); + } + }.bind(this)); + } else { + this._addLog("请选择本机server物理路径"); + } + }, + // 获取文件个数 + _getFileNum(url) { + let i = 0; + let lookDir = function (fileUrl) { + let files = fs.readdirSync(fileUrl);//读取该文件夹 + for (let k in files) { + i++; + let filePath = path.join(fileUrl, files[k]); + let stats = fs.statSync(filePath); + if (stats.isDirectory()) { + lookDir(filePath); + } + } + }; + lookDir(url); + return i; + }, + _delDir(rootFile) { + let self = this; + //删除所有的文件(将所有文件夹置空) + let emptyDir = function (fileUrl) { + let files = fs.readdirSync(fileUrl);//读取该文件夹 + for (let k in files) { + let filePath = path.join(fileUrl, files[k]); + let stats = fs.statSync(filePath); + if (stats.isDirectory()) { + emptyDir(filePath); + } else { + fs.unlinkSync(filePath); + // self.addProgress(); + // console.log("删除文件:" + filePath); + } + } + }; + //删除所有的空文件夹 + let rmEmptyDir = function (fileUrl) { + let files = fs.readdirSync(fileUrl); + if (files.length > 0) { + for (let k in files) { + let rmDir = path.join(fileUrl, files[k]); + rmEmptyDir(rmDir); + } + if (fileUrl !== rootFile) {// 不删除根目录 + fs.rmdirSync(fileUrl); + // self.addProgress(); + // console.log('删除空文件夹' + fileUrl); + } + } else { + if (fileUrl !== rootFile) {// 不删除根目录 + fs.rmdirSync(fileUrl); + // self.addProgress(); + // console.log('删除空文件夹' + fileUrl); + } + } + }; + emptyDir(rootFile); + rmEmptyDir(rootFile); + }, + // 拷贝文件到目录 + _copyFileToDesDir(file, desDir) { + if (this._getFileIsExist(file)) { + let readable = fs.createReadStream(file);// 创建读取流 + let copyFileName = path.basename(file); + let fileName = path.join(desDir, copyFileName); + let writable = fs.createWriteStream(fileName);// 创建写入流 + readable.pipe(writable);// 通过管道来传输流 + this.addProgress(); + } + }, + // 拷贝文件夹 + _copySourceDirToDesDir(source, des) { + let self = this; + // 在复制目录前需要判断该目录是否存在,不存在需要先创建目录 + let exists = function (src, dst, callback) { + fs.exists(dst, function (exists) { + // 已存在 + if (exists) { + callback(src, dst); + } + // 不存在 + else { + fs.mkdir(dst, function () { + self.addProgress(); + callback(src, dst); + }); + } + }); + }; + /* + * 复制目录中的所有文件包括子目录 + * @param{ String } 需要复制的目录 + * @param{ String } 复制到指定的目录 + */ + let copy = function (src, dst) { + // 读取目录中的所有文件/目录 + fs.readdir(src, function (err, paths) { + if (err) { + throw err; + } + paths.forEach(function (path) { + let _src = src + '/' + path, + _dst = dst + '/' + path, + readable, writable; + fs.stat(_src, function (err, st) { + if (err) { + throw err; + } + if (st.isFile()) {// 判断是否为文件 + readable = fs.createReadStream(_src);// 创建读取流 + writable = fs.createWriteStream(_dst);// 创建写入流 + readable.pipe(writable);// 通过管道来传输流 + // console.log("拷贝文件:" + _dst); + self.addProgress(); + } else if (st.isDirectory()) {// 如果是目录则递归调用自身 + exists(_src, _dst, copy); + } + }); + }); + }); + }; + // 复制目录 + exists(source, des, copy); + }, + _isVersionPass(newVersion, baseVersion) { + if (newVersion === undefined || newVersion === null || + baseVersion === undefined || baseVersion === null) { + return false; + } + + let arrayA = newVersion.split('.'); + let arrayB = baseVersion.split('.'); + let len = arrayA.length > arrayB.length ? arrayA.length : arrayB.length; + + for (let i = 0; i < len; i++) { + let itemA = arrayA[i]; + let itemB = arrayB[i]; + + // 新版本1.2 老版本 1.2.3 + if (itemA === undefined && itemB !== undefined) { + return false; + } + + // 新版本1.2.1, 老版本1.2 + if (itemA !== undefined && itemB === undefined) { + return true; + } + + if (itemA && itemB && parseInt(itemA) > parseInt(itemB)) { + return true; + } + } + return false; + }, + onInputVersionOver() { + let buildVersion = CfgUtil.cfgData.genVersion; + let buildTime = CfgUtil.cfgData.buildTime; + let genTime = CfgUtil.cfgData.genTime;// 生成manifest时间 + + let remoteVersion = this.remoteServerVersion; + if (remoteVersion !== null && remoteVersion !== undefined) {// 存在远程版本 + if (this._isVersionPass(this.version, remoteVersion)) { + this._addLog("上次构建时版本号: " + buildVersion); + if (this._isVersionPass(this.version, buildVersion)) {// 上次构建版本和远程版本一致 + this._addLog("版本通过验证!"); + } else { + this._addLog("[Warning] 要构建的版本低于上次构建版本: " + this.version + "<=" + buildVersion); + } + } else { + this._addLog("[Warning] version 填写的版本低于远程版本"); + } + + + } else {// 未发现远程版本 + + } + // let nowTime = new Date().getTime(); + // if (nowTime !== buildTime) { + // if (genVersion === this.version) { + // this._addLog("版本一致,请构建项目"); + // } else { + // } + // } + this._saveConfig(); + }, + onInPutUrlOver(event) { + let url = this.serverRootDir; + let index1 = url.indexOf("http://"); + let index2 = url.indexOf("https://"); + if (index1 === -1 && index2 === -1) { + let reg = /^([hH][tT]{2}[pP]:\/\/|[hH][tT]{2}[pP][sS]:\/\/)(([A-Za-z0-9-~]+)\.)+([A-Za-z0-9-~\/])+$/; + if (!reg.test(url)) { + this._addLog(url + " 不是以http://https://开头,或者不是网址, 已经自动修改"); + this.serverRootDir = "http://" + this.serverRootDir; + this._getRemoteServerVersion(); + } + } else { + // 更新服务器版本 + this._getRemoteServerVersion(); + } + this._addHotAddress(this.serverRootDir); + this._updateShowUseAddrBtn(); + this._saveConfig(); + }, + // 获取远程资源服务器的版本号 + _getRemoteServerVersion() { + if (this.serverRootDir.length <= 0) { + console.log("远程资源服务器URL错误: " + this.serverRootDir); + return; + } + // TODO 浏览器缓存会导致版本号获取失败 + this.isShowRemoteServerVersion = false; + this.remoteServerVersion = null; + let versionUrl = this.serverRootDir + "/version.manifest"; + + let xhr = new XMLHttpRequest(); + xhr.onreadystatechange = function () { + if (xhr.readyState === 4 && ((xhr.status >= 200 && xhr.status < 400))) { + let text = xhr.responseText; + // console.log("版本文件内容\n" + versionUrl + "\n" + text); + let json = null; + try { + json = JSON.parse(text); + } catch (e) { + console.log(e); + this._addLog("获取远程版本号失败!"); + return; + } + this.isShowRemoteServerVersion = true; + this.remoteServerVersion = json.version; + } else if (xhr.status === 404) { + // console.log("404"); + } + }.bind(this); + xhr.open('get', versionUrl, true); + xhr.setRequestHeader("If-Modified-Since", "0");// 不缓存 + xhr.send(); + }, + onTestUrl() { + let url = this.serverRootDir; + if (url.length > 0) { + this._isUrlAvilable(url, function (code) { + this._addLog(url + " 响应: " + code); + }.bind(this)); + } else { + this._addLog("请填写 [资源服务器url] "); + } + }, + _isUrlAvilable(url, callback) { + let http = require("http"); + try { + http.get(url, function (res) { + if (callback) { + callback(res.statusCode); + } + //let text; + //res.setEncoding('utf8'); + //res.on('data', function (chunk) { + // text += chunk; + // console.log(text); + //}); + }.bind(this)); + } catch (e) { + callback(-1); + } + }, + // 访问测试网站 + onOpenUrl(event) { + let url = this.serverRootDir; + if (url.length > 0) { + Electron.shell.openExternal(url); + } else { + this._addLog("未填写参数"); + } + }, + userLocalIP() { + let ip = ""; + let os = require('os'); + let network = os.networkInterfaces(); + for (let i = 0; i < network.WLAN.length; i++) { + let json = network.WLAN[i]; + if (json.family === 'IPv4') { + ip = json.address; + } + } + console.log(ip); + if (ip.length > 0) { + this.serverRootDir = "http://" + ip; + this.onInPutUrlOver(null); + } + }, + // 选择资源文件目录 + onSelectSrcDir(event) { + let res = Editor.Dialog.openFile({ + title: "选择Src目录", + defaultPath: Editor.projectInfo.path, + properties: ['openDirectory'], + callback: function (fileNames) { + + }, + }); + if (res !== -1) { + this.srcDirPath = res[0]; + this._saveConfig(); + } + }, + onSelectResDir() { + let res = Editor.Dialog.openFile({ + title: "选择Res目录", + defaultPath: Editor.projectInfo.path, + properties: ['openDirectory'], + }); + if (res !== -1) { + this.resDirPath = res[0]; + this._saveConfig(); + } + }, + // 选择projManifest文件 + onOpenResourceDir() { + if (!fs.existsSync(this.resourceRootDir)) { + this._addLog("目录不存在:" + this.resourceRootDir); + return; + } + Electron.shell.showItemInFolder(this.resourceRootDir); + Electron.shell.beep(); + }, + onOpenManifestDir() { + if (!fs.existsSync(this.genManifestDir)) { + this._addLog("目录不存在:" + this.genManifestDir); + return; + } + Electron.shell.showItemInFolder(this.genManifestDir); + Electron.shell.beep(); + }, + onOpenLocalServer() { + if (!fs.existsSync(this.genManifestDir)) { + this._addLog("目录不存在:" + this.localServerPath); + return; + } + Electron.shell.showItemInFolder(this.localServerPath); + Electron.shell.beep(); + }, + // 选择生成Manifest的目录 + onSelectGenManifestDir() { + let res = Editor.Dialog.openFile({ + title: "选择生成Manifest目录", + defaultPath: Editor.projectInfo.path, + properties: ['openDirectory'], + }); + if (res !== -1) { + this.genManifestDir = res[0]; + this._saveConfig(); + } + }, + onSelectGenServerRootDir() { + let res = Editor.Dialog.openFile({ + title: "选择部署的服务器根目录", + defaultPath: Editor.projectInfo.path, + properties: ['openDirectory'], + }); + if (res !== -1) { + this.serverRootDir = res[0]; + this._saveConfig(); + } + }, + onSelectResourceRootDir() { + let res = Editor.Dialog.openFile({ + title: "选择构建后的根目录", + defaultPath: Editor.projectInfo.path, + properties: ['openDirectory'], + }); + if (res !== -1) { + let dir = res[0]; + if (this._checkResourceRootDir(dir)) { + this.resourceRootDir = dir; + this._saveConfig(); + } + } + }, + onCleanSimRemoteRes() { + let path = require("fire-path"); + let simPath = path.join(__dirname, "../cocos2d-x/simulator/win32"); + let remoteAsset = path.join(simPath, "remote-asset"); + if (!fs.existsSync(remoteAsset)) { + console.log(remoteAsset); + this._addLog("[清理热更缓存] 目录不存在: " + remoteAsset); + } else { + FileUtil.emptyDir(remoteAsset); + this._addLog("[清理热更缓存] 清空目录 " + remoteAsset + " 成功."); + } + }, + onOpenLocalGameManifestDir() { + let strArr = this.localGameProjectManifest.split("project.manifest"); + let dir = strArr[0]; + + if (!fs.existsSync(dir)) { + this._addLog("目录不存在:" + dir); + return; + } + Electron.shell.showItemInFolder(dir); + Electron.shell.beep(); + }, + onTestZip() { + let zip = require("node-native-zip"); + }, + // + onTestSelect() { + let ip = Math.random() * 100; + this.hotAddressArray.push(ip.toFixed(2)); + selectionLast(this.hotAddressArray.length - 1); + }, + onIpSelectChange(event) { + console.log("index:%d, text:%s, value:%s ", event.detail.index, event.detail.text, event.detail.value); + }, + onLogIp() { + // getSelectIp(); + Editor.Ipc.sendToMain('hot-update-tools:test', 'Hello, this is simple panel'); + // let relativePath = path.relative(__dirname, path.join(Editor.projectInfo.path, 'assets')); + // console.log(relativePath); + }, + onTestEnvChange(event) { + // let children = event.target.$select.children; + // for (let i = 0; i < children.length; i++) { + // let item = children[i]; + // if (item.value === "0") { + // item.selected = true; + // } else { + // item.selected = false; + // } + // } + let selectValue = event.target.value; + this.testEnvALi = false; + this.testEnvLocal = false; + this.testEnvEmail = false; + if (selectValue === "0") {// 本地测试环境 + this.testEnvLocal = true; + } else if (selectValue === "1") {//阿里云测试环境 + this.testEnvALi = true; + } else if (selectValue === "2") { + this.testEnvEmail = true; + } + }, + } + }); + }, + + + messages: { + 'hot-update-tools:onBuildFinished'(event, time) { + window.plugin.onBuildFinished(time); + }, + + } + +}); \ No newline at end of file diff --git a/packages/hot-update-tools/panel/test.js b/packages/hot-update-tools/panel/test.js new file mode 100644 index 0000000..e69de29 diff --git a/packages/hot-update-tools/test/TestEnvAli.html b/packages/hot-update-tools/test/TestEnvAli.html new file mode 100644 index 0000000..e69de29 diff --git a/packages/hot-update-tools/test/TestEnvAli.js b/packages/hot-update-tools/test/TestEnvAli.js new file mode 100644 index 0000000..137a435 --- /dev/null +++ b/packages/hot-update-tools/test/TestEnvAli.js @@ -0,0 +1,14 @@ +'use strict'; +var Fs = require('fire-fs'); +var Path = require('fire-path'); +let url = Editor.url(window.packageRoot + "panel/TestEnvAli.html", 'utf8'); + + +module.exports = { + init() { + Vue.component('TestEnvAli', { + props: ['data'], + template: Fs.readFileSync(url), + }); + }, +}; diff --git a/packages/hot-update/main.js b/packages/hot-update/main.js new file mode 100644 index 0000000..3224a9a --- /dev/null +++ b/packages/hot-update/main.js @@ -0,0 +1,44 @@ +'use strict'; + +var Fs = require("fire-fs"); +var Path = require("fire-path"); + +module.exports = { + load: function () { + // 当 package 被正确加载的时候执行 + }, + + unload: function () { + // 当 package 被正确卸载的时候执行 + }, + + messages: { + 'editor:build-finished': function (event, target) { + var root = Path.normalize(target.dest); + var url = Path.join(root, "main.js"); + Fs.readFile(url, "utf8", function (err, data) { + if (err) { + throw err; + } + + var newStr = + "(function () { \n"+ + "\n"+ + " if (cc.sys.isNative) { \n" + + " var hotUpdateSearchPaths = cc.sys.localStorage.getItem('HotUpdateSearchPaths'); \n" + + " if (hotUpdateSearchPaths) { \n" + + " jsb.fileUtils.setSearchPaths(JSON.parse(hotUpdateSearchPaths)); \n" + + " }\n" + + " }"; + + var newData = data.replace("(function () {", newStr); + Fs.writeFile(url, newData, function (error) { + if (err) { + throw err; + } + Editor.log("SearchPath updated in built main.js for hot update"); + }); + }); + } + } +}; \ No newline at end of file diff --git a/packages/hot-update/package.json b/packages/hot-update/package.json new file mode 100644 index 0000000..b6a0286 --- /dev/null +++ b/packages/hot-update/package.json @@ -0,0 +1,7 @@ +{ + "name": "hot-update", + "version": "0.0.1", + "description": "用于热更新插件", + "author": "Cocos Creator", + "main": "main.js" +} \ No newline at end of file diff --git a/remote-assets/project.manifest b/remote-assets/project.manifest new file mode 100644 index 0000000..13fa209 --- /dev/null +++ b/remote-assets/project.manifest @@ -0,0 +1 @@ +{"packageUrl":"https://jianmiau.tk/Resources/App/JMKA/update/remote-assets/","remoteManifestUrl":"https://jianmiau.tk/Resources/App/JMKA/update/remote-assets/project.manifest","remoteVersionUrl":"https://jianmiau.tk/Resources/App/JMKA/update/remote-assets/version.manifest","version":"1.0.2","assets":{"src/cocos2d-jsb.js":{"size":2994873,"md5":"54eb9e8c7718557d8e6aa101ad137d37"},"src/settings.js":{"size":500,"md5":"d989547c4773fe77c3dac0293e87e174"},"assets/main/index.js":{"size":435919,"md5":"ae48365ba7b69d9e57fccd8308cb262d"}},"searchPaths":[]} \ No newline at end of file diff --git a/remote-assets/version.manifest b/remote-assets/version.manifest new file mode 100644 index 0000000..5deb797 --- /dev/null +++ b/remote-assets/version.manifest @@ -0,0 +1 @@ +{"packageUrl":"https://jianmiau.tk/Resources/App/JMKA/update/remote-assets/","remoteManifestUrl":"https://jianmiau.tk/Resources/App/JMKA/update/remote-assets/project.manifest","remoteVersionUrl":"https://jianmiau.tk/Resources/App/JMKA/update/remote-assets/version.manifest","version":"1.0.2"} \ No newline at end of file diff --git a/tsconfig.json b/tsconfig.json index 93c0b22..dd2485b 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,19 +1,31 @@ { - "compilerOptions": { - "module": "commonjs", - "lib": [ "es2015", "es2017", "dom" ], - "target": "es5", - "experimentalDecorators": true, - "skipLibCheck": true, - "outDir": "temp/vscode-dist", - "forceConsistentCasingInFileNames": true - }, - "exclude": [ - "node_modules", - "library", - "local", - "temp", - "build", - "settings" - ] + "compilerOptions": { + "module": "commonjs", + "lib": [ + "es2015", + "es2017", + "dom" + ], + "target": "es5", + "allowJs": true, + "experimentalDecorators": true, + "skipLibCheck": true, + "outDir": "temp/vscode-dist", + "forceConsistentCasingInFileNames": true, + "downlevelIteration": true, + "sourceMap": true + }, + "exclude": [ + "node_modules", + "library", + "local", + "temp", + "build", + "settings", + ".git", + ".vscode", + "build-templates", + "preview-templates", + "packages" + ] } \ No newline at end of file diff --git a/version_generator.js b/version_generator.js new file mode 100644 index 0000000..342862e --- /dev/null +++ b/version_generator.js @@ -0,0 +1,115 @@ +var fs = require('fs'); +var path = require('path'); +var crypto = require('crypto'); + +var manifest = { + packageUrl: 'http://localhost/tutorial-hot-update/remote-assets/', + remoteManifestUrl: 'http://localhost/tutorial-hot-update/remote-assets/project.manifest', + remoteVersionUrl: 'http://localhost/tutorial-hot-update/remote-assets/version.manifest', + version: '1.0.0', + assets: {}, + searchPaths: [] +}; + +var dest = './remote-assets/'; +var src = './jsb/'; + +// Parse arguments +var i = 2; +while (i < process.argv.length) { + var arg = process.argv[i]; + + switch (arg) { + case '--url': + case '-u': + var url = process.argv[i + 1]; + manifest.packageUrl = url; + manifest.remoteManifestUrl = url + 'project.manifest'; + manifest.remoteVersionUrl = url + 'version.manifest'; + i += 2; + break; + case '--version': + case '-v': + manifest.version = process.argv[i + 1]; + i += 2; + break; + case '--src': + case '-s': + src = process.argv[i + 1]; + i += 2; + break; + case '--dest': + case '-d': + dest = process.argv[i + 1]; + i += 2; + break; + default: + i++; + break; + } +} + + +function readDir(dir, obj) { + var stat = fs.statSync(dir); + if (!stat.isDirectory()) { + return; + } + var subpaths = fs.readdirSync(dir), subpath, size, md5, compressed, relative; + for (var i = 0; i < subpaths.length; ++i) { + if (subpaths[i][0] === '.') { + continue; + } + subpath = path.join(dir, subpaths[i]); + stat = fs.statSync(subpath); + if (stat.isDirectory()) { + readDir(subpath, obj); + } + else if (stat.isFile()) { + // Size in Bytes + size = stat['size']; + md5 = crypto.createHash('md5').update(fs.readFileSync(subpath, 'binary')).digest('hex'); + compressed = path.extname(subpath).toLowerCase() === '.zip'; + + relative = path.relative(src, subpath); + relative = relative.replace(/\\/g, '/'); + relative = encodeURI(relative); + obj[relative] = { + 'size': size, + 'md5': md5 + }; + if (compressed) { + obj[relative].compressed = true; + } + } + } +} + +var mkdirSync = function (path) { + try { + fs.mkdirSync(path); + } catch (e) { + if (e.code != 'EEXIST') throw e; + } +} + +// Iterate res and src folder +readDir(path.join(src, 'src'), manifest.assets); +readDir(path.join(src, 'assets'), manifest.assets); + +var destManifest = path.join(dest, 'project.manifest'); +var destVersion = path.join(dest, 'version.manifest'); + +mkdirSync(dest); + +fs.writeFile(destManifest, JSON.stringify(manifest), (err) => { + if (err) throw err; + console.log('Manifest successfully generated'); +}); + +delete manifest.assets; +delete manifest.searchPaths; +fs.writeFile(destVersion, JSON.stringify(manifest), (err) => { + if (err) throw err; + console.log('Version successfully generated'); +});