├── .gitignore ├── LICENSE.md ├── README.md ├── assets ├── hotupdate.meta ├── hotupdate │ ├── HotUpdate.ts │ ├── HotUpdate.ts.meta │ ├── UpdatePanel.ts │ └── UpdatePanel.ts.meta ├── project.manifest ├── project.manifest.meta ├── scenes.meta ├── scenes │ ├── menu.scene │ └── menu.scene.meta ├── textures.meta ├── textures │ ├── UI.meta │ └── UI │ │ ├── bg_changjing.png │ │ ├── bg_changjing.png.meta │ │ ├── bg_jinbishu.png │ │ ├── bg_jinbishu.png.meta │ │ ├── bg_rankinglist.png │ │ ├── bg_rankinglist.png.meta │ │ ├── button_orange.png │ │ ├── button_orange.png.meta │ │ ├── gb_inputbox.png │ │ ├── gb_inputbox.png.meta │ │ ├── singleColor.png │ │ └── singleColor.png.meta ├── version.manifest └── version.manifest.meta ├── extensions ├── hot-update-local-ip │ ├── builder │ │ ├── hook.js │ │ └── index.js │ └── package.json └── hot-update │ ├── builder │ ├── hook.js │ └── index.js │ └── package.json ├── package.json ├── settings └── v2 │ └── packages │ ├── builder.json │ ├── cocos-service.json │ ├── device.json │ ├── engine.json │ ├── program.json │ └── project.json ├── tsconfig.json └── version_generator.js /.gitignore: -------------------------------------------------------------------------------- 1 | #///////////////////////////////////////////////////////////////////////////// 2 | # Fireball Projects 3 | #///////////////////////////////////////////////////////////////////////////// 4 | 5 | library/ 6 | temp/ 7 | local/ 8 | build/ 9 | native/ 10 | 11 | #///////////////////////////////////////////////////////////////////////////// 12 | # Logs and databases 13 | #///////////////////////////////////////////////////////////////////////////// 14 | 15 | *.log 16 | *.sql 17 | *.sqlite 18 | 19 | #///////////////////////////////////////////////////////////////////////////// 20 | # files for debugger 21 | #///////////////////////////////////////////////////////////////////////////// 22 | 23 | *.sln 24 | *.csproj 25 | *.pidb 26 | *.unityproj 27 | *.suo 28 | 29 | #///////////////////////////////////////////////////////////////////////////// 30 | # OS generated files 31 | #///////////////////////////////////////////////////////////////////////////// 32 | 33 | .DS_Store 34 | ehthumbs.db 35 | Thumbs.db 36 | 37 | #///////////////////////////////////////////////////////////////////////////// 38 | # exvim files 39 | #///////////////////////////////////////////////////////////////////////////// 40 | 41 | *UnityVS.meta 42 | *.err 43 | *.err.meta 44 | *.exvim 45 | *.exvim.meta 46 | *.vimentry 47 | *.vimentry.meta 48 | *.vimproject 49 | *.vimproject.meta 50 | .vimfiles.*/ 51 | .exvim.*/ 52 | quick_gen_project_*_autogen.bat 53 | quick_gen_project_*_autogen.bat.meta 54 | quick_gen_project_*_autogen.sh 55 | quick_gen_project_*_autogen.sh.meta 56 | .exvim.app 57 | 58 | #///////////////////////////////////////////////////////////////////////////// 59 | # webstorm files 60 | #///////////////////////////////////////////////////////////////////////////// 61 | 62 | .idea/ 63 | 64 | # JSB publish files 65 | 66 | jsb/ 67 | profiles 68 | -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | # 资源授权声明 2 | 3 | 「21点游戏」项目是由腾讯游戏和触控科技合作开发的,用于展示 Cocos Creator 快速开发游戏界面和玩法能力的教学项目。本项目中所有美术资源(包括但不限于 png, jpg 格式的图片文件)的版权归腾讯游戏所有,在未经授权的情况下: 4 | 5 | - 不可在任何情况下用于公开发布的可获取商业利益的游戏或演示。 6 | - 对本项目中的美术资源进行修改、加工、混合后的图像不可用于再次分发。 7 | - 在非可获得商业利益的游戏或演示中使用这些资源,需要在软件公开的部分保留本授权声明文本。 8 | 9 | 除了个人学习研究目的,本授权声明不保证你能获得任何使用本项目资源的授权。如果有任何疑问请咨询触控科技相关部门:contactus@chukong-inc.com -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # 资源热更新教程 2 | 3 | ## 前言 4 | 5 | **本篇文档基于 Cocos Creator v3.0.0 完成** 6 | 7 | 之所以这篇文档的标题为教程,是因为目前 Cocos Creator 资源热更新的工作流还没有彻底集成到编辑器中,不过引擎本身对于热更新的支持是完备的,所以借助一些外围脚本和一些额外的工作就可以达成。 8 | 9 | 本篇文档的范例工程可以从 [Github 仓库](https://github.com/cocos-creator/tutorial-hot-update)获取。 10 | 11 | ## 使用场景和设计思路 12 | 13 | 资源热更新的使用场景相信游戏开发者都非常熟悉,对于已发布的游戏,在游戏内通过从服务器动态下载新的游戏内容,来时刻保持玩家对游戏的新鲜感,是保持一款游戏长盛不衰非常重要的手段。当然热更新还有一些其他的用途,不过在此不再深入讨论,我们下面将主要讨论 Cocos Creator 对热更新支持的原理和手段。 14 | 15 | Cocos Creator 中的热更新主要源于 Cocos 引擎中的 AssetsManager 模块对热更新的支持。它有个非常重要的特点: 16 | 17 | **服务端和本地均保存完整版本的游戏资源**,热更新过程中通过比较服务端和本地版本的差异来决定更新哪些内容。这样即可天然支持跨版本更新,比如本地版本为 A,远程版本是 C,则直接更新 A 和 C 之间的差异,并不需要生成 A 到 B 和 B 到 C 的更新包,依次更新。所以,在这种设计思路下,新版本的文件以离散的方式保存在服务端,更新时以文件为单位下载。 18 | 19 | 除此之外,由于 WEB 版本可以通过服务器直接进行版本更新,所以资源热更新只适用于原生发布版本。AssetsManager 类也只在 jsb 命名空间下,在使用的时候需要注意判断运行环境。 20 | 21 | ## Manifest 文件 22 | 23 | 对于不同版本的文件级差异,AssetsManager 中使用 Manifest 文件来进行版本比对。本地和远端的 Manifest 文件分别标示了本地和远端的当前版本包含的文件列表和文件版本,这样就可以通过比对每个文件的版本来确定需要更新的文件列表。 24 | 25 | Manifest 文件中包含以下几个重要信息: 26 | 27 | 1. 远程资源包的根路径 28 | 2. 远程 Manifest 文件地址 29 | 3. 远程 Version 文件地址(非必需) 30 | 4. 主版本号 31 | 5. 文件列表:以文件路径来索引,包含文件版本信息,一般推荐用文件的 md5 校验码来作为版本号 32 | 6. 搜索路径列表 33 | 34 | 其中 Version 文件内容是 Manifest 文件内容的一部分,不包含文件列表。由于 Manifest 文件可能比较大,每次检查更新的时候都完整下载的话可能影响体验,所以开发者可以额外提供一个非常小的 Version 文件。AssetsManager 会首先检查 Version 文件提供的主版本号来判断是否需要继续下载 Manifest 文件并更新。 35 | 36 | ## 在 Cocos Creator 项目中支持热更新 37 | 38 | 在这篇教程中,将提出一种针对 Cocos Creator 项目可行的热更新方案,不过我们将在 Cocos2d-x 的未来版本中开放 Downloader 的 JavaScript 接口,届时用户可以自由开发自己的热更新方案。对于 Cocos Creator 来说,所有 JS 脚本将会打包到 src 目录中,其他 Assets 资源将会被导出到 assets 目录。 39 | 40 | 基于这样的项目结构,本篇教程中的热更新思路很简单: 41 | 42 | 1. 基于原生打包目录中的 assets 和 src 目录生成本地 Manifest 文件。 43 | 2. 创建一个热更新组件来负责热更新逻辑。 44 | 3. 游戏发布后,若需要更新版本,则生成一套远程版本资源,包含 assets 目录、src 目录和 Manifest 文件,将远程版本部署到服务端。 45 | 4. 当热更新组件检测到服务端 Manifest 版本不一致时,就会开始热更新 46 | 47 | ### 使用 Version Generator 来生成 Manifest 文件 48 | 49 | 在范例工程中,我们提供了一个 [version_generator.js 文件](https://github.com/cocos-creator/tutorial-hot-update/blob/master/version_generator.js),这是一个用于生成 Manfiest 文件的 NodeJS 脚本。使用方式如下: 50 | 51 | ``` 52 | > node version_generator.js -v 1.0.0 -u http://your-server-address/tutorial-hot-update/remote-assets/ -s native/package/ -d assets/ 53 | ``` 54 | 55 | 下面是参数说明: 56 | 57 | - `-v` 指定 Manifest 文件的主版本号。 58 | - `-u` 指定服务器远程包的地址,这个地址需要和最初发布版本中 Manifest 文件的远程包地址一致,否则无法检测到更新。 59 | - `-s` 本地原生打包版本的目录相对路径。 60 | - `-d` 保存 Manifest 文件的地址。 61 | 62 | ### 热更新组件 63 | 64 | 在范例工程中,热更新组件的实现位于 [`assets/hotupdate/HotUpdate.js`](https://github.com/cocos-creator/tutorial-hot-update/blob/master/assets/hotupdate/HotUpdate.js) 中,开发者可以参考这种实现,也可以自由得按自己的需求修改。 65 | 66 | 除此之外,范例工程中还搭配了一个 `Canvas/update` 节点用于提示更新和显示更新进度供参考。 67 | 68 | ### 部署远程服务器 69 | 70 | 为了让游戏可以检测到远程版本,可以在本机上模拟一个远程服务器,搭建服务器的方案多种多样(比如 Python [SimpleHTTPServer](https://docs.python.org/2/library/simplehttpserver.html)),这里不做讨论,开发者可以使用自己习惯的方式。搭建成功后,访问远程包和 Manifest 文件的地址与范例工程中不同,所以需要修改以下几个地方来让游戏可以成功找到远程包: 71 | 72 | 1. `assets/project.manifest`:游戏的本地 Manifest 文件中的 `packageUrl`、`remoteManifestUrl` 和 `remoteVersionUrl` 73 | 2. `remote-assets/project.manifest`:远程包的 Manifest 文件中的 `packageUrl`、`remoteManifestUrl` 和 `remoteVersionUrl` 74 | 3. `remote-assets/version.manifest`:远程包的 Version 文件中的 `packageUrl`、`remoteManifestUrl` 和 `remoteVersionUrl` 75 | 76 | ### 打包原生版本 77 | 78 | 下载完成范例工程后,可以用 Cocos Creator 直接打开这个工程。打开`构建发布`面板,构建原生版本,建议使用 Windows / Mac 来测试。 79 | **注意**: 80 | - 构建时请不要勾选 MD5 Cache,否则会导致热更新无效。 81 | - 并且应该确保在工程目录的 packages 文件夹里导入 hot-update 编辑器插件(范例工程里已经导入了该插件) 82 | 83 | 该编辑器插件会在每次构建结束后,自动给 `main.js` 附加上搜索路径设置的逻辑和更新中断修复代码: 84 | 85 | ``` 86 | // 在 main.js 的开头添加如下代码 87 | (function () { 88 | if (typeof window.jsb === 'object') { 89 | var hotUpdateSearchPaths = localStorage.getItem('HotUpdateSearchPaths'); 90 | if (hotUpdateSearchPaths) { 91 | var paths = JSON.parse(hotUpdateSearchPaths); 92 | jsb.fileUtils.setSearchPaths(paths); 93 | 94 | var fileList = []; 95 | var storagePath = paths[0] || ''; 96 | var tempPath = storagePath + '_temp/'; 97 | var baseOffset = tempPath.length; 98 | 99 | if (jsb.fileUtils.isDirectoryExist(tempPath) && !jsb.fileUtils.isFileExist(tempPath + 'project.manifest.temp')) { 100 | jsb.fileUtils.listFilesRecursively(tempPath, fileList); 101 | fileList.forEach(srcPath => { 102 | var relativePath = srcPath.substr(baseOffset); 103 | var dstPath = storagePath + relativePath; 104 | 105 | if (srcPath[srcPath.length] == '/') { 106 | jsb.fileUtils.createDirectory(dstPath) 107 | } 108 | else { 109 | if (jsb.fileUtils.isFileExist(dstPath)) { 110 | jsb.fileUtils.removeFile(dstPath) 111 | } 112 | jsb.fileUtils.renameFile(srcPath, dstPath); 113 | } 114 | }) 115 | jsb.fileUtils.removeDirectory(tempPath); 116 | } 117 | } 118 | } 119 | })(); 120 | ``` 121 | 122 | 这一步是必须要做的原因是,热更新的本质是用远程下载的文件取代原始游戏包中的文件。Cocos2d-x 的搜索路径恰好满足这个需求,它可以用来指定远程包的下载地址作为默认的搜索路径,这样游戏运行过程中就会使用下载好的远程版本。另外,这里搜索路径是在上一次更新的过程中使用 `localStorage`(它符合 WEB 标准的 [Local Storage API](https://developer.mozilla.org/en/docs/Web/API/Window/localStorage))固化保存在用户机器上,`HotUpdateSearchPaths` 这个键值是在 `HotUpdate.js` 中指定的,保存和读取过程使用的名字必须匹配。 123 | 124 | 此外,打开工程过程中如果遇到这个警告可以忽略:`loader for [.manifest] not exists!`。 125 | 126 | ### 运行范例工程 127 | 128 | 如果一切正常,此时运行原生版本的范例工程,就会发现检测到新版本,提示更新,更新之后会自动重启游戏,此时可进入 table 场景。 129 | 130 | ## 结语 131 | 132 | 以上介绍的是目前一种可能的热更新方案,Cocos Creator 在未来版本中提供更成熟的热更新方案,直接集成到编辑器中。当然,也会提供底层 Downloader API 来允许用户自由实现自己的热更新方案,并通过插件机制在编辑器中搭建完整可视化的工作流。这篇教程和范例工程提供给大家参考,并不是官方方案,也鼓励开发者针对自己的工作流进行定制。如果有问题和交流也欢迎反馈到[论坛](https://forum.cocos.com/c/Creator)中。 133 | 134 | ## 参考 135 | 136 | [资源管理器 Assets Manager 文档](https://docs.cocos.com/creator/manual/zh/advanced-topics/assets-manager.html) 137 | -------------------------------------------------------------------------------- /assets/hotupdate.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.1.0", 3 | "importer": "directory", 4 | "imported": true, 5 | "uuid": "e85ccabe-9e68-497c-bc65-3e980d3560a2", 6 | "files": [], 7 | "subMetas": {}, 8 | "userData": { 9 | "compressionType": {}, 10 | "isRemoteBundle": {} 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /assets/hotupdate/HotUpdate.ts: -------------------------------------------------------------------------------- 1 | import { UpdatePanel } from './UpdatePanel'; 2 | 3 | const jsb = (window).jsb; 4 | 5 | // Custom manifest removed the following assets: 6 | // 1. res/raw-assets/2a/2a40e5e7-4c4a-4350-9e5d-76757755cdd2.png 7 | // 2. res/raw-assets/2d/2d86a854-63c4-4b90-8b88-a4328b8526c2.png 8 | // So when custom manifest used, you should be able to find them in downloaded remote assets 9 | var customManifestStr = JSON.stringify({ 10 | "packageUrl": "http://192.168.55.13:5502/remote-assets/", 11 | "remoteManifestUrl": "http://192.168.55.13:5502/remote-assets/project.manifest", 12 | "remoteVersionUrl": "http://192.168.55.13:5502/remote-assets/version.manifest", 13 | "version": "1.0.0", 14 | "assets": { 15 | "src/application.js": { 16 | "size": 5514, 17 | "md5": "d09753aaed7c55c4566cecf766cbc5c3" 18 | }, 19 | "src/cocos-js/ammo-instantiated-45eaa448.js": { 20 | "size": 2318381, 21 | "md5": "081a863c98742000893bca3bb87c1775" 22 | }, 23 | "src/cocos-js/cc.js": { 24 | "size": 1774495, 25 | "md5": "c4ba032d442580df30778c0369917917" 26 | }, 27 | "src/cocos-js/wait-for-ammo-instantiation.js": { 28 | "size": 625, 29 | "md5": "c9c1bf74589762eca08ae868d216f243" 30 | }, 31 | "src/import-map.json": { 32 | "size": 111, 33 | "md5": "498f3926fc713deab3e0ac6fcbb3d549" 34 | }, 35 | "src/settings.json": { 36 | "size": 31619, 37 | "md5": "f54273c3c1c29dc9040f129ee11db461" 38 | }, 39 | "src/system.bundle.js": { 40 | "size": 6275, 41 | "md5": "3f3f2b5f3725599ff2c8b9801195ee37" 42 | }, 43 | "assets/main/config.json": { 44 | "size": 918, 45 | "md5": "757c93f3908a069aaaa062541715edcf" 46 | }, 47 | "assets/main/import/08/0897a7610.json": { 48 | "size": 248, 49 | "md5": "12b2792f517c08d878378119a80a09cc" 50 | }, 51 | "assets/main/import/0f/0f4f09600.json": { 52 | "size": 8090, 53 | "md5": "755c01fe8bae77adb19e3b21f11e95d7" 54 | }, 55 | "assets/main/import/70/700faa17-11a6-46cd-aeb5-d6900bc264f8.json": { 56 | "size": 69, 57 | "md5": "1f9cadcf049e884e057ca8cf797d73a1" 58 | }, 59 | "assets/main/import/9e/9e71ecbc-8d63-45dd-b0e3-26cefa3d07b1.json": { 60 | "size": 69, 61 | "md5": "1f9cadcf049e884e057ca8cf797d73a1" 62 | }, 63 | "assets/main/import/ae/ae4e2188-2b7b-42a9-85e1-8fb987600b04.json": { 64 | "size": 69, 65 | "md5": "1f9cadcf049e884e057ca8cf797d73a1" 66 | }, 67 | "assets/main/import/c1/c1e757ac-f5bb-46ed-b86a-fdabff7aeb55.json": { 68 | "size": 69, 69 | "md5": "1f9cadcf049e884e057ca8cf797d73a1" 70 | }, 71 | "assets/main/import/ed/edd97988-52a3-4312-8671-90a51bb563ae.json": { 72 | "size": 69, 73 | "md5": "1f9cadcf049e884e057ca8cf797d73a1" 74 | }, 75 | "assets/main/import/fd/fd8ec536-a354-4a17-9c74-4f3883c378c8.json": { 76 | "size": 480, 77 | "md5": "731f44a39ce9377ee6de8ba34edaf039" 78 | }, 79 | "assets/main/index.js": { 80 | "size": 12682, 81 | "md5": "e2fd04611b129a14138444b6207c1ab7" 82 | }, 83 | "assets/main/native/70/700faa17-11a6-46cd-aeb5-d6900bc264f8.png": { 84 | "size": 3765, 85 | "md5": "878e89a0a3e02b13beee9f3274f2ca39" 86 | }, 87 | "assets/main/native/80/800f94fd-7424-4202-9629-d3ca77f3b72d.manifest": { 88 | "size": 2808, 89 | "md5": "507a24062f30709e41e0891ae6a53c7f" 90 | }, 91 | "assets/main/native/9e/9e71ecbc-8d63-45dd-b0e3-26cefa3d07b1.png": { 92 | "size": 2548, 93 | "md5": "ae7a04af25e238a5478170759b55a7ba" 94 | }, 95 | "assets/main/native/ae/ae4e2188-2b7b-42a9-85e1-8fb987600b04.png": { 96 | "size": 634171, 97 | "md5": "07b03f7145b75579708ae05ea2a2c029" 98 | }, 99 | "assets/main/native/c1/c1e757ac-f5bb-46ed-b86a-fdabff7aeb55.png": { 100 | "size": 18969, 101 | "md5": "8eaaf03d4497b39525214bf039a11a7d" 102 | }, 103 | "assets/main/native/ed/edd97988-52a3-4312-8671-90a51bb563ae.png": { 104 | "size": 1829, 105 | "md5": "94d761c4626df88053787f17fa09914d" 106 | }, 107 | "jsb-adapter/jsb-builtin.js": { 108 | "size": 170485, 109 | "md5": "f7f79bebbd40822e195af8f099332b0e" 110 | }, 111 | "jsb-adapter/jsb-engine.js": { 112 | "size": 140954, 113 | "md5": "2846deccc21c73b49e8bae51e3d5387a" 114 | } 115 | }, 116 | "searchPaths": [] 117 | }); 118 | 119 | import { _decorator, Component, Node, Label, ProgressBar, Asset, game, sys } from 'cc'; 120 | const { ccclass, property } = _decorator; 121 | 122 | @ccclass('HotUpdate') 123 | export class HotUpdate extends Component { 124 | 125 | @property(UpdatePanel) 126 | panel: UpdatePanel = null!; 127 | 128 | @property(Asset) 129 | manifestUrl: Asset = null!; 130 | 131 | @property(Node) 132 | updateUI: Node = null!; 133 | 134 | private _updating = false; 135 | private _canRetry = false; 136 | private _storagePath = ''; 137 | private _am: jsb.AssetsManager = null!; 138 | private _checkListener = null; 139 | private _updateListener = null; 140 | private _failCount = 0; 141 | private versionCompareHandle: (versionA: string, versionB: string) => number = null!; 142 | 143 | checkCb(event: any) { 144 | console.log('Code: ' + event.getEventCode()); 145 | switch (event.getEventCode()) { 146 | case jsb.EventAssetsManager.ERROR_NO_LOCAL_MANIFEST: 147 | this.panel.info.string = "No local manifest file found, hot update skipped."; 148 | break; 149 | case jsb.EventAssetsManager.ERROR_DOWNLOAD_MANIFEST: 150 | case jsb.EventAssetsManager.ERROR_PARSE_MANIFEST: 151 | this.panel.info.string = "Fail to download manifest file, hot update skipped."; 152 | break; 153 | case jsb.EventAssetsManager.ALREADY_UP_TO_DATE: 154 | this.panel.info.string = "Already up to date with the latest remote version."; 155 | break; 156 | case jsb.EventAssetsManager.NEW_VERSION_FOUND: 157 | this.panel.info.string = 'New version found, please try to update. (' + Math.ceil(this._am.getTotalBytes() / 1024) + 'kb)'; 158 | this.panel.checkBtn.active = false; 159 | this.panel.fileProgress.progress = 0; 160 | this.panel.byteProgress.progress = 0; 161 | break; 162 | default: 163 | return; 164 | } 165 | 166 | 167 | this._am.setEventCallback(null!); 168 | this._checkListener = null; 169 | this._updating = false; 170 | } 171 | 172 | updateCb(event: any) { 173 | var needRestart = false; 174 | var failed = false; 175 | switch (event.getEventCode()) { 176 | case jsb.EventAssetsManager.ERROR_NO_LOCAL_MANIFEST: 177 | this.panel.info.string = 'No local manifest file found, hot update skipped.'; 178 | failed = true; 179 | break; 180 | case jsb.EventAssetsManager.UPDATE_PROGRESSION: 181 | this.panel.byteProgress.progress = event.getPercent(); 182 | this.panel.fileProgress.progress = event.getPercentByFile(); 183 | 184 | this.panel.fileLabel.string = event.getDownloadedFiles() + ' / ' + event.getTotalFiles(); 185 | this.panel.byteLabel.string = event.getDownloadedBytes() + ' / ' + event.getTotalBytes(); 186 | console.log(this.panel.fileLabel.string, this.panel.byteLabel.string); 187 | var msg = event.getMessage(); 188 | if (msg) { 189 | this.panel.info.string = 'Updated file: ' + msg; 190 | // cc.log(event.getPercent()/100 + '% : ' + msg); 191 | } 192 | break; 193 | case jsb.EventAssetsManager.ERROR_DOWNLOAD_MANIFEST: 194 | case jsb.EventAssetsManager.ERROR_PARSE_MANIFEST: 195 | this.panel.info.string = 'Fail to download manifest file, hot update skipped.'; 196 | failed = true; 197 | break; 198 | case jsb.EventAssetsManager.ALREADY_UP_TO_DATE: 199 | this.panel.info.string = 'Already up to date with the latest remote version.'; 200 | failed = true; 201 | break; 202 | case jsb.EventAssetsManager.UPDATE_FINISHED: 203 | this.panel.info.string = 'Update finished. ' + event.getMessage(); 204 | needRestart = true; 205 | break; 206 | case jsb.EventAssetsManager.UPDATE_FAILED: 207 | this.panel.info.string = 'Update failed. ' + event.getMessage(); 208 | this.panel.retryBtn.active = true; 209 | this._updating = false; 210 | this._canRetry = true; 211 | break; 212 | case jsb.EventAssetsManager.ERROR_UPDATING: 213 | this.panel.info.string = 'Asset update error: ' + event.getAssetId() + ', ' + event.getMessage(); 214 | break; 215 | case jsb.EventAssetsManager.ERROR_DECOMPRESS: 216 | this.panel.info.string = event.getMessage(); 217 | break; 218 | default: 219 | break; 220 | } 221 | 222 | if (failed) { 223 | this._am.setEventCallback(null!); 224 | this._updateListener = null; 225 | this._updating = false; 226 | } 227 | 228 | if (needRestart) { 229 | this._am.setEventCallback(null!); 230 | this._updateListener = null; 231 | // Prepend the manifest's search path 232 | var searchPaths = jsb.fileUtils.getSearchPaths(); 233 | var newPaths = this._am.getLocalManifest().getSearchPaths(); 234 | console.log(JSON.stringify(newPaths)); 235 | Array.prototype.unshift.apply(searchPaths, newPaths); 236 | // This value will be retrieved and appended to the default search path during game startup, 237 | // please refer to samples/js-tests/main.js for detailed usage. 238 | // !!! Re-add the search paths in main.js is very important, otherwise, new scripts won't take effect. 239 | localStorage.setItem('HotUpdateSearchPaths', JSON.stringify(searchPaths)); 240 | jsb.fileUtils.setSearchPaths(searchPaths); 241 | 242 | // restart game. 243 | setTimeout(() => { 244 | game.restart(); 245 | }, 1000) 246 | } 247 | } 248 | 249 | loadCustomManifest() { 250 | if (this._am.getState() === jsb.AssetsManager.State.UNINITED) { 251 | var manifest = new jsb.Manifest(customManifestStr, this._storagePath); 252 | this._am.loadLocalManifest(manifest, this._storagePath); 253 | this.panel.info.string = 'Using custom manifest'; 254 | } 255 | } 256 | 257 | retry() { 258 | if (!this._updating && this._canRetry) { 259 | this.panel.retryBtn.active = false; 260 | this._canRetry = false; 261 | 262 | this.panel.info.string = 'Retry failed Assets...'; 263 | this._am.downloadFailedAssets(); 264 | } 265 | } 266 | 267 | checkUpdate() { 268 | if (this._updating) { 269 | this.panel.info.string = 'Checking or updating ...'; 270 | return; 271 | } 272 | if (this._am.getState() === jsb.AssetsManager.State.UNINITED) { 273 | var url = this.manifestUrl.nativeUrl; 274 | this._am.loadLocalManifest(url); 275 | } 276 | if (!this._am.getLocalManifest() || !this._am.getLocalManifest().isLoaded()) { 277 | this.panel.info.string = 'Failed to load local manifest ...'; 278 | return; 279 | } 280 | this._am.setEventCallback(this.checkCb.bind(this)); 281 | 282 | this._am.checkUpdate(); 283 | this._updating = true; 284 | } 285 | 286 | hotUpdate() { 287 | if (this._am && !this._updating) { 288 | this._am.setEventCallback(this.updateCb.bind(this)); 289 | 290 | if (this._am.getState() === jsb.AssetsManager.State.UNINITED) { 291 | var url = this.manifestUrl.nativeUrl; 292 | this._am.loadLocalManifest(url); 293 | } 294 | 295 | this._failCount = 0; 296 | this._am.update(); 297 | this.panel.updateBtn.active = false; 298 | this._updating = true; 299 | } 300 | } 301 | 302 | show() { 303 | if (this.updateUI.active === false) { 304 | this.updateUI.active = true; 305 | } 306 | } 307 | 308 | // use this for initialization 309 | onLoad() { 310 | // Hot update is only available in Native build 311 | if (!jsb) { 312 | return; 313 | } 314 | this._storagePath = ((jsb.fileUtils ? jsb.fileUtils.getWritablePath() : '/') + 'blackjack-remote-asset'); 315 | console.log('Storage path for remote asset : ' + this._storagePath); 316 | 317 | // Setup your own version compare handler, versionA and B is versions in string 318 | // if the return value greater than 0, versionA is greater than B, 319 | // if the return value equals 0, versionA equals to B, 320 | // if the return value smaller than 0, versionA is smaller than B. 321 | this.versionCompareHandle = function (versionA: string, versionB: string) { 322 | console.log("JS Custom Version Compare: version A is " + versionA + ', version B is ' + versionB); 323 | var vA = versionA.split('.'); 324 | var vB = versionB.split('.'); 325 | for (var i = 0; i < vA.length; ++i) { 326 | var a = parseInt(vA[i]); 327 | var b = parseInt(vB[i] || '0'); 328 | if (a === b) { 329 | continue; 330 | } 331 | else { 332 | return a - b; 333 | } 334 | } 335 | if (vB.length > vA.length) { 336 | return -1; 337 | } 338 | else { 339 | return 0; 340 | } 341 | }; 342 | 343 | // Init with empty manifest url for testing custom manifest 344 | this._am = new jsb.AssetsManager('', this._storagePath, this.versionCompareHandle); 345 | 346 | var panel = this.panel; 347 | // Setup the verification callback, but we don't have md5 check function yet, so only print some message 348 | // Return true if the verification passed, otherwise return false 349 | this._am.setVerifyCallback(function (path: string, asset: any) { 350 | // When asset is compressed, we don't need to check its md5, because zip file have been deleted. 351 | var compressed = asset.compressed; 352 | // Retrieve the correct md5 value. 353 | var expectedMD5 = asset.md5; 354 | // asset.path is relative path and path is absolute. 355 | var relativePath = asset.path; 356 | // The size of asset file, but this value could be absent. 357 | var size = asset.size; 358 | if (compressed) { 359 | panel.info.string = "Verification passed : " + relativePath; 360 | return true; 361 | } 362 | else { 363 | panel.info.string = "Verification passed : " + relativePath + ' (' + expectedMD5 + ')'; 364 | return true; 365 | } 366 | }); 367 | 368 | this.panel.info.string = 'Hot update is ready, please check or directly update.'; 369 | this.panel.fileProgress.progress = 0; 370 | this.panel.byteProgress.progress = 0; 371 | } 372 | 373 | onDestroy() { 374 | if (this._updateListener) { 375 | this._am.setEventCallback(null!); 376 | this._updateListener = null; 377 | } 378 | } 379 | } 380 | -------------------------------------------------------------------------------- /assets/hotupdate/HotUpdate.ts.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "4.0.22", 3 | "importer": "typescript", 4 | "imported": true, 5 | "uuid": "8ee7ab5e-ece5-4312-9876-aee14260b419", 6 | "files": [], 7 | "subMetas": {}, 8 | "userData": { 9 | "importAsPlugin": false, 10 | "moduleId": "project:///assets/hotupdate/HotUpdate.js", 11 | "importerSettings": 7, 12 | "simulateGlobals": [] 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /assets/hotupdate/UpdatePanel.ts: -------------------------------------------------------------------------------- 1 | 2 | import { _decorator, Component, Node, Label, ProgressBar } from 'cc'; 3 | const { ccclass, property } = _decorator; 4 | 5 | @ccclass('UpdatePanel') 6 | export class UpdatePanel extends Component { 7 | 8 | @property(Label) 9 | info: Label = null!; 10 | 11 | @property(ProgressBar) 12 | fileProgress: ProgressBar = null!; 13 | 14 | @property(Label) 15 | fileLabel: Label = null!; 16 | @property(ProgressBar) 17 | byteProgress: ProgressBar = null!; 18 | 19 | @property(Label) 20 | byteLabel: Label = null!; 21 | 22 | @property(Node) 23 | close: Node = null!; 24 | 25 | @property(Node) 26 | checkBtn: Node = null!; 27 | 28 | @property(Node) 29 | retryBtn: Node = null!; 30 | 31 | @property(Node) 32 | updateBtn: Node = null!; 33 | 34 | onLoad() { 35 | 36 | } 37 | }; 38 | -------------------------------------------------------------------------------- /assets/hotupdate/UpdatePanel.ts.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "4.0.22", 3 | "importer": "typescript", 4 | "imported": true, 5 | "uuid": "d896f161-064f-40e7-b80b-32f123dca67b", 6 | "files": [], 7 | "subMetas": {}, 8 | "userData": { 9 | "importAsPlugin": false, 10 | "moduleId": "project:///assets/hotupdate/UpdatePanel.js", 11 | "importerSettings": 7, 12 | "simulateGlobals": [] 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /assets/project.manifest: -------------------------------------------------------------------------------- 1 | {"packageUrl":"http://192.168.130.1:7879/","remoteManifestUrl":"http://192.168.130.1:7879/project.manifest","remoteVersionUrl":"http://192.168.130.1:7879/version.manifest","version":"1.0.0","assets":{"src/application.js":{"size":5737,"md5":"967be77b81844d12da3a017805063af8"},"src/chunks/bundle.js":{"size":2117,"md5":"22ffaa7f19440b6caf742dc770192a16"},"src/cocos-js/cc.js":{"size":4234551,"md5":"76f378a82794c677f187122c85a54f02"},"src/cocos-js/instantiated-23df9b40.js":{"size":3810813,"md5":"214be7b9f80ac6fe1137533c94b16fdb"},"src/cocos-js/wait-for-ammo-instantiation.js":{"size":1546,"md5":"8edfd332991fbf777f5932e07216794b"},"src/import-map.json":{"size":131,"md5":"9f3cb7d333c139e53c921d6fdea86985"},"src/settings.json":{"size":32131,"md5":"ce23b545d31618e514a5ce4460304b07"},"src/system.bundle.js":{"size":19420,"md5":"615d022bc5f1f90f8e22462caebc2325"},"assets/main/cc.config.json":{"size":2581,"md5":"1af88db206fa327ac81796e66bca662e"},"assets/main/import/08/0897a7610.json":{"size":318,"md5":"ef906f0c6da75dea910377524c7ad8d2"},"assets/main/import/09/09206bb20.json":{"size":394,"md5":"7fd539c3626fe13a1e29ea2541f1dd98"},"assets/main/import/0f/0f4f09600.json":{"size":8044,"md5":"0783e8b10b27abb13086f53064457f66"},"assets/main/import/fd/fd8ec536-a354-4a17-9c74-4f3883c378c8.json":{"size":480,"md5":"731f44a39ce9377ee6de8ba34edaf039"},"assets/main/index.js":{"size":22133,"md5":"9de01d6b989ae522d1a6c173030b6080"},"assets/main/native/70/700faa17-11a6-46cd-aeb5-d6900bc264f8.png":{"size":3765,"md5":"878e89a0a3e02b13beee9f3274f2ca39"},"assets/main/native/80/800f94fd-7424-4202-9629-d3ca77f3b72d.manifest":{"size":2343,"md5":"f85dc5cbdc88cd3db1e71f7212035739"},"assets/main/native/9e/9e71ecbc-8d63-45dd-b0e3-26cefa3d07b1.png":{"size":2548,"md5":"ae7a04af25e238a5478170759b55a7ba"},"assets/main/native/ae/ae4e2188-2b7b-42a9-85e1-8fb987600b04.png":{"size":634171,"md5":"07b03f7145b75579708ae05ea2a2c029"},"assets/main/native/c1/c1e757ac-f5bb-46ed-b86a-fdabff7aeb55.png":{"size":18969,"md5":"8eaaf03d4497b39525214bf039a11a7d"},"assets/main/native/ed/edd97988-52a3-4312-8671-90a51bb563ae.png":{"size":1829,"md5":"94d761c4626df88053787f17fa09914d"},"jsb-adapter/jsb-builtin.js":{"size":166398,"md5":"1b647a82982dbed2f22785b602416c64"},"jsb-adapter/jsb-engine.js":{"size":153770,"md5":"46fd2018cb2a7428cc6abf618f719dda"}},"searchPaths":[]} -------------------------------------------------------------------------------- /assets/project.manifest.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.0", 3 | "importer": "*", 4 | "imported": true, 5 | "uuid": "800f94fd-7424-4202-9629-d3ca77f3b72d", 6 | "files": [ 7 | ".manifest", 8 | ".json" 9 | ], 10 | "subMetas": {}, 11 | "userData": {} 12 | } 13 | -------------------------------------------------------------------------------- /assets/scenes.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.1.0", 3 | "importer": "directory", 4 | "imported": true, 5 | "uuid": "9ec567bd-9e78-4409-8b3b-29b5b38bd52d", 6 | "files": [], 7 | "subMetas": {}, 8 | "userData": { 9 | "compressionType": {}, 10 | "isRemoteBundle": {} 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /assets/scenes/menu.scene: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "__type__": "cc.SceneAsset", 4 | "_name": "", 5 | "_objFlags": 0, 6 | "_native": "", 7 | "scene": { 8 | "__id__": 1 9 | } 10 | }, 11 | { 12 | "__type__": "cc.Scene", 13 | "_name": "menu", 14 | "_objFlags": 0, 15 | "_parent": null, 16 | "_children": [ 17 | { 18 | "__id__": 2 19 | }, 20 | { 21 | "__id__": 5 22 | } 23 | ], 24 | "_active": true, 25 | "_components": [], 26 | "_prefab": null, 27 | "autoReleaseAssets": false, 28 | "_globals": { 29 | "__id__": 98 30 | }, 31 | "_id": "8a546935-70d4-42d2-a051-8d0e76f28008" 32 | }, 33 | { 34 | "__type__": "cc.Node", 35 | "_name": "Main Camera", 36 | "_objFlags": 0, 37 | "_parent": { 38 | "__id__": 1 39 | }, 40 | "_children": [], 41 | "_active": true, 42 | "_components": [ 43 | { 44 | "__id__": 3 45 | }, 46 | { 47 | "__id__": 4 48 | } 49 | ], 50 | "_prefab": null, 51 | "_lpos": { 52 | "__type__": "cc.Vec3", 53 | "x": 480, 54 | "y": 320, 55 | "z": 319.56337399645787 56 | }, 57 | "_lrot": { 58 | "__type__": "cc.Quat", 59 | "x": 0, 60 | "y": 0, 61 | "z": 0, 62 | "w": 1 63 | }, 64 | "_lscale": { 65 | "__type__": "cc.Vec3", 66 | "x": 1, 67 | "y": 1, 68 | "z": 1 69 | }, 70 | "_layer": 524288, 71 | "_euler": { 72 | "__type__": "cc.Vec3", 73 | "x": 0, 74 | "y": 0, 75 | "z": 0 76 | }, 77 | "_id": "b91TBKWQVGnpsCQCMLeQOL" 78 | }, 79 | { 80 | "__type__": "cc.Camera", 81 | "_name": "", 82 | "_objFlags": 0, 83 | "node": { 84 | "__id__": 2 85 | }, 86 | "_enabled": true, 87 | "__prefab": null, 88 | "_projection": 1, 89 | "_priority": 0, 90 | "_fov": 60, 91 | "_fovAxis": 0, 92 | "_orthoHeight": 10, 93 | "_near": 1, 94 | "_far": 1000, 95 | "_color": { 96 | "__type__": "cc.Color", 97 | "r": 51, 98 | "g": 51, 99 | "b": 51, 100 | "a": 255 101 | }, 102 | "_depth": -1, 103 | "_stencil": 0, 104 | "_clearFlags": 0, 105 | "_rect": { 106 | "__type__": "cc.Rect", 107 | "x": 0, 108 | "y": 0, 109 | "width": 1, 110 | "height": 1 111 | }, 112 | "_aperture": 19, 113 | "_shutter": 7, 114 | "_iso": 0, 115 | "_screenScale": 1, 116 | "_visibility": 1107296256, 117 | "_targetTexture": null, 118 | "_id": "a8EbTwsk5IRbnQH7d9intQ" 119 | }, 120 | { 121 | "__type__": "cc.UITransform", 122 | "_name": "", 123 | "_objFlags": 0, 124 | "node": { 125 | "__id__": 2 126 | }, 127 | "_enabled": true, 128 | "__prefab": null, 129 | "_contentSize": { 130 | "__type__": "cc.Size", 131 | "width": 0, 132 | "height": 0 133 | }, 134 | "_anchorPoint": { 135 | "__type__": "cc.Vec2", 136 | "x": 0.5, 137 | "y": 0.5 138 | }, 139 | "_id": "bdp0Piwa1F0LopFYX1ZUBS" 140 | }, 141 | { 142 | "__type__": "cc.Node", 143 | "_name": "Canvas", 144 | "_objFlags": 0, 145 | "_parent": { 146 | "__id__": 1 147 | }, 148 | "_children": [ 149 | { 150 | "__id__": 6 151 | }, 152 | { 153 | "__id__": 13 154 | }, 155 | { 156 | "__id__": 92 157 | } 158 | ], 159 | "_active": true, 160 | "_components": [ 161 | { 162 | "__id__": 94 163 | }, 164 | { 165 | "__id__": 95 166 | }, 167 | { 168 | "__id__": 96 169 | }, 170 | { 171 | "__id__": 97 172 | } 173 | ], 174 | "_prefab": null, 175 | "_lpos": { 176 | "__type__": "cc.Vec3", 177 | "x": 480, 178 | "y": 320, 179 | "z": 0 180 | }, 181 | "_lrot": { 182 | "__type__": "cc.Quat", 183 | "x": 0, 184 | "y": 0, 185 | "z": 0, 186 | "w": 1 187 | }, 188 | "_lscale": { 189 | "__type__": "cc.Vec3", 190 | "x": 1, 191 | "y": 1, 192 | "z": 1 193 | }, 194 | "_layer": 33554432, 195 | "_euler": { 196 | "__type__": "cc.Vec3", 197 | "x": 0, 198 | "y": 0, 199 | "z": 0 200 | }, 201 | "_id": "aa2f6rtn5pHHZr289ji53Oy" 202 | }, 203 | { 204 | "__type__": "cc.Node", 205 | "_name": "bg", 206 | "_objFlags": 0, 207 | "_parent": { 208 | "__id__": 5 209 | }, 210 | "_children": [], 211 | "_active": true, 212 | "_components": [ 213 | { 214 | "__id__": 7 215 | }, 216 | { 217 | "__id__": 9 218 | }, 219 | { 220 | "__id__": 11 221 | } 222 | ], 223 | "_prefab": null, 224 | "_lpos": { 225 | "__type__": "cc.Vec3", 226 | "x": 0, 227 | "y": 0, 228 | "z": 0 229 | }, 230 | "_lrot": { 231 | "__type__": "cc.Quat", 232 | "x": 0, 233 | "y": 0, 234 | "z": 0, 235 | "w": 1 236 | }, 237 | "_lscale": { 238 | "__type__": "cc.Vec3", 239 | "x": 1, 240 | "y": 1, 241 | "z": 1 242 | }, 243 | "_layer": 524288, 244 | "_euler": { 245 | "__type__": "cc.Vec3", 246 | "x": 0, 247 | "y": 0, 248 | "z": 0 249 | }, 250 | "_id": "92e8bSqadxD1oL6wMhnQZX9" 251 | }, 252 | { 253 | "__type__": "cc.Sprite", 254 | "_name": "", 255 | "_objFlags": 0, 256 | "node": { 257 | "__id__": 6 258 | }, 259 | "_enabled": true, 260 | "__prefab": { 261 | "__id__": 8 262 | }, 263 | "_visFlags": 0, 264 | "_customMaterial": null, 265 | "_srcBlendFactor": 2, 266 | "_dstBlendFactor": 4, 267 | "_color": { 268 | "__type__": "cc.Color", 269 | "r": 255, 270 | "g": 255, 271 | "b": 255, 272 | "a": 255 273 | }, 274 | "_spriteFrame": { 275 | "__uuid__": "ae4e2188-2b7b-42a9-85e1-8fb987600b04@f9941", 276 | "__expectedType__": "cc.SpriteFrame" 277 | }, 278 | "_type": 0, 279 | "_fillType": 0, 280 | "_sizeMode": 0, 281 | "_fillCenter": { 282 | "__type__": "cc.Vec2", 283 | "x": 0, 284 | "y": 0 285 | }, 286 | "_fillStart": 0, 287 | "_fillRange": 0, 288 | "_isTrimmedMode": true, 289 | "_useGrayscale": false, 290 | "_atlas": null, 291 | "_id": "64NMWGYFdHpohIgjD/+dCa" 292 | }, 293 | { 294 | "__type__": "cc.CompPrefabInfo", 295 | "fileId": "64NMWGYFdHpohIgjD/+dCa" 296 | }, 297 | { 298 | "__type__": "cc.Widget", 299 | "_name": "", 300 | "_objFlags": 0, 301 | "node": { 302 | "__id__": 6 303 | }, 304 | "_enabled": true, 305 | "__prefab": { 306 | "__id__": 10 307 | }, 308 | "_alignFlags": 45, 309 | "_target": null, 310 | "_left": 0, 311 | "_right": 0, 312 | "_top": 0, 313 | "_bottom": 0, 314 | "_horizontalCenter": 0, 315 | "_verticalCenter": 0, 316 | "_isAbsLeft": true, 317 | "_isAbsRight": true, 318 | "_isAbsTop": true, 319 | "_isAbsBottom": true, 320 | "_isAbsHorizontalCenter": true, 321 | "_isAbsVerticalCenter": true, 322 | "_originalWidth": 1334, 323 | "_originalHeight": 750, 324 | "_alignMode": 0, 325 | "_lockFlags": 0, 326 | "_id": "e5pQWfH8pAr6g2T42jmALB" 327 | }, 328 | { 329 | "__type__": "cc.CompPrefabInfo", 330 | "fileId": "e5pQWfH8pAr6g2T42jmALB" 331 | }, 332 | { 333 | "__type__": "cc.UITransform", 334 | "_name": "", 335 | "_objFlags": 0, 336 | "node": { 337 | "__id__": 6 338 | }, 339 | "_enabled": true, 340 | "__prefab": { 341 | "__id__": 12 342 | }, 343 | "_contentSize": { 344 | "__type__": "cc.Size", 345 | "width": 960, 346 | "height": 640 347 | }, 348 | "_anchorPoint": { 349 | "__type__": "cc.Vec2", 350 | "x": 0.5, 351 | "y": 0.5 352 | }, 353 | "_id": "a4uf8vIFNCBp0PSFstiQGr" 354 | }, 355 | { 356 | "__type__": "cc.CompPrefabInfo", 357 | "fileId": "a4uf8vIFNCBp0PSFstiQGr" 358 | }, 359 | { 360 | "__type__": "cc.Node", 361 | "_name": "update", 362 | "_objFlags": 0, 363 | "_parent": { 364 | "__id__": 5 365 | }, 366 | "_children": [ 367 | { 368 | "__id__": 14 369 | }, 370 | { 371 | "__id__": 18 372 | } 373 | ], 374 | "_active": true, 375 | "_components": [ 376 | { 377 | "__id__": 90 378 | }, 379 | { 380 | "__id__": 91 381 | } 382 | ], 383 | "_prefab": null, 384 | "_lpos": { 385 | "__type__": "cc.Vec3", 386 | "x": 0, 387 | "y": 0, 388 | "z": 0 389 | }, 390 | "_lrot": { 391 | "__type__": "cc.Quat", 392 | "x": 0, 393 | "y": 0, 394 | "z": 0, 395 | "w": 1 396 | }, 397 | "_lscale": { 398 | "__type__": "cc.Vec3", 399 | "x": 0.7, 400 | "y": 0.7, 401 | "z": 1 402 | }, 403 | "_layer": 524288, 404 | "_euler": { 405 | "__type__": "cc.Vec3", 406 | "x": 0, 407 | "y": 0, 408 | "z": 0 409 | }, 410 | "_id": "ce5ee5STOlFPrlU01Uvc6J+" 411 | }, 412 | { 413 | "__type__": "cc.Node", 414 | "_name": "background_mask", 415 | "_objFlags": 0, 416 | "_parent": { 417 | "__id__": 13 418 | }, 419 | "_children": [], 420 | "_active": true, 421 | "_components": [ 422 | { 423 | "__id__": 15 424 | }, 425 | { 426 | "__id__": 16 427 | }, 428 | { 429 | "__id__": 17 430 | } 431 | ], 432 | "_prefab": null, 433 | "_lpos": { 434 | "__type__": "cc.Vec3", 435 | "x": 0, 436 | "y": 0, 437 | "z": 0 438 | }, 439 | "_lrot": { 440 | "__type__": "cc.Quat", 441 | "x": 0, 442 | "y": 0, 443 | "z": 0, 444 | "w": 1 445 | }, 446 | "_lscale": { 447 | "__type__": "cc.Vec3", 448 | "x": 1, 449 | "y": 1, 450 | "z": 1 451 | }, 452 | "_layer": 524288, 453 | "_euler": { 454 | "__type__": "cc.Vec3", 455 | "x": 0, 456 | "y": 0, 457 | "z": 0 458 | }, 459 | "_id": "c0d64DpcbtHJINtvy67FBxY" 460 | }, 461 | { 462 | "__type__": "cc.Sprite", 463 | "_name": "", 464 | "_objFlags": 0, 465 | "node": { 466 | "__id__": 14 467 | }, 468 | "_enabled": true, 469 | "__prefab": null, 470 | "_visFlags": 0, 471 | "_customMaterial": null, 472 | "_srcBlendFactor": 2, 473 | "_dstBlendFactor": 4, 474 | "_color": { 475 | "__type__": "cc.Color", 476 | "r": 255, 477 | "g": 255, 478 | "b": 255, 479 | "a": 205 480 | }, 481 | "_spriteFrame": { 482 | "__uuid__": "9e71ecbc-8d63-45dd-b0e3-26cefa3d07b1@f9941", 483 | "__expectedType__": "cc.SpriteFrame" 484 | }, 485 | "_type": 1, 486 | "_fillType": 0, 487 | "_sizeMode": 0, 488 | "_fillCenter": { 489 | "__type__": "cc.Vec2", 490 | "x": 0, 491 | "y": 0 492 | }, 493 | "_fillStart": 0, 494 | "_fillRange": 0, 495 | "_isTrimmedMode": true, 496 | "_useGrayscale": false, 497 | "_atlas": null, 498 | "_id": "b5zZG2tS5HfZja/GyffHv3" 499 | }, 500 | { 501 | "__type__": "cc.Widget", 502 | "_name": "", 503 | "_objFlags": 0, 504 | "node": { 505 | "__id__": 14 506 | }, 507 | "_enabled": true, 508 | "__prefab": null, 509 | "_alignFlags": 45, 510 | "_target": null, 511 | "_left": 0, 512 | "_right": 0, 513 | "_top": 0, 514 | "_bottom": 0, 515 | "_horizontalCenter": 0, 516 | "_verticalCenter": 0, 517 | "_isAbsLeft": true, 518 | "_isAbsRight": true, 519 | "_isAbsTop": true, 520 | "_isAbsBottom": true, 521 | "_isAbsHorizontalCenter": true, 522 | "_isAbsVerticalCenter": true, 523 | "_originalWidth": 54, 524 | "_originalHeight": 81, 525 | "_alignMode": 0, 526 | "_lockFlags": 0, 527 | "_id": "547mIpKDBBe6LOWFd2h1ll" 528 | }, 529 | { 530 | "__type__": "cc.UITransform", 531 | "_name": "", 532 | "_objFlags": 0, 533 | "node": { 534 | "__id__": 14 535 | }, 536 | "_enabled": true, 537 | "__prefab": null, 538 | "_contentSize": { 539 | "__type__": "cc.Size", 540 | "width": 1371.4285714285716, 541 | "height": 914.2857142857143 542 | }, 543 | "_anchorPoint": { 544 | "__type__": "cc.Vec2", 545 | "x": 0.5, 546 | "y": 0.5 547 | }, 548 | "_id": "25xPI4fuRD6oKWOVrMMFoN" 549 | }, 550 | { 551 | "__type__": "cc.Node", 552 | "_name": "update_panel", 553 | "_objFlags": 0, 554 | "_parent": { 555 | "__id__": 13 556 | }, 557 | "_children": [ 558 | { 559 | "__id__": 19 560 | }, 561 | { 562 | "__id__": 22 563 | }, 564 | { 565 | "__id__": 25 566 | }, 567 | { 568 | "__id__": 32 569 | }, 570 | { 571 | "__id__": 35 572 | }, 573 | { 574 | "__id__": 42 575 | }, 576 | { 577 | "__id__": 45 578 | }, 579 | { 580 | "__id__": 54 581 | }, 582 | { 583 | "__id__": 63 584 | }, 585 | { 586 | "__id__": 72 587 | }, 588 | { 589 | "__id__": 75 590 | }, 591 | { 592 | "__id__": 78 593 | } 594 | ], 595 | "_active": true, 596 | "_components": [ 597 | { 598 | "__id__": 87 599 | }, 600 | { 601 | "__id__": 88 602 | }, 603 | { 604 | "__id__": 89 605 | } 606 | ], 607 | "_prefab": null, 608 | "_lpos": { 609 | "__type__": "cc.Vec3", 610 | "x": 0, 611 | "y": 0, 612 | "z": 0 613 | }, 614 | "_lrot": { 615 | "__type__": "cc.Quat", 616 | "x": 0, 617 | "y": 0, 618 | "z": 0, 619 | "w": 1 620 | }, 621 | "_lscale": { 622 | "__type__": "cc.Vec3", 623 | "x": 1, 624 | "y": 1, 625 | "z": 1 626 | }, 627 | "_layer": 524288, 628 | "_euler": { 629 | "__type__": "cc.Vec3", 630 | "x": 0, 631 | "y": 0, 632 | "z": 0 633 | }, 634 | "_id": "44bf7dV9ndNoKsEAvu7p3MF" 635 | }, 636 | { 637 | "__type__": "cc.Node", 638 | "_name": "update_title", 639 | "_objFlags": 0, 640 | "_parent": { 641 | "__id__": 18 642 | }, 643 | "_children": [], 644 | "_active": true, 645 | "_components": [ 646 | { 647 | "__id__": 20 648 | }, 649 | { 650 | "__id__": 21 651 | } 652 | ], 653 | "_prefab": null, 654 | "_lpos": { 655 | "__type__": "cc.Vec3", 656 | "x": 0, 657 | "y": 267, 658 | "z": 0 659 | }, 660 | "_lrot": { 661 | "__type__": "cc.Quat", 662 | "x": 0, 663 | "y": 0, 664 | "z": 0, 665 | "w": 1 666 | }, 667 | "_lscale": { 668 | "__type__": "cc.Vec3", 669 | "x": 1, 670 | "y": 1, 671 | "z": 1 672 | }, 673 | "_layer": 524288, 674 | "_euler": { 675 | "__type__": "cc.Vec3", 676 | "x": 0, 677 | "y": 0, 678 | "z": 0 679 | }, 680 | "_id": "52617hgdZlJdI6xYnVIrwca" 681 | }, 682 | { 683 | "__type__": "cc.Label", 684 | "_name": "", 685 | "_objFlags": 0, 686 | "node": { 687 | "__id__": 19 688 | }, 689 | "_enabled": true, 690 | "__prefab": null, 691 | "_visFlags": 0, 692 | "_customMaterial": null, 693 | "_srcBlendFactor": 2, 694 | "_dstBlendFactor": 4, 695 | "_color": { 696 | "__type__": "cc.Color", 697 | "r": 255, 698 | "g": 255, 699 | "b": 255, 700 | "a": 255 701 | }, 702 | "_string": "热更新信息", 703 | "_horizontalAlign": 1, 704 | "_verticalAlign": 1, 705 | "_actualFontSize": 40, 706 | "_fontSize": 40, 707 | "_fontFamily": "Arial", 708 | "_lineHeight": 40, 709 | "_overflow": 0, 710 | "_enableWrapText": true, 711 | "_font": null, 712 | "_isSystemFontUsed": true, 713 | "_isItalic": false, 714 | "_isBold": false, 715 | "_isUnderline": false, 716 | "_underlineHeight": 0, 717 | "_cacheMode": 0, 718 | "_id": "625WFN2jFIBbIYt9OrFHHk" 719 | }, 720 | { 721 | "__type__": "cc.UITransform", 722 | "_name": "", 723 | "_objFlags": 0, 724 | "node": { 725 | "__id__": 19 726 | }, 727 | "_enabled": true, 728 | "__prefab": null, 729 | "_contentSize": { 730 | "__type__": "cc.Size", 731 | "width": 200, 732 | "height": 50.4 733 | }, 734 | "_anchorPoint": { 735 | "__type__": "cc.Vec2", 736 | "x": 0.5, 737 | "y": 0.5 738 | }, 739 | "_id": "d1cdNUa3JHS7gtP4BuPFmC" 740 | }, 741 | { 742 | "__type__": "cc.Node", 743 | "_name": "label1", 744 | "_objFlags": 0, 745 | "_parent": { 746 | "__id__": 18 747 | }, 748 | "_children": [], 749 | "_active": true, 750 | "_components": [ 751 | { 752 | "__id__": 23 753 | }, 754 | { 755 | "__id__": 24 756 | } 757 | ], 758 | "_prefab": null, 759 | "_lpos": { 760 | "__type__": "cc.Vec3", 761 | "x": -260, 762 | "y": 150, 763 | "z": 0 764 | }, 765 | "_lrot": { 766 | "__type__": "cc.Quat", 767 | "x": 0, 768 | "y": 0, 769 | "z": 0, 770 | "w": 1 771 | }, 772 | "_lscale": { 773 | "__type__": "cc.Vec3", 774 | "x": 1, 775 | "y": 1, 776 | "z": 1 777 | }, 778 | "_layer": 524288, 779 | "_euler": { 780 | "__type__": "cc.Vec3", 781 | "x": 0, 782 | "y": 0, 783 | "z": 0 784 | }, 785 | "_id": "fedf8JCNDRJ06CLq8ydLuZR" 786 | }, 787 | { 788 | "__type__": "cc.Label", 789 | "_name": "", 790 | "_objFlags": 0, 791 | "node": { 792 | "__id__": 22 793 | }, 794 | "_enabled": true, 795 | "__prefab": null, 796 | "_visFlags": 0, 797 | "_customMaterial": null, 798 | "_srcBlendFactor": 2, 799 | "_dstBlendFactor": 4, 800 | "_color": { 801 | "__type__": "cc.Color", 802 | "r": 255, 803 | "g": 255, 804 | "b": 255, 805 | "a": 255 806 | }, 807 | "_string": "File", 808 | "_horizontalAlign": 1, 809 | "_verticalAlign": 1, 810 | "_actualFontSize": 40, 811 | "_fontSize": 40, 812 | "_fontFamily": "Arial", 813 | "_lineHeight": 40, 814 | "_overflow": 2, 815 | "_enableWrapText": true, 816 | "_font": null, 817 | "_isSystemFontUsed": true, 818 | "_isItalic": false, 819 | "_isBold": false, 820 | "_isUnderline": false, 821 | "_underlineHeight": 0, 822 | "_cacheMode": 0, 823 | "_id": "60gfgQrwtNPrjuWYFiMSt4" 824 | }, 825 | { 826 | "__type__": "cc.UITransform", 827 | "_name": "", 828 | "_objFlags": 0, 829 | "node": { 830 | "__id__": 22 831 | }, 832 | "_enabled": true, 833 | "__prefab": null, 834 | "_contentSize": { 835 | "__type__": "cc.Size", 836 | "width": 150, 837 | "height": 40 838 | }, 839 | "_anchorPoint": { 840 | "__type__": "cc.Vec2", 841 | "x": 0.5, 842 | "y": 0.5 843 | }, 844 | "_id": "64WtBEbPtNG7oAagyS+4Vi" 845 | }, 846 | { 847 | "__type__": "cc.Node", 848 | "_name": "fileProgress", 849 | "_objFlags": 0, 850 | "_parent": { 851 | "__id__": 18 852 | }, 853 | "_children": [ 854 | { 855 | "__id__": 26 856 | } 857 | ], 858 | "_active": true, 859 | "_components": [ 860 | { 861 | "__id__": 29 862 | }, 863 | { 864 | "__id__": 30 865 | }, 866 | { 867 | "__id__": 31 868 | } 869 | ], 870 | "_prefab": null, 871 | "_lpos": { 872 | "__type__": "cc.Vec3", 873 | "x": 80, 874 | "y": 150, 875 | "z": 0 876 | }, 877 | "_lrot": { 878 | "__type__": "cc.Quat", 879 | "x": 0, 880 | "y": 0, 881 | "z": 0, 882 | "w": 1 883 | }, 884 | "_lscale": { 885 | "__type__": "cc.Vec3", 886 | "x": 1, 887 | "y": 1, 888 | "z": 1 889 | }, 890 | "_layer": 524288, 891 | "_euler": { 892 | "__type__": "cc.Vec3", 893 | "x": 0, 894 | "y": 0, 895 | "z": 0 896 | }, 897 | "_id": "f09a0KytdZBvq/02OJsCbnC" 898 | }, 899 | { 900 | "__type__": "cc.Node", 901 | "_name": "bar", 902 | "_objFlags": 0, 903 | "_parent": { 904 | "__id__": 25 905 | }, 906 | "_children": [], 907 | "_active": true, 908 | "_components": [ 909 | { 910 | "__id__": 27 911 | }, 912 | { 913 | "__id__": 28 914 | } 915 | ], 916 | "_prefab": null, 917 | "_lpos": { 918 | "__type__": "cc.Vec3", 919 | "x": -250, 920 | "y": 0, 921 | "z": 0 922 | }, 923 | "_lrot": { 924 | "__type__": "cc.Quat", 925 | "x": 0, 926 | "y": 0, 927 | "z": 0, 928 | "w": 1 929 | }, 930 | "_lscale": { 931 | "__type__": "cc.Vec3", 932 | "x": 1, 933 | "y": 1, 934 | "z": 1 935 | }, 936 | "_layer": 524288, 937 | "_euler": { 938 | "__type__": "cc.Vec3", 939 | "x": 0, 940 | "y": 0, 941 | "z": 0 942 | }, 943 | "_id": "fb941bdXWFH3ZPcByfqiPQC" 944 | }, 945 | { 946 | "__type__": "cc.Sprite", 947 | "_name": "", 948 | "_objFlags": 0, 949 | "node": { 950 | "__id__": 26 951 | }, 952 | "_enabled": true, 953 | "__prefab": null, 954 | "_visFlags": 0, 955 | "_customMaterial": null, 956 | "_srcBlendFactor": 2, 957 | "_dstBlendFactor": 4, 958 | "_color": { 959 | "__type__": "cc.Color", 960 | "r": 255, 961 | "g": 255, 962 | "b": 255, 963 | "a": 255 964 | }, 965 | "_spriteFrame": { 966 | "__uuid__": "9e71ecbc-8d63-45dd-b0e3-26cefa3d07b1@f9941", 967 | "__expectedType__": "cc.SpriteFrame" 968 | }, 969 | "_type": 1, 970 | "_fillType": 0, 971 | "_sizeMode": 0, 972 | "_fillCenter": { 973 | "__type__": "cc.Vec2", 974 | "x": 0, 975 | "y": 0 976 | }, 977 | "_fillStart": 0, 978 | "_fillRange": 0, 979 | "_isTrimmedMode": true, 980 | "_useGrayscale": false, 981 | "_atlas": null, 982 | "_id": "efRJ7Dx/5IXbCq+USDxq63" 983 | }, 984 | { 985 | "__type__": "cc.UITransform", 986 | "_name": "", 987 | "_objFlags": 0, 988 | "node": { 989 | "__id__": 26 990 | }, 991 | "_enabled": true, 992 | "__prefab": null, 993 | "_contentSize": { 994 | "__type__": "cc.Size", 995 | "width": 50, 996 | "height": 35 997 | }, 998 | "_anchorPoint": { 999 | "__type__": "cc.Vec2", 1000 | "x": 0, 1001 | "y": 0.5 1002 | }, 1003 | "_id": "70upxbystC0Zggpva8drOj" 1004 | }, 1005 | { 1006 | "__type__": "cc.Sprite", 1007 | "_name": "", 1008 | "_objFlags": 0, 1009 | "node": { 1010 | "__id__": 25 1011 | }, 1012 | "_enabled": true, 1013 | "__prefab": null, 1014 | "_visFlags": 0, 1015 | "_customMaterial": null, 1016 | "_srcBlendFactor": 2, 1017 | "_dstBlendFactor": 4, 1018 | "_color": { 1019 | "__type__": "cc.Color", 1020 | "r": 255, 1021 | "g": 255, 1022 | "b": 255, 1023 | "a": 255 1024 | }, 1025 | "_spriteFrame": { 1026 | "__uuid__": "edd97988-52a3-4312-8671-90a51bb563ae@f9941", 1027 | "__expectedType__": "cc.SpriteFrame" 1028 | }, 1029 | "_type": 1, 1030 | "_fillType": 0, 1031 | "_sizeMode": 0, 1032 | "_fillCenter": { 1033 | "__type__": "cc.Vec2", 1034 | "x": 0, 1035 | "y": 0 1036 | }, 1037 | "_fillStart": 0, 1038 | "_fillRange": 0, 1039 | "_isTrimmedMode": true, 1040 | "_useGrayscale": false, 1041 | "_atlas": null, 1042 | "_id": "2c7ZLl2ZJFOrFPKOp7knbO" 1043 | }, 1044 | { 1045 | "__type__": "cc.ProgressBar", 1046 | "_name": "", 1047 | "_objFlags": 0, 1048 | "node": { 1049 | "__id__": 25 1050 | }, 1051 | "_enabled": true, 1052 | "__prefab": null, 1053 | "_barSprite": { 1054 | "__id__": 27 1055 | }, 1056 | "_mode": 0, 1057 | "_totalLength": 500, 1058 | "_progress": 0.1, 1059 | "_reverse": false, 1060 | "_id": "abdtbhO+VF9Jsu57EkM88H" 1061 | }, 1062 | { 1063 | "__type__": "cc.UITransform", 1064 | "_name": "", 1065 | "_objFlags": 0, 1066 | "node": { 1067 | "__id__": 25 1068 | }, 1069 | "_enabled": true, 1070 | "__prefab": null, 1071 | "_contentSize": { 1072 | "__type__": "cc.Size", 1073 | "width": 500, 1074 | "height": 40 1075 | }, 1076 | "_anchorPoint": { 1077 | "__type__": "cc.Vec2", 1078 | "x": 0.5, 1079 | "y": 0.5 1080 | }, 1081 | "_id": "58tnoC6a1D5pjoMKrF152o" 1082 | }, 1083 | { 1084 | "__type__": "cc.Node", 1085 | "_name": "label2", 1086 | "_objFlags": 0, 1087 | "_parent": { 1088 | "__id__": 18 1089 | }, 1090 | "_children": [], 1091 | "_active": true, 1092 | "_components": [ 1093 | { 1094 | "__id__": 33 1095 | }, 1096 | { 1097 | "__id__": 34 1098 | } 1099 | ], 1100 | "_prefab": null, 1101 | "_lpos": { 1102 | "__type__": "cc.Vec3", 1103 | "x": -260, 1104 | "y": 40, 1105 | "z": 0 1106 | }, 1107 | "_lrot": { 1108 | "__type__": "cc.Quat", 1109 | "x": 0, 1110 | "y": 0, 1111 | "z": 0, 1112 | "w": 1 1113 | }, 1114 | "_lscale": { 1115 | "__type__": "cc.Vec3", 1116 | "x": 1, 1117 | "y": 1, 1118 | "z": 1 1119 | }, 1120 | "_layer": 524288, 1121 | "_euler": { 1122 | "__type__": "cc.Vec3", 1123 | "x": 0, 1124 | "y": 0, 1125 | "z": 0 1126 | }, 1127 | "_id": "36c11EiKsVDaK/q1d3qJHph" 1128 | }, 1129 | { 1130 | "__type__": "cc.Label", 1131 | "_name": "", 1132 | "_objFlags": 0, 1133 | "node": { 1134 | "__id__": 32 1135 | }, 1136 | "_enabled": true, 1137 | "__prefab": null, 1138 | "_visFlags": 0, 1139 | "_customMaterial": null, 1140 | "_srcBlendFactor": 2, 1141 | "_dstBlendFactor": 4, 1142 | "_color": { 1143 | "__type__": "cc.Color", 1144 | "r": 255, 1145 | "g": 255, 1146 | "b": 255, 1147 | "a": 255 1148 | }, 1149 | "_string": "Byte", 1150 | "_horizontalAlign": 1, 1151 | "_verticalAlign": 1, 1152 | "_actualFontSize": 40, 1153 | "_fontSize": 40, 1154 | "_fontFamily": "Arial", 1155 | "_lineHeight": 40, 1156 | "_overflow": 2, 1157 | "_enableWrapText": true, 1158 | "_font": null, 1159 | "_isSystemFontUsed": true, 1160 | "_isItalic": false, 1161 | "_isBold": false, 1162 | "_isUnderline": false, 1163 | "_underlineHeight": 0, 1164 | "_cacheMode": 0, 1165 | "_id": "26cDI7IABFI7o3t+ePQ2xP" 1166 | }, 1167 | { 1168 | "__type__": "cc.UITransform", 1169 | "_name": "", 1170 | "_objFlags": 0, 1171 | "node": { 1172 | "__id__": 32 1173 | }, 1174 | "_enabled": true, 1175 | "__prefab": null, 1176 | "_contentSize": { 1177 | "__type__": "cc.Size", 1178 | "width": 150, 1179 | "height": 40 1180 | }, 1181 | "_anchorPoint": { 1182 | "__type__": "cc.Vec2", 1183 | "x": 0.5, 1184 | "y": 0.5 1185 | }, 1186 | "_id": "acC+vWC51J5JIjSBnCP/SM" 1187 | }, 1188 | { 1189 | "__type__": "cc.Node", 1190 | "_name": "byteProgress", 1191 | "_objFlags": 0, 1192 | "_parent": { 1193 | "__id__": 18 1194 | }, 1195 | "_children": [ 1196 | { 1197 | "__id__": 36 1198 | } 1199 | ], 1200 | "_active": true, 1201 | "_components": [ 1202 | { 1203 | "__id__": 39 1204 | }, 1205 | { 1206 | "__id__": 40 1207 | }, 1208 | { 1209 | "__id__": 41 1210 | } 1211 | ], 1212 | "_prefab": null, 1213 | "_lpos": { 1214 | "__type__": "cc.Vec3", 1215 | "x": 80, 1216 | "y": 40, 1217 | "z": 0 1218 | }, 1219 | "_lrot": { 1220 | "__type__": "cc.Quat", 1221 | "x": 0, 1222 | "y": 0, 1223 | "z": 0, 1224 | "w": 1 1225 | }, 1226 | "_lscale": { 1227 | "__type__": "cc.Vec3", 1228 | "x": 1, 1229 | "y": 1, 1230 | "z": 1 1231 | }, 1232 | "_layer": 524288, 1233 | "_euler": { 1234 | "__type__": "cc.Vec3", 1235 | "x": 0, 1236 | "y": 0, 1237 | "z": 0 1238 | }, 1239 | "_id": "e9ba2fqLbhHp6FHjGyCMvCW" 1240 | }, 1241 | { 1242 | "__type__": "cc.Node", 1243 | "_name": "bar", 1244 | "_objFlags": 0, 1245 | "_parent": { 1246 | "__id__": 35 1247 | }, 1248 | "_children": [], 1249 | "_active": true, 1250 | "_components": [ 1251 | { 1252 | "__id__": 37 1253 | }, 1254 | { 1255 | "__id__": 38 1256 | } 1257 | ], 1258 | "_prefab": null, 1259 | "_lpos": { 1260 | "__type__": "cc.Vec3", 1261 | "x": -250, 1262 | "y": 0, 1263 | "z": 0 1264 | }, 1265 | "_lrot": { 1266 | "__type__": "cc.Quat", 1267 | "x": 0, 1268 | "y": 0, 1269 | "z": 0, 1270 | "w": 1 1271 | }, 1272 | "_lscale": { 1273 | "__type__": "cc.Vec3", 1274 | "x": 1, 1275 | "y": 1, 1276 | "z": 1 1277 | }, 1278 | "_layer": 524288, 1279 | "_euler": { 1280 | "__type__": "cc.Vec3", 1281 | "x": 0, 1282 | "y": 0, 1283 | "z": 0 1284 | }, 1285 | "_id": "c06430zILVGAIEaa4dvgn2H" 1286 | }, 1287 | { 1288 | "__type__": "cc.Sprite", 1289 | "_name": "", 1290 | "_objFlags": 0, 1291 | "node": { 1292 | "__id__": 36 1293 | }, 1294 | "_enabled": true, 1295 | "__prefab": null, 1296 | "_visFlags": 0, 1297 | "_customMaterial": null, 1298 | "_srcBlendFactor": 2, 1299 | "_dstBlendFactor": 4, 1300 | "_color": { 1301 | "__type__": "cc.Color", 1302 | "r": 255, 1303 | "g": 255, 1304 | "b": 255, 1305 | "a": 255 1306 | }, 1307 | "_spriteFrame": { 1308 | "__uuid__": "9e71ecbc-8d63-45dd-b0e3-26cefa3d07b1@f9941", 1309 | "__expectedType__": "cc.SpriteFrame" 1310 | }, 1311 | "_type": 1, 1312 | "_fillType": 0, 1313 | "_sizeMode": 0, 1314 | "_fillCenter": { 1315 | "__type__": "cc.Vec2", 1316 | "x": 0, 1317 | "y": 0 1318 | }, 1319 | "_fillStart": 0, 1320 | "_fillRange": 0, 1321 | "_isTrimmedMode": true, 1322 | "_useGrayscale": false, 1323 | "_atlas": null, 1324 | "_id": "adGbkaCUVNQo9vDnZvUiKh" 1325 | }, 1326 | { 1327 | "__type__": "cc.UITransform", 1328 | "_name": "", 1329 | "_objFlags": 0, 1330 | "node": { 1331 | "__id__": 36 1332 | }, 1333 | "_enabled": true, 1334 | "__prefab": null, 1335 | "_contentSize": { 1336 | "__type__": "cc.Size", 1337 | "width": 50, 1338 | "height": 35 1339 | }, 1340 | "_anchorPoint": { 1341 | "__type__": "cc.Vec2", 1342 | "x": 0, 1343 | "y": 0.5 1344 | }, 1345 | "_id": "3deT1fBc5Gf4i1WqfgfKqO" 1346 | }, 1347 | { 1348 | "__type__": "cc.Sprite", 1349 | "_name": "", 1350 | "_objFlags": 0, 1351 | "node": { 1352 | "__id__": 35 1353 | }, 1354 | "_enabled": true, 1355 | "__prefab": null, 1356 | "_visFlags": 0, 1357 | "_customMaterial": null, 1358 | "_srcBlendFactor": 2, 1359 | "_dstBlendFactor": 4, 1360 | "_color": { 1361 | "__type__": "cc.Color", 1362 | "r": 255, 1363 | "g": 255, 1364 | "b": 255, 1365 | "a": 255 1366 | }, 1367 | "_spriteFrame": { 1368 | "__uuid__": "edd97988-52a3-4312-8671-90a51bb563ae@f9941", 1369 | "__expectedType__": "cc.SpriteFrame" 1370 | }, 1371 | "_type": 1, 1372 | "_fillType": 0, 1373 | "_sizeMode": 0, 1374 | "_fillCenter": { 1375 | "__type__": "cc.Vec2", 1376 | "x": 0, 1377 | "y": 0 1378 | }, 1379 | "_fillStart": 0, 1380 | "_fillRange": 0, 1381 | "_isTrimmedMode": true, 1382 | "_useGrayscale": false, 1383 | "_atlas": null, 1384 | "_id": "45Dv+VVL5BPJA7qXKMlet1" 1385 | }, 1386 | { 1387 | "__type__": "cc.ProgressBar", 1388 | "_name": "", 1389 | "_objFlags": 0, 1390 | "node": { 1391 | "__id__": 35 1392 | }, 1393 | "_enabled": true, 1394 | "__prefab": null, 1395 | "_barSprite": { 1396 | "__id__": 37 1397 | }, 1398 | "_mode": 0, 1399 | "_totalLength": 500, 1400 | "_progress": 0.1, 1401 | "_reverse": false, 1402 | "_id": "deTv7jvOZJj6Kzdr4zpdWE" 1403 | }, 1404 | { 1405 | "__type__": "cc.UITransform", 1406 | "_name": "", 1407 | "_objFlags": 0, 1408 | "node": { 1409 | "__id__": 35 1410 | }, 1411 | "_enabled": true, 1412 | "__prefab": null, 1413 | "_contentSize": { 1414 | "__type__": "cc.Size", 1415 | "width": 500, 1416 | "height": 40 1417 | }, 1418 | "_anchorPoint": { 1419 | "__type__": "cc.Vec2", 1420 | "x": 0.5, 1421 | "y": 0.5 1422 | }, 1423 | "_id": "cbCZAgm1dCKIIz7MaKE/eV" 1424 | }, 1425 | { 1426 | "__type__": "cc.Node", 1427 | "_name": "info", 1428 | "_objFlags": 0, 1429 | "_parent": { 1430 | "__id__": 18 1431 | }, 1432 | "_children": [], 1433 | "_active": true, 1434 | "_components": [ 1435 | { 1436 | "__id__": 43 1437 | }, 1438 | { 1439 | "__id__": 44 1440 | } 1441 | ], 1442 | "_prefab": null, 1443 | "_lpos": { 1444 | "__type__": "cc.Vec3", 1445 | "x": 0, 1446 | "y": -111, 1447 | "z": 0 1448 | }, 1449 | "_lrot": { 1450 | "__type__": "cc.Quat", 1451 | "x": 0, 1452 | "y": 0, 1453 | "z": 0, 1454 | "w": 1 1455 | }, 1456 | "_lscale": { 1457 | "__type__": "cc.Vec3", 1458 | "x": 1, 1459 | "y": 1, 1460 | "z": 1 1461 | }, 1462 | "_layer": 524288, 1463 | "_euler": { 1464 | "__type__": "cc.Vec3", 1465 | "x": 0, 1466 | "y": 0, 1467 | "z": 0 1468 | }, 1469 | "_id": "3df75XUVDRNAZnzKT+Jgbv4" 1470 | }, 1471 | { 1472 | "__type__": "cc.Label", 1473 | "_name": "", 1474 | "_objFlags": 0, 1475 | "node": { 1476 | "__id__": 42 1477 | }, 1478 | "_enabled": true, 1479 | "__prefab": null, 1480 | "_visFlags": 0, 1481 | "_customMaterial": null, 1482 | "_srcBlendFactor": 2, 1483 | "_dstBlendFactor": 4, 1484 | "_color": { 1485 | "__type__": "cc.Color", 1486 | "r": 255, 1487 | "g": 255, 1488 | "b": 255, 1489 | "a": 255 1490 | }, 1491 | "_string": "Infomations:", 1492 | "_horizontalAlign": 0, 1493 | "_verticalAlign": 1, 1494 | "_actualFontSize": 23, 1495 | "_fontSize": 22, 1496 | "_fontFamily": "Arial", 1497 | "_lineHeight": 26, 1498 | "_overflow": 2, 1499 | "_enableWrapText": true, 1500 | "_font": null, 1501 | "_isSystemFontUsed": true, 1502 | "_isItalic": false, 1503 | "_isBold": false, 1504 | "_isUnderline": false, 1505 | "_underlineHeight": 0, 1506 | "_cacheMode": 0, 1507 | "_id": "02WCni1plKSJKXZXNLuxYO" 1508 | }, 1509 | { 1510 | "__type__": "cc.UITransform", 1511 | "_name": "", 1512 | "_objFlags": 0, 1513 | "node": { 1514 | "__id__": 42 1515 | }, 1516 | "_enabled": true, 1517 | "__prefab": null, 1518 | "_contentSize": { 1519 | "__type__": "cc.Size", 1520 | "width": 600, 1521 | "height": 100 1522 | }, 1523 | "_anchorPoint": { 1524 | "__type__": "cc.Vec2", 1525 | "x": 0.5, 1526 | "y": 0.5 1527 | }, 1528 | "_id": "47H0gQ6EJLWrPf6OyZj03u" 1529 | }, 1530 | { 1531 | "__type__": "cc.Node", 1532 | "_name": "check_btn", 1533 | "_objFlags": 0, 1534 | "_parent": { 1535 | "__id__": 18 1536 | }, 1537 | "_children": [ 1538 | { 1539 | "__id__": 46 1540 | } 1541 | ], 1542 | "_active": true, 1543 | "_components": [ 1544 | { 1545 | "__id__": 49 1546 | }, 1547 | { 1548 | "__id__": 50 1549 | }, 1550 | { 1551 | "__id__": 51 1552 | }, 1553 | { 1554 | "__id__": 53 1555 | } 1556 | ], 1557 | "_prefab": null, 1558 | "_lpos": { 1559 | "__type__": "cc.Vec3", 1560 | "x": -160, 1561 | "y": -220, 1562 | "z": 0 1563 | }, 1564 | "_lrot": { 1565 | "__type__": "cc.Quat", 1566 | "x": 0, 1567 | "y": 0, 1568 | "z": 0, 1569 | "w": 1 1570 | }, 1571 | "_lscale": { 1572 | "__type__": "cc.Vec3", 1573 | "x": 1, 1574 | "y": 1, 1575 | "z": 1 1576 | }, 1577 | "_layer": 524288, 1578 | "_euler": { 1579 | "__type__": "cc.Vec3", 1580 | "x": 0, 1581 | "y": 0, 1582 | "z": 0 1583 | }, 1584 | "_id": "6d113KHwRtPOJT1W52QhWrw" 1585 | }, 1586 | { 1587 | "__type__": "cc.Node", 1588 | "_name": "Label", 1589 | "_objFlags": 0, 1590 | "_parent": { 1591 | "__id__": 45 1592 | }, 1593 | "_children": [], 1594 | "_active": true, 1595 | "_components": [ 1596 | { 1597 | "__id__": 47 1598 | }, 1599 | { 1600 | "__id__": 48 1601 | } 1602 | ], 1603 | "_prefab": null, 1604 | "_lpos": { 1605 | "__type__": "cc.Vec3", 1606 | "x": 0, 1607 | "y": 11, 1608 | "z": 0 1609 | }, 1610 | "_lrot": { 1611 | "__type__": "cc.Quat", 1612 | "x": 0, 1613 | "y": 0, 1614 | "z": 0, 1615 | "w": 1 1616 | }, 1617 | "_lscale": { 1618 | "__type__": "cc.Vec3", 1619 | "x": 1, 1620 | "y": 1, 1621 | "z": 1 1622 | }, 1623 | "_layer": 524288, 1624 | "_euler": { 1625 | "__type__": "cc.Vec3", 1626 | "x": 0, 1627 | "y": 0, 1628 | "z": 0 1629 | }, 1630 | "_id": "eb3b5JB3QRPYarXaeay2Z84" 1631 | }, 1632 | { 1633 | "__type__": "cc.Label", 1634 | "_name": "", 1635 | "_objFlags": 0, 1636 | "node": { 1637 | "__id__": 46 1638 | }, 1639 | "_enabled": true, 1640 | "__prefab": null, 1641 | "_visFlags": 0, 1642 | "_customMaterial": null, 1643 | "_srcBlendFactor": 2, 1644 | "_dstBlendFactor": 4, 1645 | "_color": { 1646 | "__type__": "cc.Color", 1647 | "r": 0, 1648 | "g": 0, 1649 | "b": 0, 1650 | "a": 255 1651 | }, 1652 | "_string": "检查更新", 1653 | "_horizontalAlign": 1, 1654 | "_verticalAlign": 1, 1655 | "_actualFontSize": 30, 1656 | "_fontSize": 30, 1657 | "_fontFamily": "Arial", 1658 | "_lineHeight": 40, 1659 | "_overflow": 0, 1660 | "_enableWrapText": true, 1661 | "_font": null, 1662 | "_isSystemFontUsed": true, 1663 | "_isItalic": false, 1664 | "_isBold": false, 1665 | "_isUnderline": false, 1666 | "_underlineHeight": 0, 1667 | "_cacheMode": 0, 1668 | "_id": "cdqU2xCJxGRLp/uMUVoG7J" 1669 | }, 1670 | { 1671 | "__type__": "cc.UITransform", 1672 | "_name": "", 1673 | "_objFlags": 0, 1674 | "node": { 1675 | "__id__": 46 1676 | }, 1677 | "_enabled": true, 1678 | "__prefab": null, 1679 | "_contentSize": { 1680 | "__type__": "cc.Size", 1681 | "width": 120, 1682 | "height": 50.4 1683 | }, 1684 | "_anchorPoint": { 1685 | "__type__": "cc.Vec2", 1686 | "x": 0.5, 1687 | "y": 0.5 1688 | }, 1689 | "_id": "9ajriJdWhKl6pIT2D0Fuu0" 1690 | }, 1691 | { 1692 | "__type__": "cc.Widget", 1693 | "_name": "", 1694 | "_objFlags": 0, 1695 | "node": { 1696 | "__id__": 45 1697 | }, 1698 | "_enabled": true, 1699 | "__prefab": null, 1700 | "_alignFlags": 0, 1701 | "_target": null, 1702 | "_left": 0, 1703 | "_right": 0, 1704 | "_top": 0, 1705 | "_bottom": 0, 1706 | "_horizontalCenter": 0, 1707 | "_verticalCenter": 0, 1708 | "_isAbsLeft": true, 1709 | "_isAbsRight": true, 1710 | "_isAbsTop": true, 1711 | "_isAbsBottom": true, 1712 | "_isAbsHorizontalCenter": true, 1713 | "_isAbsVerticalCenter": true, 1714 | "_originalWidth": 0, 1715 | "_originalHeight": 0, 1716 | "_alignMode": 0, 1717 | "_lockFlags": 0, 1718 | "_id": "a7dRUkveBJjJhARq9jFD/A" 1719 | }, 1720 | { 1721 | "__type__": "cc.Sprite", 1722 | "_name": "", 1723 | "_objFlags": 0, 1724 | "node": { 1725 | "__id__": 45 1726 | }, 1727 | "_enabled": true, 1728 | "__prefab": null, 1729 | "_visFlags": 0, 1730 | "_customMaterial": null, 1731 | "_srcBlendFactor": 2, 1732 | "_dstBlendFactor": 4, 1733 | "_color": { 1734 | "__type__": "cc.Color", 1735 | "r": 255, 1736 | "g": 255, 1737 | "b": 255, 1738 | "a": 255 1739 | }, 1740 | "_spriteFrame": { 1741 | "__uuid__": "c1e757ac-f5bb-46ed-b86a-fdabff7aeb55@f9941", 1742 | "__expectedType__": "cc.SpriteFrame" 1743 | }, 1744 | "_type": 1, 1745 | "_fillType": 0, 1746 | "_sizeMode": 0, 1747 | "_fillCenter": { 1748 | "__type__": "cc.Vec2", 1749 | "x": 0, 1750 | "y": 0 1751 | }, 1752 | "_fillStart": 0, 1753 | "_fillRange": 0, 1754 | "_isTrimmedMode": true, 1755 | "_useGrayscale": false, 1756 | "_atlas": null, 1757 | "_id": "4cixFrrCJND52RmDrKlA74" 1758 | }, 1759 | { 1760 | "__type__": "cc.Button", 1761 | "_name": "", 1762 | "_objFlags": 0, 1763 | "node": { 1764 | "__id__": 45 1765 | }, 1766 | "_enabled": true, 1767 | "__prefab": null, 1768 | "clickEvents": [ 1769 | { 1770 | "__id__": 52 1771 | } 1772 | ], 1773 | "_interactable": true, 1774 | "_transition": 3, 1775 | "_normalColor": { 1776 | "__type__": "cc.Color", 1777 | "r": 255, 1778 | "g": 255, 1779 | "b": 255, 1780 | "a": 255 1781 | }, 1782 | "_hoverColor": { 1783 | "__type__": "cc.Color", 1784 | "r": 255, 1785 | "g": 255, 1786 | "b": 255, 1787 | "a": 255 1788 | }, 1789 | "_pressedColor": { 1790 | "__type__": "cc.Color", 1791 | "r": 255, 1792 | "g": 255, 1793 | "b": 255, 1794 | "a": 255 1795 | }, 1796 | "_disabledColor": { 1797 | "__type__": "cc.Color", 1798 | "r": 255, 1799 | "g": 255, 1800 | "b": 255, 1801 | "a": 255 1802 | }, 1803 | "_normalSprite": { 1804 | "__uuid__": "c1e757ac-f5bb-46ed-b86a-fdabff7aeb55@f9941", 1805 | "__expectedType__": "cc.SpriteFrame" 1806 | }, 1807 | "_hoverSprite": null, 1808 | "_pressedSprite": null, 1809 | "_disabledSprite": null, 1810 | "_duration": 0.1, 1811 | "_zoomScale": 1.2, 1812 | "_target": { 1813 | "__id__": 45 1814 | }, 1815 | "_id": "71Kr8XCpxKZ4CHZRDf4yT6" 1816 | }, 1817 | { 1818 | "__type__": "cc.ClickEvent", 1819 | "target": { 1820 | "__id__": 5 1821 | }, 1822 | "component": "HotUpdate", 1823 | "_componentId": "8ee7ate7OVDEph2ruFCYLQZ", 1824 | "handler": "checkUpdate", 1825 | "customEventData": "" 1826 | }, 1827 | { 1828 | "__type__": "cc.UITransform", 1829 | "_name": "", 1830 | "_objFlags": 0, 1831 | "node": { 1832 | "__id__": 45 1833 | }, 1834 | "_enabled": true, 1835 | "__prefab": null, 1836 | "_contentSize": { 1837 | "__type__": "cc.Size", 1838 | "width": 250, 1839 | "height": 100 1840 | }, 1841 | "_anchorPoint": { 1842 | "__type__": "cc.Vec2", 1843 | "x": 0.5, 1844 | "y": 0.5 1845 | }, 1846 | "_id": "c5edgpE+JGppuVR+fhYQEH" 1847 | }, 1848 | { 1849 | "__type__": "cc.Node", 1850 | "_name": "update_btn", 1851 | "_objFlags": 0, 1852 | "_parent": { 1853 | "__id__": 18 1854 | }, 1855 | "_children": [ 1856 | { 1857 | "__id__": 55 1858 | } 1859 | ], 1860 | "_active": true, 1861 | "_components": [ 1862 | { 1863 | "__id__": 58 1864 | }, 1865 | { 1866 | "__id__": 59 1867 | }, 1868 | { 1869 | "__id__": 60 1870 | }, 1871 | { 1872 | "__id__": 62 1873 | } 1874 | ], 1875 | "_prefab": null, 1876 | "_lpos": { 1877 | "__type__": "cc.Vec3", 1878 | "x": 160, 1879 | "y": -220, 1880 | "z": 0 1881 | }, 1882 | "_lrot": { 1883 | "__type__": "cc.Quat", 1884 | "x": 0, 1885 | "y": 0, 1886 | "z": 0, 1887 | "w": 1 1888 | }, 1889 | "_lscale": { 1890 | "__type__": "cc.Vec3", 1891 | "x": 1, 1892 | "y": 1, 1893 | "z": 1 1894 | }, 1895 | "_layer": 524288, 1896 | "_euler": { 1897 | "__type__": "cc.Vec3", 1898 | "x": 0, 1899 | "y": 0, 1900 | "z": 0 1901 | }, 1902 | "_id": "b657cAwGIVFkaM5c9zojOT1" 1903 | }, 1904 | { 1905 | "__type__": "cc.Node", 1906 | "_name": "Label", 1907 | "_objFlags": 0, 1908 | "_parent": { 1909 | "__id__": 54 1910 | }, 1911 | "_children": [], 1912 | "_active": true, 1913 | "_components": [ 1914 | { 1915 | "__id__": 56 1916 | }, 1917 | { 1918 | "__id__": 57 1919 | } 1920 | ], 1921 | "_prefab": null, 1922 | "_lpos": { 1923 | "__type__": "cc.Vec3", 1924 | "x": 0, 1925 | "y": 11, 1926 | "z": 0 1927 | }, 1928 | "_lrot": { 1929 | "__type__": "cc.Quat", 1930 | "x": 0, 1931 | "y": 0, 1932 | "z": 0, 1933 | "w": 1 1934 | }, 1935 | "_lscale": { 1936 | "__type__": "cc.Vec3", 1937 | "x": 1, 1938 | "y": 1, 1939 | "z": 1 1940 | }, 1941 | "_layer": 524288, 1942 | "_euler": { 1943 | "__type__": "cc.Vec3", 1944 | "x": 0, 1945 | "y": 0, 1946 | "z": 0 1947 | }, 1948 | "_id": "953db9KZftLHpskixRda+M3" 1949 | }, 1950 | { 1951 | "__type__": "cc.Label", 1952 | "_name": "", 1953 | "_objFlags": 0, 1954 | "node": { 1955 | "__id__": 55 1956 | }, 1957 | "_enabled": true, 1958 | "__prefab": null, 1959 | "_visFlags": 0, 1960 | "_customMaterial": null, 1961 | "_srcBlendFactor": 2, 1962 | "_dstBlendFactor": 4, 1963 | "_color": { 1964 | "__type__": "cc.Color", 1965 | "r": 0, 1966 | "g": 0, 1967 | "b": 0, 1968 | "a": 255 1969 | }, 1970 | "_string": "立即更新", 1971 | "_horizontalAlign": 1, 1972 | "_verticalAlign": 1, 1973 | "_actualFontSize": 30, 1974 | "_fontSize": 30, 1975 | "_fontFamily": "Arial", 1976 | "_lineHeight": 40, 1977 | "_overflow": 0, 1978 | "_enableWrapText": false, 1979 | "_font": null, 1980 | "_isSystemFontUsed": true, 1981 | "_isItalic": false, 1982 | "_isBold": false, 1983 | "_isUnderline": false, 1984 | "_underlineHeight": 0, 1985 | "_cacheMode": 0, 1986 | "_id": "f7IwVyywJOiKM3AoO6v6yQ" 1987 | }, 1988 | { 1989 | "__type__": "cc.UITransform", 1990 | "_name": "", 1991 | "_objFlags": 0, 1992 | "node": { 1993 | "__id__": 55 1994 | }, 1995 | "_enabled": true, 1996 | "__prefab": null, 1997 | "_contentSize": { 1998 | "__type__": "cc.Size", 1999 | "width": 120, 2000 | "height": 50.4 2001 | }, 2002 | "_anchorPoint": { 2003 | "__type__": "cc.Vec2", 2004 | "x": 0.5, 2005 | "y": 0.5 2006 | }, 2007 | "_id": "41Rz3XtRxAhrRZcYrCozSa" 2008 | }, 2009 | { 2010 | "__type__": "cc.Widget", 2011 | "_name": "", 2012 | "_objFlags": 0, 2013 | "node": { 2014 | "__id__": 54 2015 | }, 2016 | "_enabled": true, 2017 | "__prefab": null, 2018 | "_alignFlags": 0, 2019 | "_target": null, 2020 | "_left": 0, 2021 | "_right": 0, 2022 | "_top": 0, 2023 | "_bottom": 0, 2024 | "_horizontalCenter": 0, 2025 | "_verticalCenter": 0, 2026 | "_isAbsLeft": true, 2027 | "_isAbsRight": true, 2028 | "_isAbsTop": true, 2029 | "_isAbsBottom": true, 2030 | "_isAbsHorizontalCenter": true, 2031 | "_isAbsVerticalCenter": true, 2032 | "_originalWidth": 0, 2033 | "_originalHeight": 0, 2034 | "_alignMode": 0, 2035 | "_lockFlags": 0, 2036 | "_id": "e5Z3EEzNxNM53HBeXwW863" 2037 | }, 2038 | { 2039 | "__type__": "cc.Sprite", 2040 | "_name": "", 2041 | "_objFlags": 0, 2042 | "node": { 2043 | "__id__": 54 2044 | }, 2045 | "_enabled": true, 2046 | "__prefab": null, 2047 | "_visFlags": 0, 2048 | "_customMaterial": null, 2049 | "_srcBlendFactor": 2, 2050 | "_dstBlendFactor": 4, 2051 | "_color": { 2052 | "__type__": "cc.Color", 2053 | "r": 255, 2054 | "g": 255, 2055 | "b": 255, 2056 | "a": 255 2057 | }, 2058 | "_spriteFrame": { 2059 | "__uuid__": "c1e757ac-f5bb-46ed-b86a-fdabff7aeb55@f9941", 2060 | "__expectedType__": "cc.SpriteFrame" 2061 | }, 2062 | "_type": 1, 2063 | "_fillType": 0, 2064 | "_sizeMode": 0, 2065 | "_fillCenter": { 2066 | "__type__": "cc.Vec2", 2067 | "x": 0, 2068 | "y": 0 2069 | }, 2070 | "_fillStart": 0, 2071 | "_fillRange": 0, 2072 | "_isTrimmedMode": true, 2073 | "_useGrayscale": false, 2074 | "_atlas": null, 2075 | "_id": "479kljpd1Dhp+16saLA8OO" 2076 | }, 2077 | { 2078 | "__type__": "cc.Button", 2079 | "_name": "", 2080 | "_objFlags": 0, 2081 | "node": { 2082 | "__id__": 54 2083 | }, 2084 | "_enabled": true, 2085 | "__prefab": null, 2086 | "clickEvents": [ 2087 | { 2088 | "__id__": 61 2089 | } 2090 | ], 2091 | "_interactable": true, 2092 | "_transition": 3, 2093 | "_normalColor": { 2094 | "__type__": "cc.Color", 2095 | "r": 255, 2096 | "g": 255, 2097 | "b": 255, 2098 | "a": 255 2099 | }, 2100 | "_hoverColor": { 2101 | "__type__": "cc.Color", 2102 | "r": 255, 2103 | "g": 255, 2104 | "b": 255, 2105 | "a": 255 2106 | }, 2107 | "_pressedColor": { 2108 | "__type__": "cc.Color", 2109 | "r": 255, 2110 | "g": 255, 2111 | "b": 255, 2112 | "a": 255 2113 | }, 2114 | "_disabledColor": { 2115 | "__type__": "cc.Color", 2116 | "r": 255, 2117 | "g": 255, 2118 | "b": 255, 2119 | "a": 255 2120 | }, 2121 | "_normalSprite": { 2122 | "__uuid__": "c1e757ac-f5bb-46ed-b86a-fdabff7aeb55@f9941", 2123 | "__expectedType__": "cc.SpriteFrame" 2124 | }, 2125 | "_hoverSprite": null, 2126 | "_pressedSprite": null, 2127 | "_disabledSprite": null, 2128 | "_duration": 0.1, 2129 | "_zoomScale": 1.2, 2130 | "_target": { 2131 | "__id__": 54 2132 | }, 2133 | "_id": "1bBIwWqCtPmIAe66Mw/Dum" 2134 | }, 2135 | { 2136 | "__type__": "cc.ClickEvent", 2137 | "target": { 2138 | "__id__": 5 2139 | }, 2140 | "component": "HotUpdate", 2141 | "_componentId": "8ee7ate7OVDEph2ruFCYLQZ", 2142 | "handler": "hotUpdate", 2143 | "customEventData": "" 2144 | }, 2145 | { 2146 | "__type__": "cc.UITransform", 2147 | "_name": "", 2148 | "_objFlags": 0, 2149 | "node": { 2150 | "__id__": 54 2151 | }, 2152 | "_enabled": true, 2153 | "__prefab": null, 2154 | "_contentSize": { 2155 | "__type__": "cc.Size", 2156 | "width": 250, 2157 | "height": 100 2158 | }, 2159 | "_anchorPoint": { 2160 | "__type__": "cc.Vec2", 2161 | "x": 0.5, 2162 | "y": 0.5 2163 | }, 2164 | "_id": "24d5G2sPdJ/LCqBSp/8v44" 2165 | }, 2166 | { 2167 | "__type__": "cc.Node", 2168 | "_name": "retry_btn", 2169 | "_objFlags": 0, 2170 | "_parent": { 2171 | "__id__": 18 2172 | }, 2173 | "_children": [ 2174 | { 2175 | "__id__": 64 2176 | } 2177 | ], 2178 | "_active": false, 2179 | "_components": [ 2180 | { 2181 | "__id__": 67 2182 | }, 2183 | { 2184 | "__id__": 68 2185 | }, 2186 | { 2187 | "__id__": 69 2188 | }, 2189 | { 2190 | "__id__": 71 2191 | } 2192 | ], 2193 | "_prefab": null, 2194 | "_lpos": { 2195 | "__type__": "cc.Vec3", 2196 | "x": 160, 2197 | "y": -220, 2198 | "z": 0 2199 | }, 2200 | "_lrot": { 2201 | "__type__": "cc.Quat", 2202 | "x": 0, 2203 | "y": 0, 2204 | "z": 0, 2205 | "w": 1 2206 | }, 2207 | "_lscale": { 2208 | "__type__": "cc.Vec3", 2209 | "x": 1, 2210 | "y": 1, 2211 | "z": 1 2212 | }, 2213 | "_layer": 524288, 2214 | "_euler": { 2215 | "__type__": "cc.Vec3", 2216 | "x": 0, 2217 | "y": 0, 2218 | "z": 0 2219 | }, 2220 | "_id": "7678bzc/EhI7aEyPDwX4LPr" 2221 | }, 2222 | { 2223 | "__type__": "cc.Node", 2224 | "_name": "Label", 2225 | "_objFlags": 0, 2226 | "_parent": { 2227 | "__id__": 63 2228 | }, 2229 | "_children": [], 2230 | "_active": true, 2231 | "_components": [ 2232 | { 2233 | "__id__": 65 2234 | }, 2235 | { 2236 | "__id__": 66 2237 | } 2238 | ], 2239 | "_prefab": null, 2240 | "_lpos": { 2241 | "__type__": "cc.Vec3", 2242 | "x": 0, 2243 | "y": 11, 2244 | "z": 0 2245 | }, 2246 | "_lrot": { 2247 | "__type__": "cc.Quat", 2248 | "x": 0, 2249 | "y": 0, 2250 | "z": 0, 2251 | "w": 1 2252 | }, 2253 | "_lscale": { 2254 | "__type__": "cc.Vec3", 2255 | "x": 1, 2256 | "y": 1, 2257 | "z": 1 2258 | }, 2259 | "_layer": 524288, 2260 | "_euler": { 2261 | "__type__": "cc.Vec3", 2262 | "x": 0, 2263 | "y": 0, 2264 | "z": 0 2265 | }, 2266 | "_id": "36809f1dhZPiIYH6b5+QU9m" 2267 | }, 2268 | { 2269 | "__type__": "cc.Label", 2270 | "_name": "", 2271 | "_objFlags": 0, 2272 | "node": { 2273 | "__id__": 64 2274 | }, 2275 | "_enabled": true, 2276 | "__prefab": null, 2277 | "_visFlags": 0, 2278 | "_customMaterial": null, 2279 | "_srcBlendFactor": 2, 2280 | "_dstBlendFactor": 4, 2281 | "_color": { 2282 | "__type__": "cc.Color", 2283 | "r": 0, 2284 | "g": 0, 2285 | "b": 0, 2286 | "a": 255 2287 | }, 2288 | "_string": "重试更新", 2289 | "_horizontalAlign": 1, 2290 | "_verticalAlign": 1, 2291 | "_actualFontSize": 0, 2292 | "_fontSize": 30, 2293 | "_fontFamily": "Arial", 2294 | "_lineHeight": 40, 2295 | "_overflow": 0, 2296 | "_enableWrapText": true, 2297 | "_font": null, 2298 | "_isSystemFontUsed": true, 2299 | "_isItalic": false, 2300 | "_isBold": false, 2301 | "_isUnderline": false, 2302 | "_underlineHeight": 0, 2303 | "_cacheMode": 0, 2304 | "_id": "7crc2IQYRDqZrN7rSUKljF" 2305 | }, 2306 | { 2307 | "__type__": "cc.UITransform", 2308 | "_name": "", 2309 | "_objFlags": 0, 2310 | "node": { 2311 | "__id__": 64 2312 | }, 2313 | "_enabled": true, 2314 | "__prefab": null, 2315 | "_contentSize": { 2316 | "__type__": "cc.Size", 2317 | "width": 120, 2318 | "height": 40 2319 | }, 2320 | "_anchorPoint": { 2321 | "__type__": "cc.Vec2", 2322 | "x": 0.5, 2323 | "y": 0.5 2324 | }, 2325 | "_id": "cfBqrY8blK6KXrrXY+E1T3" 2326 | }, 2327 | { 2328 | "__type__": "cc.Widget", 2329 | "_name": "", 2330 | "_objFlags": 0, 2331 | "node": { 2332 | "__id__": 63 2333 | }, 2334 | "_enabled": true, 2335 | "__prefab": null, 2336 | "_alignFlags": 0, 2337 | "_target": null, 2338 | "_left": 0, 2339 | "_right": 0, 2340 | "_top": 0, 2341 | "_bottom": 0, 2342 | "_horizontalCenter": 0, 2343 | "_verticalCenter": 0, 2344 | "_isAbsLeft": true, 2345 | "_isAbsRight": true, 2346 | "_isAbsTop": true, 2347 | "_isAbsBottom": true, 2348 | "_isAbsHorizontalCenter": true, 2349 | "_isAbsVerticalCenter": true, 2350 | "_originalWidth": 0, 2351 | "_originalHeight": 0, 2352 | "_alignMode": 1, 2353 | "_lockFlags": 0, 2354 | "_id": "42AEOFptxBSY+c/nFFWYCV" 2355 | }, 2356 | { 2357 | "__type__": "cc.Sprite", 2358 | "_name": "", 2359 | "_objFlags": 0, 2360 | "node": { 2361 | "__id__": 63 2362 | }, 2363 | "_enabled": true, 2364 | "__prefab": null, 2365 | "_visFlags": 0, 2366 | "_customMaterial": null, 2367 | "_srcBlendFactor": 2, 2368 | "_dstBlendFactor": 4, 2369 | "_color": { 2370 | "__type__": "cc.Color", 2371 | "r": 255, 2372 | "g": 255, 2373 | "b": 255, 2374 | "a": 255 2375 | }, 2376 | "_spriteFrame": { 2377 | "__uuid__": "c1e757ac-f5bb-46ed-b86a-fdabff7aeb55@f9941", 2378 | "__expectedType__": "cc.SpriteFrame" 2379 | }, 2380 | "_type": 1, 2381 | "_fillType": 0, 2382 | "_sizeMode": 0, 2383 | "_fillCenter": { 2384 | "__type__": "cc.Vec2", 2385 | "x": 0, 2386 | "y": 0 2387 | }, 2388 | "_fillStart": 0, 2389 | "_fillRange": 0, 2390 | "_isTrimmedMode": true, 2391 | "_useGrayscale": false, 2392 | "_atlas": null, 2393 | "_id": "74LLOlhwxKQIacki2rGp2U" 2394 | }, 2395 | { 2396 | "__type__": "cc.Button", 2397 | "_name": "", 2398 | "_objFlags": 0, 2399 | "node": { 2400 | "__id__": 63 2401 | }, 2402 | "_enabled": true, 2403 | "__prefab": null, 2404 | "clickEvents": [ 2405 | { 2406 | "__id__": 70 2407 | } 2408 | ], 2409 | "_interactable": true, 2410 | "_transition": 3, 2411 | "_normalColor": { 2412 | "__type__": "cc.Color", 2413 | "r": 255, 2414 | "g": 255, 2415 | "b": 255, 2416 | "a": 255 2417 | }, 2418 | "_hoverColor": { 2419 | "__type__": "cc.Color", 2420 | "r": 255, 2421 | "g": 255, 2422 | "b": 255, 2423 | "a": 255 2424 | }, 2425 | "_pressedColor": { 2426 | "__type__": "cc.Color", 2427 | "r": 255, 2428 | "g": 255, 2429 | "b": 255, 2430 | "a": 255 2431 | }, 2432 | "_disabledColor": { 2433 | "__type__": "cc.Color", 2434 | "r": 255, 2435 | "g": 255, 2436 | "b": 255, 2437 | "a": 255 2438 | }, 2439 | "_normalSprite": null, 2440 | "_hoverSprite": null, 2441 | "_pressedSprite": null, 2442 | "_disabledSprite": null, 2443 | "_duration": 0.1, 2444 | "_zoomScale": 1.2, 2445 | "_target": { 2446 | "__id__": 63 2447 | }, 2448 | "_id": "54AARku0xCG6zQofqINWOr" 2449 | }, 2450 | { 2451 | "__type__": "cc.ClickEvent", 2452 | "target": { 2453 | "__id__": 5 2454 | }, 2455 | "component": "HotUpdate", 2456 | "_componentId": "", 2457 | "handler": "retry", 2458 | "customEventData": "" 2459 | }, 2460 | { 2461 | "__type__": "cc.UITransform", 2462 | "_name": "", 2463 | "_objFlags": 0, 2464 | "node": { 2465 | "__id__": 63 2466 | }, 2467 | "_enabled": true, 2468 | "__prefab": null, 2469 | "_contentSize": { 2470 | "__type__": "cc.Size", 2471 | "width": 250, 2472 | "height": 100 2473 | }, 2474 | "_anchorPoint": { 2475 | "__type__": "cc.Vec2", 2476 | "x": 0.5, 2477 | "y": 0.5 2478 | }, 2479 | "_id": "fcrxVgRYhKwYiB5CtHvzP0" 2480 | }, 2481 | { 2482 | "__type__": "cc.Node", 2483 | "_name": "filep", 2484 | "_objFlags": 0, 2485 | "_parent": { 2486 | "__id__": 18 2487 | }, 2488 | "_children": [], 2489 | "_active": true, 2490 | "_components": [ 2491 | { 2492 | "__id__": 73 2493 | }, 2494 | { 2495 | "__id__": 74 2496 | } 2497 | ], 2498 | "_prefab": null, 2499 | "_lpos": { 2500 | "__type__": "cc.Vec3", 2501 | "x": 0, 2502 | "y": 94, 2503 | "z": 0 2504 | }, 2505 | "_lrot": { 2506 | "__type__": "cc.Quat", 2507 | "x": 0, 2508 | "y": 0, 2509 | "z": 0, 2510 | "w": 1 2511 | }, 2512 | "_lscale": { 2513 | "__type__": "cc.Vec3", 2514 | "x": 1, 2515 | "y": 1, 2516 | "z": 1 2517 | }, 2518 | "_layer": 524288, 2519 | "_euler": { 2520 | "__type__": "cc.Vec3", 2521 | "x": 0, 2522 | "y": 0, 2523 | "z": 0 2524 | }, 2525 | "_id": "abc5a3cfwxPmpi6OeU/U40S" 2526 | }, 2527 | { 2528 | "__type__": "cc.Label", 2529 | "_name": "", 2530 | "_objFlags": 0, 2531 | "node": { 2532 | "__id__": 72 2533 | }, 2534 | "_enabled": true, 2535 | "__prefab": null, 2536 | "_visFlags": 0, 2537 | "_customMaterial": null, 2538 | "_srcBlendFactor": 2, 2539 | "_dstBlendFactor": 4, 2540 | "_color": { 2541 | "__type__": "cc.Color", 2542 | "r": 255, 2543 | "g": 255, 2544 | "b": 255, 2545 | "a": 255 2546 | }, 2547 | "_string": "/", 2548 | "_horizontalAlign": 1, 2549 | "_verticalAlign": 1, 2550 | "_actualFontSize": 40, 2551 | "_fontSize": 40, 2552 | "_fontFamily": "Arial", 2553 | "_lineHeight": 40, 2554 | "_overflow": 1, 2555 | "_enableWrapText": true, 2556 | "_font": null, 2557 | "_isSystemFontUsed": true, 2558 | "_isItalic": false, 2559 | "_isBold": false, 2560 | "_isUnderline": false, 2561 | "_underlineHeight": 0, 2562 | "_cacheMode": 0, 2563 | "_id": "cbspV5loBAP6sqbAGSfFdo" 2564 | }, 2565 | { 2566 | "__type__": "cc.UITransform", 2567 | "_name": "", 2568 | "_objFlags": 0, 2569 | "node": { 2570 | "__id__": 72 2571 | }, 2572 | "_enabled": true, 2573 | "__prefab": null, 2574 | "_contentSize": { 2575 | "__type__": "cc.Size", 2576 | "width": 150, 2577 | "height": 40 2578 | }, 2579 | "_anchorPoint": { 2580 | "__type__": "cc.Vec2", 2581 | "x": 0.5, 2582 | "y": 0.5 2583 | }, 2584 | "_id": "b1qFWDovpBd5iM3nM2ZWwx" 2585 | }, 2586 | { 2587 | "__type__": "cc.Node", 2588 | "_name": "bytep", 2589 | "_objFlags": 0, 2590 | "_parent": { 2591 | "__id__": 18 2592 | }, 2593 | "_children": [], 2594 | "_active": true, 2595 | "_components": [ 2596 | { 2597 | "__id__": 76 2598 | }, 2599 | { 2600 | "__id__": 77 2601 | } 2602 | ], 2603 | "_prefab": null, 2604 | "_lpos": { 2605 | "__type__": "cc.Vec3", 2606 | "x": 0, 2607 | "y": -20, 2608 | "z": 0 2609 | }, 2610 | "_lrot": { 2611 | "__type__": "cc.Quat", 2612 | "x": 0, 2613 | "y": 0, 2614 | "z": 0, 2615 | "w": 1 2616 | }, 2617 | "_lscale": { 2618 | "__type__": "cc.Vec3", 2619 | "x": 1, 2620 | "y": 1, 2621 | "z": 1 2622 | }, 2623 | "_layer": 524288, 2624 | "_euler": { 2625 | "__type__": "cc.Vec3", 2626 | "x": 0, 2627 | "y": 0, 2628 | "z": 0 2629 | }, 2630 | "_id": "047348dwX5DBZE1CFL/1t4b" 2631 | }, 2632 | { 2633 | "__type__": "cc.Label", 2634 | "_name": "", 2635 | "_objFlags": 0, 2636 | "node": { 2637 | "__id__": 75 2638 | }, 2639 | "_enabled": true, 2640 | "__prefab": null, 2641 | "_visFlags": 0, 2642 | "_customMaterial": null, 2643 | "_srcBlendFactor": 2, 2644 | "_dstBlendFactor": 4, 2645 | "_color": { 2646 | "__type__": "cc.Color", 2647 | "r": 255, 2648 | "g": 255, 2649 | "b": 255, 2650 | "a": 255 2651 | }, 2652 | "_string": "/", 2653 | "_horizontalAlign": 1, 2654 | "_verticalAlign": 1, 2655 | "_actualFontSize": 28, 2656 | "_fontSize": 28, 2657 | "_fontFamily": "Arial", 2658 | "_lineHeight": 40, 2659 | "_overflow": 1, 2660 | "_enableWrapText": true, 2661 | "_font": null, 2662 | "_isSystemFontUsed": true, 2663 | "_isItalic": false, 2664 | "_isBold": false, 2665 | "_isUnderline": false, 2666 | "_underlineHeight": 0, 2667 | "_cacheMode": 0, 2668 | "_id": "9ajr6No2FIAo0Sgt1EHIA/" 2669 | }, 2670 | { 2671 | "__type__": "cc.UITransform", 2672 | "_name": "", 2673 | "_objFlags": 0, 2674 | "node": { 2675 | "__id__": 75 2676 | }, 2677 | "_enabled": true, 2678 | "__prefab": null, 2679 | "_contentSize": { 2680 | "__type__": "cc.Size", 2681 | "width": 300, 2682 | "height": 40 2683 | }, 2684 | "_anchorPoint": { 2685 | "__type__": "cc.Vec2", 2686 | "x": 0.5, 2687 | "y": 0.5 2688 | }, 2689 | "_id": "5ewP1bE1tBarZsNjSWHEnx" 2690 | }, 2691 | { 2692 | "__type__": "cc.Node", 2693 | "_name": "update_btn", 2694 | "_objFlags": 0, 2695 | "_parent": { 2696 | "__id__": 18 2697 | }, 2698 | "_children": [ 2699 | { 2700 | "__id__": 79 2701 | } 2702 | ], 2703 | "_active": true, 2704 | "_components": [ 2705 | { 2706 | "__id__": 82 2707 | }, 2708 | { 2709 | "__id__": 83 2710 | }, 2711 | { 2712 | "__id__": 84 2713 | }, 2714 | { 2715 | "__id__": 86 2716 | } 2717 | ], 2718 | "_prefab": null, 2719 | "_lpos": { 2720 | "__type__": "cc.Vec3", 2721 | "x": 260, 2722 | "y": 266, 2723 | "z": 0 2724 | }, 2725 | "_lrot": { 2726 | "__type__": "cc.Quat", 2727 | "x": 0, 2728 | "y": 0, 2729 | "z": 0, 2730 | "w": 1 2731 | }, 2732 | "_lscale": { 2733 | "__type__": "cc.Vec3", 2734 | "x": 1, 2735 | "y": 1, 2736 | "z": 1 2737 | }, 2738 | "_layer": 524288, 2739 | "_euler": { 2740 | "__type__": "cc.Vec3", 2741 | "x": 0, 2742 | "y": 0, 2743 | "z": 0 2744 | }, 2745 | "_id": "a3011+HK3pEWJaqNYRVYnjk" 2746 | }, 2747 | { 2748 | "__type__": "cc.Node", 2749 | "_name": "Label", 2750 | "_objFlags": 0, 2751 | "_parent": { 2752 | "__id__": 78 2753 | }, 2754 | "_children": [], 2755 | "_active": true, 2756 | "_components": [ 2757 | { 2758 | "__id__": 80 2759 | }, 2760 | { 2761 | "__id__": 81 2762 | } 2763 | ], 2764 | "_prefab": null, 2765 | "_lpos": { 2766 | "__type__": "cc.Vec3", 2767 | "x": 0, 2768 | "y": 4, 2769 | "z": 0 2770 | }, 2771 | "_lrot": { 2772 | "__type__": "cc.Quat", 2773 | "x": 0, 2774 | "y": 0, 2775 | "z": 0, 2776 | "w": 1 2777 | }, 2778 | "_lscale": { 2779 | "__type__": "cc.Vec3", 2780 | "x": 1, 2781 | "y": 1, 2782 | "z": 1 2783 | }, 2784 | "_layer": 524288, 2785 | "_euler": { 2786 | "__type__": "cc.Vec3", 2787 | "x": 0, 2788 | "y": 0, 2789 | "z": 0 2790 | }, 2791 | "_id": "057e3QEtlZAvod0jQw4N7Ub" 2792 | }, 2793 | { 2794 | "__type__": "cc.Label", 2795 | "_name": "", 2796 | "_objFlags": 0, 2797 | "node": { 2798 | "__id__": 79 2799 | }, 2800 | "_enabled": true, 2801 | "__prefab": null, 2802 | "_visFlags": 0, 2803 | "_customMaterial": null, 2804 | "_srcBlendFactor": 2, 2805 | "_dstBlendFactor": 4, 2806 | "_color": { 2807 | "__type__": "cc.Color", 2808 | "r": 0, 2809 | "g": 0, 2810 | "b": 0, 2811 | "a": 255 2812 | }, 2813 | "_string": "使用自定义配置", 2814 | "_horizontalAlign": 1, 2815 | "_verticalAlign": 1, 2816 | "_actualFontSize": 20, 2817 | "_fontSize": 20, 2818 | "_fontFamily": "Arial", 2819 | "_lineHeight": 40, 2820 | "_overflow": 0, 2821 | "_enableWrapText": true, 2822 | "_font": null, 2823 | "_isSystemFontUsed": true, 2824 | "_isItalic": false, 2825 | "_isBold": false, 2826 | "_isUnderline": false, 2827 | "_underlineHeight": 0, 2828 | "_cacheMode": 0, 2829 | "_id": "e7mPy9YUtArLjtIfWBr3Ca" 2830 | }, 2831 | { 2832 | "__type__": "cc.UITransform", 2833 | "_name": "", 2834 | "_objFlags": 0, 2835 | "node": { 2836 | "__id__": 79 2837 | }, 2838 | "_enabled": true, 2839 | "__prefab": null, 2840 | "_contentSize": { 2841 | "__type__": "cc.Size", 2842 | "width": 140, 2843 | "height": 50.4 2844 | }, 2845 | "_anchorPoint": { 2846 | "__type__": "cc.Vec2", 2847 | "x": 0.5, 2848 | "y": 0.5 2849 | }, 2850 | "_id": "70OS4UmCpNvavytyVzTys+" 2851 | }, 2852 | { 2853 | "__type__": "cc.Widget", 2854 | "_name": "", 2855 | "_objFlags": 0, 2856 | "node": { 2857 | "__id__": 78 2858 | }, 2859 | "_enabled": true, 2860 | "__prefab": null, 2861 | "_alignFlags": 0, 2862 | "_target": null, 2863 | "_left": 0, 2864 | "_right": 0, 2865 | "_top": 0, 2866 | "_bottom": 0, 2867 | "_horizontalCenter": 0, 2868 | "_verticalCenter": 0, 2869 | "_isAbsLeft": true, 2870 | "_isAbsRight": true, 2871 | "_isAbsTop": true, 2872 | "_isAbsBottom": true, 2873 | "_isAbsHorizontalCenter": true, 2874 | "_isAbsVerticalCenter": true, 2875 | "_originalWidth": 0, 2876 | "_originalHeight": 0, 2877 | "_alignMode": 0, 2878 | "_lockFlags": 0, 2879 | "_id": "1aLUVp3ydDQa+hSw7k/GCq" 2880 | }, 2881 | { 2882 | "__type__": "cc.Sprite", 2883 | "_name": "", 2884 | "_objFlags": 0, 2885 | "node": { 2886 | "__id__": 78 2887 | }, 2888 | "_enabled": true, 2889 | "__prefab": null, 2890 | "_visFlags": 0, 2891 | "_customMaterial": null, 2892 | "_srcBlendFactor": 2, 2893 | "_dstBlendFactor": 4, 2894 | "_color": { 2895 | "__type__": "cc.Color", 2896 | "r": 255, 2897 | "g": 255, 2898 | "b": 255, 2899 | "a": 255 2900 | }, 2901 | "_spriteFrame": { 2902 | "__uuid__": "c1e757ac-f5bb-46ed-b86a-fdabff7aeb55@f9941", 2903 | "__expectedType__": "cc.SpriteFrame" 2904 | }, 2905 | "_type": 1, 2906 | "_fillType": 0, 2907 | "_sizeMode": 0, 2908 | "_fillCenter": { 2909 | "__type__": "cc.Vec2", 2910 | "x": 0, 2911 | "y": 0 2912 | }, 2913 | "_fillStart": 0, 2914 | "_fillRange": 0, 2915 | "_isTrimmedMode": true, 2916 | "_useGrayscale": false, 2917 | "_atlas": null, 2918 | "_id": "5cA7Gj6D9Cj6fDOCMXDnoz" 2919 | }, 2920 | { 2921 | "__type__": "cc.Button", 2922 | "_name": "", 2923 | "_objFlags": 0, 2924 | "node": { 2925 | "__id__": 78 2926 | }, 2927 | "_enabled": true, 2928 | "__prefab": null, 2929 | "clickEvents": [ 2930 | { 2931 | "__id__": 85 2932 | } 2933 | ], 2934 | "_interactable": true, 2935 | "_transition": 3, 2936 | "_normalColor": { 2937 | "__type__": "cc.Color", 2938 | "r": 255, 2939 | "g": 255, 2940 | "b": 255, 2941 | "a": 255 2942 | }, 2943 | "_hoverColor": { 2944 | "__type__": "cc.Color", 2945 | "r": 255, 2946 | "g": 255, 2947 | "b": 255, 2948 | "a": 255 2949 | }, 2950 | "_pressedColor": { 2951 | "__type__": "cc.Color", 2952 | "r": 255, 2953 | "g": 255, 2954 | "b": 255, 2955 | "a": 255 2956 | }, 2957 | "_disabledColor": { 2958 | "__type__": "cc.Color", 2959 | "r": 255, 2960 | "g": 255, 2961 | "b": 255, 2962 | "a": 255 2963 | }, 2964 | "_normalSprite": { 2965 | "__uuid__": "c1e757ac-f5bb-46ed-b86a-fdabff7aeb55@f9941", 2966 | "__expectedType__": "cc.SpriteFrame" 2967 | }, 2968 | "_hoverSprite": null, 2969 | "_pressedSprite": null, 2970 | "_disabledSprite": null, 2971 | "_duration": 0.1, 2972 | "_zoomScale": 1.2, 2973 | "_target": { 2974 | "__id__": 78 2975 | }, 2976 | "_id": "72AqCkPOJCyJb0nsc9qacw" 2977 | }, 2978 | { 2979 | "__type__": "cc.ClickEvent", 2980 | "target": { 2981 | "__id__": 5 2982 | }, 2983 | "component": "HotUpdate", 2984 | "_componentId": "", 2985 | "handler": "loadCustomManifest", 2986 | "customEventData": "" 2987 | }, 2988 | { 2989 | "__type__": "cc.UITransform", 2990 | "_name": "", 2991 | "_objFlags": 0, 2992 | "node": { 2993 | "__id__": 78 2994 | }, 2995 | "_enabled": true, 2996 | "__prefab": null, 2997 | "_contentSize": { 2998 | "__type__": "cc.Size", 2999 | "width": 200, 3000 | "height": 60 3001 | }, 3002 | "_anchorPoint": { 3003 | "__type__": "cc.Vec2", 3004 | "x": 0.5, 3005 | "y": 0.5 3006 | }, 3007 | "_id": "01sDImbdBN1IJ/F13+8dG8" 3008 | }, 3009 | { 3010 | "__type__": "cc.Sprite", 3011 | "_name": "", 3012 | "_objFlags": 0, 3013 | "node": { 3014 | "__id__": 18 3015 | }, 3016 | "_enabled": true, 3017 | "__prefab": null, 3018 | "_visFlags": 0, 3019 | "_customMaterial": null, 3020 | "_srcBlendFactor": 2, 3021 | "_dstBlendFactor": 4, 3022 | "_color": { 3023 | "__type__": "cc.Color", 3024 | "r": 255, 3025 | "g": 255, 3026 | "b": 255, 3027 | "a": 255 3028 | }, 3029 | "_spriteFrame": { 3030 | "__uuid__": "700faa17-11a6-46cd-aeb5-d6900bc264f8@f9941", 3031 | "__expectedType__": "cc.SpriteFrame" 3032 | }, 3033 | "_type": 1, 3034 | "_fillType": 0, 3035 | "_sizeMode": 0, 3036 | "_fillCenter": { 3037 | "__type__": "cc.Vec2", 3038 | "x": 0, 3039 | "y": 0 3040 | }, 3041 | "_fillStart": 0, 3042 | "_fillRange": 0, 3043 | "_isTrimmedMode": true, 3044 | "_useGrayscale": false, 3045 | "_atlas": null, 3046 | "_id": "42UAEkv95DnpSewO7r59n0" 3047 | }, 3048 | { 3049 | "__type__": "cc.UITransform", 3050 | "_name": "", 3051 | "_objFlags": 0, 3052 | "node": { 3053 | "__id__": 18 3054 | }, 3055 | "_enabled": true, 3056 | "__prefab": null, 3057 | "_contentSize": { 3058 | "__type__": "cc.Size", 3059 | "width": 800, 3060 | "height": 600 3061 | }, 3062 | "_anchorPoint": { 3063 | "__type__": "cc.Vec2", 3064 | "x": 0.5, 3065 | "y": 0.5 3066 | }, 3067 | "_id": "2bDFlmJd1K8ZdHpI5M26cK" 3068 | }, 3069 | { 3070 | "__type__": "d896fFhBk9A57gLMvEj3KZ7", 3071 | "_name": "", 3072 | "_objFlags": 0, 3073 | "node": { 3074 | "__id__": 18 3075 | }, 3076 | "_enabled": true, 3077 | "__prefab": null, 3078 | "info": { 3079 | "__id__": 43 3080 | }, 3081 | "fileProgress": { 3082 | "__id__": 30 3083 | }, 3084 | "fileLabel": { 3085 | "__id__": 23 3086 | }, 3087 | "byteProgress": { 3088 | "__id__": 40 3089 | }, 3090 | "byteLabel": { 3091 | "__id__": 33 3092 | }, 3093 | "close": null, 3094 | "checkBtn": { 3095 | "__id__": 45 3096 | }, 3097 | "retryBtn": { 3098 | "__id__": 54 3099 | }, 3100 | "updateBtn": { 3101 | "__id__": 63 3102 | }, 3103 | "_id": "47r+4sp7RNEa1RUnz4P2xp" 3104 | }, 3105 | { 3106 | "__type__": "cc.Widget", 3107 | "_name": "", 3108 | "_objFlags": 0, 3109 | "node": { 3110 | "__id__": 13 3111 | }, 3112 | "_enabled": true, 3113 | "__prefab": null, 3114 | "_alignFlags": 45, 3115 | "_target": null, 3116 | "_left": 0, 3117 | "_right": 0, 3118 | "_top": 0, 3119 | "_bottom": 0, 3120 | "_horizontalCenter": 0, 3121 | "_verticalCenter": 0, 3122 | "_isAbsLeft": true, 3123 | "_isAbsRight": true, 3124 | "_isAbsTop": true, 3125 | "_isAbsBottom": true, 3126 | "_isAbsHorizontalCenter": true, 3127 | "_isAbsVerticalCenter": true, 3128 | "_originalWidth": 0, 3129 | "_originalHeight": 0, 3130 | "_alignMode": 0, 3131 | "_lockFlags": 0, 3132 | "_id": "32Ns9SKIREZIkoGfbHiWfx" 3133 | }, 3134 | { 3135 | "__type__": "cc.UITransform", 3136 | "_name": "", 3137 | "_objFlags": 0, 3138 | "node": { 3139 | "__id__": 13 3140 | }, 3141 | "_enabled": true, 3142 | "__prefab": null, 3143 | "_contentSize": { 3144 | "__type__": "cc.Size", 3145 | "width": 1371.4285714285716, 3146 | "height": 914.2857142857143 3147 | }, 3148 | "_anchorPoint": { 3149 | "__type__": "cc.Vec2", 3150 | "x": 0.5, 3151 | "y": 0.5 3152 | }, 3153 | "_id": "23lrwteY9Kr6mr/3gW5WtX" 3154 | }, 3155 | { 3156 | "__type__": "cc.Node", 3157 | "_name": "UICamera_Canvas", 3158 | "_objFlags": 0, 3159 | "_parent": { 3160 | "__id__": 5 3161 | }, 3162 | "_children": [], 3163 | "_active": true, 3164 | "_components": [ 3165 | { 3166 | "__id__": 93 3167 | } 3168 | ], 3169 | "_prefab": null, 3170 | "_lpos": { 3171 | "__type__": "cc.Vec3", 3172 | "x": 0, 3173 | "y": 0, 3174 | "z": 1000 3175 | }, 3176 | "_lrot": { 3177 | "__type__": "cc.Quat", 3178 | "x": 0, 3179 | "y": 0, 3180 | "z": 0, 3181 | "w": 1 3182 | }, 3183 | "_lscale": { 3184 | "__type__": "cc.Vec3", 3185 | "x": 1, 3186 | "y": 1, 3187 | "z": 1 3188 | }, 3189 | "_layer": 1073741824, 3190 | "_euler": { 3191 | "__type__": "cc.Vec3", 3192 | "x": 0, 3193 | "y": 0, 3194 | "z": 0 3195 | }, 3196 | "_id": "ecMi3vPGdGOa2xo5J/sm5f" 3197 | }, 3198 | { 3199 | "__type__": "cc.Camera", 3200 | "_name": "", 3201 | "_objFlags": 0, 3202 | "node": { 3203 | "__id__": 92 3204 | }, 3205 | "_enabled": true, 3206 | "__prefab": null, 3207 | "_projection": 0, 3208 | "_priority": 1073741824, 3209 | "_fov": 45, 3210 | "_fovAxis": 0, 3211 | "_orthoHeight": 320, 3212 | "_near": 1, 3213 | "_far": 2000, 3214 | "_color": { 3215 | "__type__": "cc.Color", 3216 | "r": 0, 3217 | "g": 0, 3218 | "b": 0, 3219 | "a": 0 3220 | }, 3221 | "_depth": 1, 3222 | "_stencil": 0, 3223 | "_clearFlags": 6, 3224 | "_rect": { 3225 | "__type__": "cc.Rect", 3226 | "x": 0, 3227 | "y": 0, 3228 | "width": 1, 3229 | "height": 1 3230 | }, 3231 | "_aperture": 19, 3232 | "_shutter": 7, 3233 | "_iso": 0, 3234 | "_screenScale": 1, 3235 | "_visibility": 42467328, 3236 | "_targetTexture": null, 3237 | "_id": "1ejrFbofJEH6SNnV5o4JOX" 3238 | }, 3239 | { 3240 | "__type__": "cc.Canvas", 3241 | "_name": "", 3242 | "_objFlags": 0, 3243 | "node": { 3244 | "__id__": 5 3245 | }, 3246 | "_enabled": true, 3247 | "__prefab": null, 3248 | "_cameraComponent": { 3249 | "__id__": 93 3250 | }, 3251 | "_alignCanvasWithScreen": true, 3252 | "_id": "52yOxbnSBAALA3al5RKi0M" 3253 | }, 3254 | { 3255 | "__type__": "cc.Widget", 3256 | "_name": "", 3257 | "_objFlags": 0, 3258 | "node": { 3259 | "__id__": 5 3260 | }, 3261 | "_enabled": true, 3262 | "__prefab": null, 3263 | "_alignFlags": 45, 3264 | "_target": null, 3265 | "_left": 0, 3266 | "_right": 0, 3267 | "_top": 0, 3268 | "_bottom": 0, 3269 | "_horizontalCenter": 0, 3270 | "_verticalCenter": 0, 3271 | "_isAbsLeft": true, 3272 | "_isAbsRight": true, 3273 | "_isAbsTop": true, 3274 | "_isAbsBottom": true, 3275 | "_isAbsHorizontalCenter": true, 3276 | "_isAbsVerticalCenter": true, 3277 | "_originalWidth": 0, 3278 | "_originalHeight": 0, 3279 | "_alignMode": 1, 3280 | "_lockFlags": 0, 3281 | "_id": "b7UIfXRkhCf5y/FhCD5UH6" 3282 | }, 3283 | { 3284 | "__type__": "cc.UITransform", 3285 | "_name": "", 3286 | "_objFlags": 0, 3287 | "node": { 3288 | "__id__": 5 3289 | }, 3290 | "_enabled": true, 3291 | "__prefab": null, 3292 | "_contentSize": { 3293 | "__type__": "cc.Size", 3294 | "width": 960, 3295 | "height": 640 3296 | }, 3297 | "_anchorPoint": { 3298 | "__type__": "cc.Vec2", 3299 | "x": 0.5, 3300 | "y": 0.5 3301 | }, 3302 | "_id": "0ffzTNuqRJZZgGb1jVQGAr" 3303 | }, 3304 | { 3305 | "__type__": "8ee7ate7OVDEph2ruFCYLQZ", 3306 | "_name": "", 3307 | "_objFlags": 0, 3308 | "node": { 3309 | "__id__": 5 3310 | }, 3311 | "_enabled": true, 3312 | "__prefab": null, 3313 | "panel": { 3314 | "__id__": 89 3315 | }, 3316 | "manifestUrl": { 3317 | "__uuid__": "800f94fd-7424-4202-9629-d3ca77f3b72d", 3318 | "__expectedType__": "cc.Asset" 3319 | }, 3320 | "updateUI": { 3321 | "__id__": 13 3322 | }, 3323 | "_id": "6cnjnsxT1PhpmWn6Q9EXsS" 3324 | }, 3325 | { 3326 | "__type__": "cc.SceneGlobals", 3327 | "ambient": { 3328 | "__id__": 99 3329 | }, 3330 | "shadows": { 3331 | "__id__": 100 3332 | }, 3333 | "_skybox": { 3334 | "__id__": 101 3335 | }, 3336 | "fog": { 3337 | "__id__": 102 3338 | } 3339 | }, 3340 | { 3341 | "__type__": "cc.AmbientInfo", 3342 | "_skyColor": { 3343 | "__type__": "cc.Color", 3344 | "r": 51, 3345 | "g": 128, 3346 | "b": 204, 3347 | "a": 1 3348 | }, 3349 | "_skyIllum": 20000, 3350 | "_groundAlbedo": { 3351 | "__type__": "cc.Color", 3352 | "r": 51, 3353 | "g": 51, 3354 | "b": 51, 3355 | "a": 255 3356 | } 3357 | }, 3358 | { 3359 | "__type__": "cc.ShadowsInfo", 3360 | "_type": 0, 3361 | "_enabled": false, 3362 | "_normal": { 3363 | "__type__": "cc.Vec3", 3364 | "x": 0, 3365 | "y": 1, 3366 | "z": 0 3367 | }, 3368 | "_distance": 0, 3369 | "_shadowColor": { 3370 | "__type__": "cc.Color", 3371 | "r": 0, 3372 | "g": 0, 3373 | "b": 0, 3374 | "a": 76 3375 | }, 3376 | "_fixedArea": false, 3377 | "_pcf": 0, 3378 | "_bias": 1, 3379 | "_normalBias": 0, 3380 | "_near": 1, 3381 | "_far": 30, 3382 | "_shadowDistance": 100, 3383 | "_invisibleOcclusionRange": 200, 3384 | "_orthoSize": 5, 3385 | "_maxReceived": 4, 3386 | "_size": { 3387 | "__type__": "cc.Vec2", 3388 | "x": 512, 3389 | "y": 512 3390 | }, 3391 | "_saturation": 0.2980392156862745 3392 | }, 3393 | { 3394 | "__type__": "cc.SkyboxInfo", 3395 | "_envmap": null, 3396 | "_isRGBE": false, 3397 | "_enabled": false, 3398 | "_useIBL": false 3399 | }, 3400 | { 3401 | "__type__": "cc.FogInfo", 3402 | "_type": 0, 3403 | "_fogColor": { 3404 | "__type__": "cc.Color", 3405 | "r": 200, 3406 | "g": 200, 3407 | "b": 200, 3408 | "a": 255 3409 | }, 3410 | "_enabled": false, 3411 | "_fogDensity": 0.3, 3412 | "_fogStart": 0.5, 3413 | "_fogEnd": 300, 3414 | "_fogAtten": 5, 3415 | "_fogTop": 1.5, 3416 | "_fogRange": 1.2 3417 | } 3418 | ] -------------------------------------------------------------------------------- /assets/scenes/menu.scene.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.1.32", 3 | "importer": "scene", 4 | "imported": true, 5 | "uuid": "8a546935-70d4-42d2-a051-8d0e76f28008", 6 | "files": [ 7 | ".json" 8 | ], 9 | "subMetas": {}, 10 | "userData": {} 11 | } 12 | -------------------------------------------------------------------------------- /assets/textures.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.1.0", 3 | "importer": "directory", 4 | "imported": true, 5 | "uuid": "a7027343-5d44-4c36-a41b-5e1771cd07cd", 6 | "files": [], 7 | "subMetas": {}, 8 | "userData": { 9 | "compressionType": {}, 10 | "isRemoteBundle": {} 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /assets/textures/UI.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.1.0", 3 | "importer": "directory", 4 | "imported": true, 5 | "uuid": "4b4b6d44-2ff9-434f-aa24-a7a9e57135db", 6 | "files": [], 7 | "subMetas": {}, 8 | "userData": { 9 | "compressionType": {}, 10 | "isRemoteBundle": {} 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /assets/textures/UI/bg_changjing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cocos-creator/cocos-tutorial-hot-update/65e8e5d4f7471846d676f77ad4061ad58ca9f906/assets/textures/UI/bg_changjing.png -------------------------------------------------------------------------------- /assets/textures/UI/bg_changjing.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.21", 3 | "importer": "image", 4 | "imported": true, 5 | "uuid": "ae4e2188-2b7b-42a9-85e1-8fb987600b04", 6 | "files": [ 7 | ".png", 8 | ".json" 9 | ], 10 | "subMetas": { 11 | "bg_changjing": { 12 | "ver": "1.0.4", 13 | "uuid": "a2da79be-fe22-420a-83b5-e37878367b06", 14 | "rawTextureUuid": "ae4e2188-2b7b-42a9-85e1-8fb987600b04", 15 | "trimType": "auto", 16 | "trimThreshold": 1, 17 | "rotated": false, 18 | "offsetX": 0, 19 | "offsetY": 0, 20 | "trimX": 0, 21 | "trimY": 0, 22 | "width": 1334, 23 | "height": 750, 24 | "rawWidth": 1334, 25 | "rawHeight": 750, 26 | "borderTop": 0, 27 | "borderBottom": 0, 28 | "borderLeft": 0, 29 | "borderRight": 0, 30 | "subMetas": {}, 31 | "importer": "*", 32 | "imported": false, 33 | "files": [], 34 | "userData": {}, 35 | "displayName": "", 36 | "id": "", 37 | "name": "" 38 | }, 39 | "6c48a": { 40 | "importer": "texture", 41 | "uuid": "ae4e2188-2b7b-42a9-85e1-8fb987600b04@6c48a", 42 | "displayName": "bg_changjing", 43 | "id": "6c48a", 44 | "name": "texture", 45 | "userData": { 46 | "wrapModeS": "clamp-to-edge", 47 | "wrapModeT": "clamp-to-edge", 48 | "minfilter": "linear", 49 | "magfilter": "linear", 50 | "mipfilter": "none", 51 | "anisotropy": 0, 52 | "isUuid": true, 53 | "imageUuidOrDatabaseUri": "ae4e2188-2b7b-42a9-85e1-8fb987600b04" 54 | }, 55 | "ver": "1.0.21", 56 | "imported": true, 57 | "files": [ 58 | ".json" 59 | ], 60 | "subMetas": {} 61 | }, 62 | "f9941": { 63 | "importer": "sprite-frame", 64 | "uuid": "ae4e2188-2b7b-42a9-85e1-8fb987600b04@f9941", 65 | "displayName": "bg_changjing", 66 | "id": "f9941", 67 | "name": "spriteFrame", 68 | "userData": { 69 | "trimType": "auto", 70 | "trimThreshold": 1, 71 | "rotated": false, 72 | "offsetX": 0, 73 | "offsetY": 0, 74 | "trimX": 0, 75 | "trimY": 0, 76 | "width": 1334, 77 | "height": 750, 78 | "rawWidth": 1334, 79 | "rawHeight": 750, 80 | "borderTop": 0, 81 | "borderBottom": 0, 82 | "borderLeft": 0, 83 | "borderRight": 0, 84 | "isUuid": true, 85 | "imageUuidOrDatabaseUri": "ae4e2188-2b7b-42a9-85e1-8fb987600b04@6c48a", 86 | "atlasUuid": "", 87 | "packable": true 88 | }, 89 | "ver": "1.0.9", 90 | "imported": true, 91 | "files": [ 92 | ".json" 93 | ], 94 | "subMetas": {} 95 | } 96 | }, 97 | "userData": { 98 | "hasAlpha": false, 99 | "type": "sprite-frame", 100 | "redirect": "ae4e2188-2b7b-42a9-85e1-8fb987600b04@f9941" 101 | } 102 | } 103 | -------------------------------------------------------------------------------- /assets/textures/UI/bg_jinbishu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cocos-creator/cocos-tutorial-hot-update/65e8e5d4f7471846d676f77ad4061ad58ca9f906/assets/textures/UI/bg_jinbishu.png -------------------------------------------------------------------------------- /assets/textures/UI/bg_jinbishu.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.21", 3 | "importer": "image", 4 | "imported": true, 5 | "uuid": "edd97988-52a3-4312-8671-90a51bb563ae", 6 | "files": [ 7 | ".png", 8 | ".json" 9 | ], 10 | "subMetas": { 11 | "6c48a": { 12 | "importer": "texture", 13 | "uuid": "edd97988-52a3-4312-8671-90a51bb563ae@6c48a", 14 | "displayName": "bg_jinbishu", 15 | "id": "6c48a", 16 | "name": "texture", 17 | "userData": { 18 | "wrapModeS": "clamp-to-edge", 19 | "wrapModeT": "clamp-to-edge", 20 | "minfilter": "linear", 21 | "magfilter": "linear", 22 | "mipfilter": "none", 23 | "anisotropy": 0, 24 | "isUuid": true, 25 | "imageUuidOrDatabaseUri": "edd97988-52a3-4312-8671-90a51bb563ae" 26 | }, 27 | "ver": "1.0.21", 28 | "imported": true, 29 | "files": [ 30 | ".json" 31 | ], 32 | "subMetas": {} 33 | }, 34 | "f9941": { 35 | "importer": "sprite-frame", 36 | "uuid": "edd97988-52a3-4312-8671-90a51bb563ae@f9941", 37 | "displayName": "bg_jinbishu", 38 | "id": "f9941", 39 | "name": "spriteFrame", 40 | "userData": { 41 | "trimType": "auto", 42 | "trimThreshold": 1, 43 | "rotated": false, 44 | "offsetX": 0, 45 | "offsetY": 0, 46 | "trimX": 0, 47 | "trimY": 0, 48 | "width": 40, 49 | "height": 30, 50 | "rawWidth": 40, 51 | "rawHeight": 30, 52 | "borderTop": 0, 53 | "borderBottom": 0, 54 | "borderLeft": 11, 55 | "borderRight": 12, 56 | "isUuid": true, 57 | "imageUuidOrDatabaseUri": "edd97988-52a3-4312-8671-90a51bb563ae@6c48a", 58 | "atlasUuid": "", 59 | "packable": true 60 | }, 61 | "ver": "1.0.9", 62 | "imported": true, 63 | "files": [ 64 | ".json" 65 | ], 66 | "subMetas": {} 67 | } 68 | }, 69 | "userData": { 70 | "hasAlpha": true, 71 | "type": "sprite-frame", 72 | "redirect": "edd97988-52a3-4312-8671-90a51bb563ae@f9941" 73 | } 74 | } 75 | -------------------------------------------------------------------------------- /assets/textures/UI/bg_rankinglist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cocos-creator/cocos-tutorial-hot-update/65e8e5d4f7471846d676f77ad4061ad58ca9f906/assets/textures/UI/bg_rankinglist.png -------------------------------------------------------------------------------- /assets/textures/UI/bg_rankinglist.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.21", 3 | "importer": "image", 4 | "imported": true, 5 | "uuid": "700faa17-11a6-46cd-aeb5-d6900bc264f8", 6 | "files": [ 7 | ".png", 8 | ".json" 9 | ], 10 | "subMetas": { 11 | "6c48a": { 12 | "importer": "texture", 13 | "uuid": "700faa17-11a6-46cd-aeb5-d6900bc264f8@6c48a", 14 | "displayName": "bg_rankinglist", 15 | "id": "6c48a", 16 | "name": "texture", 17 | "userData": { 18 | "imageUuidOrDatabaseUri": "700faa17-11a6-46cd-aeb5-d6900bc264f8", 19 | "wrapModeS": "clamp-to-edge", 20 | "wrapModeT": "clamp-to-edge", 21 | "minfilter": "linear", 22 | "magfilter": "linear", 23 | "mipfilter": "none", 24 | "anisotropy": 0, 25 | "isUuid": true 26 | }, 27 | "ver": "1.0.21", 28 | "imported": true, 29 | "files": [ 30 | ".json" 31 | ], 32 | "subMetas": {} 33 | }, 34 | "f9941": { 35 | "importer": "sprite-frame", 36 | "uuid": "700faa17-11a6-46cd-aeb5-d6900bc264f8@f9941", 37 | "displayName": "bg_rankinglist", 38 | "id": "f9941", 39 | "name": "spriteFrame", 40 | "userData": { 41 | "trimType": "auto", 42 | "trimThreshold": 1, 43 | "rotated": false, 44 | "offsetX": 0, 45 | "offsetY": 0, 46 | "trimX": 0, 47 | "trimY": 0, 48 | "width": 504, 49 | "height": 144, 50 | "rawWidth": 504, 51 | "rawHeight": 144, 52 | "borderTop": 69, 53 | "borderBottom": 36, 54 | "borderLeft": 36, 55 | "borderRight": 36, 56 | "imageUuidOrDatabaseUri": "700faa17-11a6-46cd-aeb5-d6900bc264f8@6c48a", 57 | "isUuid": true, 58 | "atlasUuid": "", 59 | "packable": true 60 | }, 61 | "ver": "1.0.9", 62 | "imported": true, 63 | "files": [ 64 | ".json" 65 | ], 66 | "subMetas": {} 67 | } 68 | }, 69 | "userData": { 70 | "type": "sprite-frame", 71 | "hasAlpha": true, 72 | "redirect": "700faa17-11a6-46cd-aeb5-d6900bc264f8@f9941" 73 | } 74 | } 75 | -------------------------------------------------------------------------------- /assets/textures/UI/button_orange.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cocos-creator/cocos-tutorial-hot-update/65e8e5d4f7471846d676f77ad4061ad58ca9f906/assets/textures/UI/button_orange.png -------------------------------------------------------------------------------- /assets/textures/UI/button_orange.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.21", 3 | "importer": "image", 4 | "imported": true, 5 | "uuid": "c1e757ac-f5bb-46ed-b86a-fdabff7aeb55", 6 | "files": [ 7 | ".png", 8 | ".json" 9 | ], 10 | "subMetas": { 11 | "6c48a": { 12 | "importer": "texture", 13 | "uuid": "c1e757ac-f5bb-46ed-b86a-fdabff7aeb55@6c48a", 14 | "displayName": "button_orange", 15 | "id": "6c48a", 16 | "name": "texture", 17 | "userData": { 18 | "imageUuidOrDatabaseUri": "c1e757ac-f5bb-46ed-b86a-fdabff7aeb55", 19 | "wrapModeS": "clamp-to-edge", 20 | "wrapModeT": "clamp-to-edge", 21 | "minfilter": "linear", 22 | "magfilter": "linear", 23 | "mipfilter": "none", 24 | "anisotropy": 0, 25 | "isUuid": true 26 | }, 27 | "ver": "1.0.21", 28 | "imported": true, 29 | "files": [ 30 | ".json" 31 | ], 32 | "subMetas": {} 33 | }, 34 | "f9941": { 35 | "importer": "sprite-frame", 36 | "uuid": "c1e757ac-f5bb-46ed-b86a-fdabff7aeb55@f9941", 37 | "displayName": "button_orange", 38 | "id": "f9941", 39 | "name": "spriteFrame", 40 | "userData": { 41 | "trimType": "auto", 42 | "trimThreshold": 1, 43 | "rotated": false, 44 | "offsetX": 0, 45 | "offsetY": 0, 46 | "trimX": 0, 47 | "trimY": 0, 48 | "width": 240, 49 | "height": 95, 50 | "rawWidth": 240, 51 | "rawHeight": 95, 52 | "borderTop": 0, 53 | "borderBottom": 0, 54 | "borderLeft": 0, 55 | "borderRight": 0, 56 | "imageUuidOrDatabaseUri": "c1e757ac-f5bb-46ed-b86a-fdabff7aeb55@6c48a", 57 | "isUuid": true, 58 | "atlasUuid": "", 59 | "packable": true 60 | }, 61 | "ver": "1.0.9", 62 | "imported": true, 63 | "files": [ 64 | ".json" 65 | ], 66 | "subMetas": {} 67 | } 68 | }, 69 | "userData": { 70 | "type": "sprite-frame", 71 | "hasAlpha": true, 72 | "redirect": "c1e757ac-f5bb-46ed-b86a-fdabff7aeb55@f9941" 73 | } 74 | } 75 | -------------------------------------------------------------------------------- /assets/textures/UI/gb_inputbox.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cocos-creator/cocos-tutorial-hot-update/65e8e5d4f7471846d676f77ad4061ad58ca9f906/assets/textures/UI/gb_inputbox.png -------------------------------------------------------------------------------- /assets/textures/UI/gb_inputbox.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.21", 3 | "importer": "image", 4 | "imported": true, 5 | "uuid": "9e71ecbc-8d63-45dd-b0e3-26cefa3d07b1", 6 | "files": [ 7 | ".png", 8 | ".json" 9 | ], 10 | "subMetas": { 11 | "6c48a": { 12 | "importer": "texture", 13 | "uuid": "9e71ecbc-8d63-45dd-b0e3-26cefa3d07b1@6c48a", 14 | "displayName": "gb_inputbox", 15 | "id": "6c48a", 16 | "name": "texture", 17 | "userData": { 18 | "wrapModeS": "clamp-to-edge", 19 | "wrapModeT": "clamp-to-edge", 20 | "minfilter": "linear", 21 | "magfilter": "linear", 22 | "mipfilter": "none", 23 | "anisotropy": 0, 24 | "isUuid": true, 25 | "imageUuidOrDatabaseUri": "9e71ecbc-8d63-45dd-b0e3-26cefa3d07b1" 26 | }, 27 | "ver": "1.0.21", 28 | "imported": true, 29 | "files": [ 30 | ".json" 31 | ], 32 | "subMetas": {} 33 | }, 34 | "f9941": { 35 | "importer": "sprite-frame", 36 | "uuid": "9e71ecbc-8d63-45dd-b0e3-26cefa3d07b1@f9941", 37 | "displayName": "gb_inputbox", 38 | "id": "f9941", 39 | "name": "spriteFrame", 40 | "userData": { 41 | "trimType": "auto", 42 | "trimThreshold": 1, 43 | "rotated": false, 44 | "offsetX": 0, 45 | "offsetY": 0, 46 | "trimX": 0, 47 | "trimY": 0, 48 | "width": 54, 49 | "height": 81, 50 | "rawWidth": 54, 51 | "rawHeight": 81, 52 | "borderTop": 10, 53 | "borderBottom": 10, 54 | "borderLeft": 10, 55 | "borderRight": 10, 56 | "isUuid": true, 57 | "imageUuidOrDatabaseUri": "9e71ecbc-8d63-45dd-b0e3-26cefa3d07b1@6c48a", 58 | "atlasUuid": "", 59 | "packable": true 60 | }, 61 | "ver": "1.0.9", 62 | "imported": true, 63 | "files": [ 64 | ".json" 65 | ], 66 | "subMetas": {} 67 | } 68 | }, 69 | "userData": { 70 | "hasAlpha": true, 71 | "type": "sprite-frame", 72 | "redirect": "9e71ecbc-8d63-45dd-b0e3-26cefa3d07b1@f9941" 73 | } 74 | } 75 | -------------------------------------------------------------------------------- /assets/textures/UI/singleColor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cocos-creator/cocos-tutorial-hot-update/65e8e5d4f7471846d676f77ad4061ad58ca9f906/assets/textures/UI/singleColor.png -------------------------------------------------------------------------------- /assets/textures/UI/singleColor.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.21", 3 | "importer": "image", 4 | "imported": true, 5 | "uuid": "fb40272e-7e52-469d-96da-c6fbce1b7b7e", 6 | "files": [ 7 | ".png", 8 | ".json" 9 | ], 10 | "subMetas": { 11 | "6c48a": { 12 | "importer": "texture", 13 | "uuid": "fb40272e-7e52-469d-96da-c6fbce1b7b7e@6c48a", 14 | "displayName": "singleColor", 15 | "id": "6c48a", 16 | "name": "texture", 17 | "userData": { 18 | "imageUuidOrDatabaseUri": "fb40272e-7e52-469d-96da-c6fbce1b7b7e", 19 | "wrapModeS": "clamp-to-edge", 20 | "wrapModeT": "clamp-to-edge", 21 | "minfilter": "linear", 22 | "magfilter": "linear", 23 | "mipfilter": "none", 24 | "anisotropy": 0, 25 | "isUuid": true 26 | }, 27 | "ver": "1.0.21", 28 | "imported": true, 29 | "files": [ 30 | ".json" 31 | ], 32 | "subMetas": {} 33 | }, 34 | "f9941": { 35 | "importer": "sprite-frame", 36 | "uuid": "fb40272e-7e52-469d-96da-c6fbce1b7b7e@f9941", 37 | "displayName": "singleColor", 38 | "id": "f9941", 39 | "name": "spriteFrame", 40 | "userData": { 41 | "trimType": "auto", 42 | "trimThreshold": 1, 43 | "rotated": false, 44 | "offsetX": 0, 45 | "offsetY": 0, 46 | "trimX": 0, 47 | "trimY": 0, 48 | "width": 10, 49 | "height": 10, 50 | "rawWidth": 10, 51 | "rawHeight": 10, 52 | "borderTop": 0, 53 | "borderBottom": 0, 54 | "borderLeft": 0, 55 | "borderRight": 0, 56 | "imageUuidOrDatabaseUri": "fb40272e-7e52-469d-96da-c6fbce1b7b7e@6c48a", 57 | "isUuid": true, 58 | "atlasUuid": "", 59 | "packable": true 60 | }, 61 | "ver": "1.0.9", 62 | "imported": true, 63 | "files": [ 64 | ".json" 65 | ], 66 | "subMetas": {} 67 | } 68 | }, 69 | "userData": { 70 | "type": "sprite-frame", 71 | "hasAlpha": true, 72 | "redirect": "fb40272e-7e52-469d-96da-c6fbce1b7b7e@f9941" 73 | } 74 | } 75 | -------------------------------------------------------------------------------- /assets/version.manifest: -------------------------------------------------------------------------------- 1 | {"packageUrl":"http://192.168.130.1:7879/","remoteManifestUrl":"http://192.168.130.1:7879/project.manifest","remoteVersionUrl":"http://192.168.130.1:7879/version.manifest","version":"1.0.0"} -------------------------------------------------------------------------------- /assets/version.manifest.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.0", 3 | "importer": "*", 4 | "imported": true, 5 | "uuid": "e53f75f8-ddcd-421e-968d-c85d3ccef940", 6 | "files": [ 7 | ".manifest", 8 | ".json" 9 | ], 10 | "subMetas": {}, 11 | "userData": {} 12 | } 13 | -------------------------------------------------------------------------------- /extensions/hot-update-local-ip/builder/hook.js: -------------------------------------------------------------------------------- 1 | 2 | 'use strict'; 3 | 4 | const os = require("os"); 5 | const fs = require("fs"); 6 | const path = require("path"); 7 | const { exec } = require('child_process'); 8 | 9 | const remote_port = 7879; 10 | 11 | function getIPAdress() { 12 | var interfaces = os.networkInterfaces(); 13 | for (var devName in interfaces) { 14 | var iface = interfaces[devName]; 15 | for (var i = 0; i < iface.length; i++) { 16 | var alias = iface[i]; 17 | if (alias.family === 'IPv4' && alias.address !== '127.0.0.1' && !alias.internal) { 18 | return alias.address; 19 | } 20 | } 21 | } 22 | } 23 | 24 | exports.onAfterBuild = function (options, result) { 25 | let resdir = 'assets'; 26 | 27 | if (fs.existsSync(path.join(result.dest, 'data'))) { 28 | resdir = 'data'; 29 | } 30 | 31 | let cmd = `node version_generator.js -v 1.0.0 -u http://${getIPAdress()}:${remote_port}/ -s ${path.join(result.dest, resdir)} -d ${path.join(Editor.Project.path, "assets")}` 32 | console.warn(cmd); 33 | 34 | exec(cmd, { cwd: Editor.Project.path }, (err, stdout, stderr) => { 35 | if (!err) return; 36 | console.error(err); 37 | }); 38 | } 39 | -------------------------------------------------------------------------------- /extensions/hot-update-local-ip/builder/index.js: -------------------------------------------------------------------------------- 1 | exports.configs = { 2 | '*': { 3 | hooks: './builder/hook.js' 4 | }, 5 | }; 6 | 7 | -------------------------------------------------------------------------------- /extensions/hot-update-local-ip/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "hot-update-local-ip", 3 | "version": "0.0.2", 4 | "package_version": 2, 5 | "description": "用于热更新插件 -本地测试 (3.0.0)", 6 | "contributions": { 7 | "builder": "./builder" 8 | } 9 | } -------------------------------------------------------------------------------- /extensions/hot-update/builder/hook.js: -------------------------------------------------------------------------------- 1 | 2 | 'use strict'; 3 | 4 | var Fs = require("fs"); 5 | var Path = require("path"); 6 | 7 | var inject_script = ` 8 | (function () { 9 | if (typeof window.jsb === 'object') { 10 | var hotUpdateSearchPaths = localStorage.getItem('HotUpdateSearchPaths'); 11 | if (hotUpdateSearchPaths) { 12 | var paths = JSON.parse(hotUpdateSearchPaths); 13 | jsb.fileUtils.setSearchPaths(paths); 14 | 15 | var fileList = []; 16 | var storagePath = paths[0] || ''; 17 | var tempPath = storagePath + '_temp/'; 18 | var baseOffset = tempPath.length; 19 | 20 | if (jsb.fileUtils.isDirectoryExist(tempPath) && !jsb.fileUtils.isFileExist(tempPath + 'project.manifest.temp')) { 21 | jsb.fileUtils.listFilesRecursively(tempPath, fileList); 22 | fileList.forEach(srcPath => { 23 | var relativePath = srcPath.substr(baseOffset); 24 | var dstPath = storagePath + relativePath; 25 | 26 | if (srcPath[srcPath.length] == '/') { 27 | jsb.fileUtils.createDirectory(dstPath) 28 | } 29 | else { 30 | if (jsb.fileUtils.isFileExist(dstPath)) { 31 | jsb.fileUtils.removeFile(dstPath) 32 | } 33 | jsb.fileUtils.renameFile(srcPath, dstPath); 34 | } 35 | }) 36 | jsb.fileUtils.removeDirectory(tempPath); 37 | } 38 | } 39 | } 40 | })(); 41 | `; 42 | 43 | exports.onAfterBuild = function (options, result) { 44 | var url = Path.join(result.dest, 'data', 'main.js'); 45 | 46 | if (!Fs.existsSync(url)) { 47 | url = Path.join(result.dest, 'assets', 'main.js'); 48 | } 49 | 50 | Fs.readFile(url, "utf8", function (err, data) { 51 | if (err) { 52 | throw err; 53 | } 54 | 55 | var newStr = inject_script + data; 56 | Fs.writeFile(url, newStr, function (error) { 57 | if (err) { 58 | throw err; 59 | } 60 | console.warn("SearchPath updated in built main.js for hot update"); 61 | }); 62 | }); 63 | } 64 | -------------------------------------------------------------------------------- /extensions/hot-update/builder/index.js: -------------------------------------------------------------------------------- 1 | exports.configs = { 2 | '*': { 3 | hooks: './builder/hook.js' 4 | }, 5 | }; 6 | 7 | -------------------------------------------------------------------------------- /extensions/hot-update/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "hot-update", 3 | "version": "0.0.2", 4 | "package_version": 2, 5 | "description": "用于热更新插件 (3.0.0)", 6 | "contributions": { 7 | "builder": "./builder" 8 | } 9 | } -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "NewProject", 3 | "type": "3d", 4 | "uuid": "086c4b01-a387-4a92-a07c-39240d62d4a2", 5 | "version": "3.3.2", 6 | "creator": { 7 | "version": "3.3.2" 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /settings/v2/packages/builder.json: -------------------------------------------------------------------------------- 1 | { 2 | "__version__": "1.2.9" 3 | } 4 | -------------------------------------------------------------------------------- /settings/v2/packages/cocos-service.json: -------------------------------------------------------------------------------- 1 | { 2 | "game": { 3 | "name": "UNKNOW GAME", 4 | "app_id": "UNKNOW", 5 | "c_id": "0" 6 | }, 7 | "appConfigMaps": [ 8 | { 9 | "app_id": "UNKNOW", 10 | "config_id": "e20f89" 11 | } 12 | ], 13 | "configs": [ 14 | { 15 | "app_id": "UNKNOW", 16 | "config_id": "e20f89", 17 | "config_name": "Default", 18 | "config_remarks": "", 19 | "services": [] 20 | } 21 | ] 22 | } 23 | -------------------------------------------------------------------------------- /settings/v2/packages/device.json: -------------------------------------------------------------------------------- 1 | { 2 | "__version__": "1.0.1" 3 | } 4 | -------------------------------------------------------------------------------- /settings/v2/packages/engine.json: -------------------------------------------------------------------------------- 1 | { 2 | "__version__": "1.0.5", 3 | "modules": { 4 | "cache": {}, 5 | "includeModules": [ 6 | "base", 7 | "gfx-webgl", 8 | "gfx-webgl2", 9 | "3d", 10 | "2d", 11 | "ui", 12 | "particle", 13 | "physics-ammo", 14 | "physics-2d-box2d", 15 | "intersection-2d", 16 | "primitive", 17 | "profiler", 18 | "particle-2d", 19 | "audio", 20 | "video", 21 | "webview", 22 | "tween", 23 | "terrain", 24 | "tiled-map", 25 | "spine", 26 | "dragon-bones" 27 | ] 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /settings/v2/packages/program.json: -------------------------------------------------------------------------------- 1 | { 2 | "__version__": "1.0.0" 3 | } 4 | -------------------------------------------------------------------------------- /settings/v2/packages/project.json: -------------------------------------------------------------------------------- 1 | { 2 | "__version__": "1.0.1", 3 | "layer": [ 4 | { 5 | "name": "canvas_19", 6 | "value": 524288 7 | } 8 | ] 9 | } 10 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | /* Base configuration. Do not edit this field. */ 3 | "extends": "./temp/tsconfig.cocos.json" 4 | 5 | /* Add your custom configuration here. */ 6 | } 7 | -------------------------------------------------------------------------------- /version_generator.js: -------------------------------------------------------------------------------- 1 | var fs = require('fs'); 2 | var path = require('path'); 3 | var crypto = require('crypto'); 4 | 5 | var manifest = { 6 | packageUrl: 'http://localhost/tutorial-hot-update/remote-assets/', 7 | remoteManifestUrl: 'http://localhost/tutorial-hot-update/remote-assets/project.manifest', 8 | remoteVersionUrl: 'http://localhost/tutorial-hot-update/remote-assets/version.manifest', 9 | version: '1.0.0', 10 | assets: {}, 11 | searchPaths: [] 12 | }; 13 | 14 | var dest = './remote-assets/'; 15 | var src = './jsb/'; 16 | 17 | // Parse arguments 18 | var i = 2; 19 | while (i < process.argv.length) { 20 | var arg = process.argv[i]; 21 | 22 | switch (arg) { 23 | case '--url': 24 | case '-u': 25 | var url = process.argv[i + 1]; 26 | manifest.packageUrl = url; 27 | manifest.remoteManifestUrl = url + 'project.manifest'; 28 | manifest.remoteVersionUrl = url + 'version.manifest'; 29 | i += 2; 30 | break; 31 | case '--version': 32 | case '-v': 33 | manifest.version = process.argv[i + 1]; 34 | i += 2; 35 | break; 36 | case '--src': 37 | case '-s': 38 | src = process.argv[i + 1]; 39 | i += 2; 40 | break; 41 | case '--dest': 42 | case '-d': 43 | dest = process.argv[i + 1]; 44 | i += 2; 45 | break; 46 | default: 47 | i++; 48 | break; 49 | } 50 | } 51 | 52 | 53 | function readDir(dir, obj) { 54 | try { 55 | var stat = fs.statSync(dir); 56 | if (!stat.isDirectory()) { 57 | return; 58 | } 59 | var subpaths = fs.readdirSync(dir), subpath, size, md5, compressed, relative; 60 | for (var i = 0; i < subpaths.length; ++i) { 61 | if (subpaths[i][0] === '.') { 62 | continue; 63 | } 64 | subpath = path.join(dir, subpaths[i]); 65 | stat = fs.statSync(subpath); 66 | if (stat.isDirectory()) { 67 | readDir(subpath, obj); 68 | } 69 | else if (stat.isFile()) { 70 | // Size in Bytes 71 | size = stat['size']; 72 | md5 = crypto.createHash('md5').update(fs.readFileSync(subpath)).digest('hex'); 73 | compressed = path.extname(subpath).toLowerCase() === '.zip'; 74 | 75 | relative = path.relative(src, subpath); 76 | relative = relative.replace(/\\/g, '/'); 77 | relative = encodeURI(relative); 78 | obj[relative] = { 79 | 'size': size, 80 | 'md5': md5 81 | }; 82 | if (compressed) { 83 | obj[relative].compressed = true; 84 | } 85 | } 86 | } 87 | } catch (err) { 88 | console.error(err) 89 | } 90 | } 91 | 92 | var mkdirSync = function (path) { 93 | try { 94 | fs.mkdirSync(path); 95 | } catch (e) { 96 | if (e.code != 'EEXIST') throw e; 97 | } 98 | } 99 | 100 | // Iterate assets and src folder 101 | readDir(path.join(src, 'src'), manifest.assets); 102 | readDir(path.join(src, 'assets'), manifest.assets); 103 | readDir(path.join(src, 'jsb-adapter'), manifest.assets); 104 | 105 | var destManifest = path.join(dest, 'project.manifest'); 106 | var destVersion = path.join(dest, 'version.manifest'); 107 | 108 | mkdirSync(dest); 109 | 110 | fs.writeFile(destManifest, JSON.stringify(manifest), (err) => { 111 | if (err) throw err; 112 | console.log('Manifest successfully generated'); 113 | }); 114 | 115 | delete manifest.assets; 116 | delete manifest.searchPaths; 117 | fs.writeFile(destVersion, JSON.stringify(manifest), (err) => { 118 | if (err) throw err; 119 | console.log('Version successfully generated'); 120 | }); 121 | --------------------------------------------------------------------------------