├── doc ├── 1 │ ├── 1.png │ ├── 2.png │ └── 3.png ├── 2 │ ├── 1.png │ ├── 2.png │ └── 3.png ├── 3 │ └── 1.png ├── 4.md ├── 1.md ├── 3.md └── 2.md ├── code ├── 2 │ ├── project.json │ ├── assets │ │ ├── Script │ │ │ ├── Global.js │ │ │ ├── UI.meta │ │ │ ├── Global.js.meta │ │ │ ├── UI │ │ │ │ ├── MainUI.js.meta │ │ │ │ ├── UI1.js.meta │ │ │ │ ├── MainUI.js │ │ │ │ └── UI1.js │ │ │ ├── UIManager.js.meta │ │ │ └── UIManager.js │ │ ├── Scene.meta │ │ ├── Script.meta │ │ └── Scene │ │ │ ├── Main.fire.meta │ │ │ └── Main.fire │ ├── jsconfig.json │ ├── settings │ │ ├── project.json │ │ └── services.json │ └── .gitignore └── 4 │ ├── assets │ ├── Texture │ │ ├── Player │ │ │ ├── AutoAtlas.pac │ │ │ ├── sheep_down_0.png │ │ │ ├── AutoAtlas.pac.meta │ │ │ └── sheep_down_0.png.meta │ │ ├── progressbar_bg.png │ │ ├── Player.meta │ │ └── progressbar_bg.png.meta │ ├── Prefab.meta │ ├── Scene.meta │ ├── Texture.meta │ ├── Scene │ │ ├── 优化后.fire.meta │ │ ├── 未优化.fire.meta │ │ ├── 优化后.fire │ │ └── 未优化.fire │ ├── Main.js.meta │ └── Main.js │ ├── project.json │ ├── jsconfig.json │ ├── settings │ ├── project.json │ └── services.json │ └── .gitignore └── README.md /doc/4.md: -------------------------------------------------------------------------------- 1 | ## **drawCall 优化** 2 | *** 3 | 引擎优化了很多, 4 | 我需要再学习下~~ ^_^ -------------------------------------------------------------------------------- /code/4/assets/Texture/Player/AutoAtlas.pac: -------------------------------------------------------------------------------- 1 | { 2 | "__type__": "cc.SpriteAtlas" 3 | } -------------------------------------------------------------------------------- /code/2/project.json: -------------------------------------------------------------------------------- 1 | { 2 | "engine": "cocos-creator-js", 3 | "packages": "packages" 4 | } -------------------------------------------------------------------------------- /code/4/project.json: -------------------------------------------------------------------------------- 1 | { 2 | "engine": "cocos-creator-js", 3 | "packages": "packages" 4 | } -------------------------------------------------------------------------------- /doc/1/1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/freedomyueye/CocosCreator-Programming/HEAD/doc/1/1.png -------------------------------------------------------------------------------- /doc/1/2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/freedomyueye/CocosCreator-Programming/HEAD/doc/1/2.png -------------------------------------------------------------------------------- /doc/1/3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/freedomyueye/CocosCreator-Programming/HEAD/doc/1/3.png -------------------------------------------------------------------------------- /doc/2/1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/freedomyueye/CocosCreator-Programming/HEAD/doc/2/1.png -------------------------------------------------------------------------------- /doc/2/2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/freedomyueye/CocosCreator-Programming/HEAD/doc/2/2.png -------------------------------------------------------------------------------- /doc/2/3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/freedomyueye/CocosCreator-Programming/HEAD/doc/2/3.png -------------------------------------------------------------------------------- /doc/3/1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/freedomyueye/CocosCreator-Programming/HEAD/doc/3/1.png -------------------------------------------------------------------------------- /code/4/assets/Texture/progressbar_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/freedomyueye/CocosCreator-Programming/HEAD/code/4/assets/Texture/progressbar_bg.png -------------------------------------------------------------------------------- /code/4/assets/Texture/Player/sheep_down_0.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/freedomyueye/CocosCreator-Programming/HEAD/code/4/assets/Texture/Player/sheep_down_0.png -------------------------------------------------------------------------------- /code/2/assets/Script/Global.js: -------------------------------------------------------------------------------- 1 | var Global = { 2 | uiManager: null, 3 | 4 | //全局变量 5 | APPID: "123456", 6 | } 7 | 8 | module.exports = cc.Global = Global; 9 | -------------------------------------------------------------------------------- /code/2/assets/Scene.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.1", 3 | "uuid": "2088bd83-8544-4d9f-ba74-f456a2d34769", 4 | "isSubpackage": false, 5 | "subpackageName": "", 6 | "subMetas": {} 7 | } -------------------------------------------------------------------------------- /code/2/assets/Script.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.1", 3 | "uuid": "d254ce5c-ec71-4c55-a0fb-cc30e06a2740", 4 | "isSubpackage": false, 5 | "subpackageName": "", 6 | "subMetas": {} 7 | } -------------------------------------------------------------------------------- /code/4/assets/Prefab.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.1", 3 | "uuid": "a209d36b-8b9f-4d51-bbac-d25fcf03d0eb", 4 | "isSubpackage": false, 5 | "subpackageName": "", 6 | "subMetas": {} 7 | } -------------------------------------------------------------------------------- /code/4/assets/Scene.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.1", 3 | "uuid": "95af9ec1-053d-4603-bd70-68e3765a1a41", 4 | "isSubpackage": false, 5 | "subpackageName": "", 6 | "subMetas": {} 7 | } -------------------------------------------------------------------------------- /code/4/assets/Texture.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.1", 3 | "uuid": "d43da238-8049-4c08-a450-0624b9f9b9b6", 4 | "isSubpackage": false, 5 | "subpackageName": "", 6 | "subMetas": {} 7 | } -------------------------------------------------------------------------------- /code/2/assets/Script/UI.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.1", 3 | "uuid": "7ac91b1e-8274-485f-beac-11264b33aac7", 4 | "isSubpackage": false, 5 | "subpackageName": "", 6 | "subMetas": {} 7 | } -------------------------------------------------------------------------------- /code/4/assets/Texture/Player.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.1", 3 | "uuid": "148cc3ee-b166-4363-abc0-2abbcdb66a3e", 4 | "isSubpackage": false, 5 | "subpackageName": "", 6 | "subMetas": {} 7 | } -------------------------------------------------------------------------------- /code/4/assets/Scene/优化后.fire.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.1.0", 3 | "uuid": "ea0e65b5-c9b1-42e7-bba5-6fcf63e61666", 4 | "asyncLoadAssets": false, 5 | "autoReleaseAssets": false, 6 | "subMetas": {} 7 | } -------------------------------------------------------------------------------- /code/4/assets/Scene/未优化.fire.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.1.0", 3 | "uuid": "af1ce967-723d-47ac-8b86-f3546a8031f6", 4 | "asyncLoadAssets": false, 5 | "autoReleaseAssets": false, 6 | "subMetas": {} 7 | } -------------------------------------------------------------------------------- /code/2/assets/Scene/Main.fire.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.1.0", 3 | "uuid": "2b344c0a-e213-4a1a-b7a7-07a98787b837", 4 | "asyncLoadAssets": false, 5 | "autoReleaseAssets": false, 6 | "subMetas": {} 7 | } -------------------------------------------------------------------------------- /code/4/assets/Main.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "e88f9498-30ff-4ea1-b146-e0f78d114457", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /code/2/assets/Script/Global.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "b63e403a-69d9-4d14-ae3d-bfd014f4b4bc", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /code/2/assets/Script/UI/MainUI.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "64d1d05f-5d8c-414e-8fc3-d326ea609f91", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /code/2/assets/Script/UI/UI1.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "6ca4c379-c2d8-4da5-b64a-23c5815c5177", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /code/2/assets/Script/UIManager.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "7b30f4a3-3dfa-48c4-8753-4349fe319dd6", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /code/2/jsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "es6", 4 | "module": "commonjs", 5 | "experimentalDecorators": true 6 | }, 7 | "exclude": [ 8 | "node_modules", 9 | ".vscode", 10 | "library", 11 | "local", 12 | "settings", 13 | "temp" 14 | ] 15 | } -------------------------------------------------------------------------------- /code/4/jsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "es6", 4 | "module": "commonjs", 5 | "experimentalDecorators": true 6 | }, 7 | "exclude": [ 8 | "node_modules", 9 | ".vscode", 10 | "library", 11 | "local", 12 | "settings", 13 | "temp" 14 | ] 15 | } -------------------------------------------------------------------------------- /code/4/assets/Scene/优化后.fire: -------------------------------------------------------------------------------- 1 | [{"__type__":"cc.SceneAsset","scene":{"__id__":1}},{"__type__":"cc.Scene","_children":[{"__id__":2}]},{"__type__":"cc.Node","_name":"Canvas","_parent":{"__id__":1},"_children":[],"_components":[{"__id__":3}]},{"__type__":"cc.Canvas","node":{"__id__":2},"_fitWidth":false,"_fitHeight":true,"_designResolution":{"__type__":"cc.Size","width":960,"height":640}}] -------------------------------------------------------------------------------- /code/4/assets/Texture/Player/AutoAtlas.pac.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.2.0", 3 | "uuid": "6ce9a398-fdaf-486c-b81e-1b3ed157c296", 4 | "maxWidth": 1024, 5 | "maxHeight": 1024, 6 | "padding": 2, 7 | "allowRotation": true, 8 | "forceSquared": false, 9 | "powerOfTwo": false, 10 | "heuristices": "BestAreaFit", 11 | "format": "png", 12 | "quality": 80, 13 | "contourBleed": true, 14 | "paddingBleed": true, 15 | "filterUnused": false, 16 | "platformSettings": {}, 17 | "subMetas": {} 18 | } -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # CocosCreator-Programming 2 | Cocos Creator 编程框架,如何快速搭建一个小游戏。 包含教程和DEMO。 3 | 4 | > 优先把Cocos Creator的文档看完 [链接](https://docs.cocos.com/creator/manual/zh/) 5 | > 代码使用 Cocos Creator 2.1.1 版本 6 | ### **开始** 7 | 1. [基础 编辑器推荐 文件夹命名推荐 代码规范 gitignore 杂等](doc/1.md) 8 | 2. [单件和UI管理](doc/2.md) 9 | 3. [对象池封装](doc/3.md) 10 | 4. [drawCall 优化](doc/4.md) 11 | 5. 可更新的本地存档 12 | 6. 新手引导实现(截获事件。当TimeScale 停止时,正常播放Animation) 13 | 7. websocket 网络连接 14 | 8. 使用matter.js 物理引擎 15 | 16 | *** 17 | ### **杂** 18 | * 使用 build-templates 文件夹,编译自动覆盖build里面文件 19 | * 使用 FontPruner 精简字体文件大小 20 | * 使用 excel2json 把excel生成json文件 21 | * Common.js 我常用的函数 22 | * 好看的窗口 弹出动画 23 | * 金币掉落飞行实现 24 | * 当TimeScale 为0时候, 如何更新Animation动画。 25 | * 镜头抖动实现和移动注意事项 26 | 27 | -------------------------------------------------------------------------------- /code/2/settings/project.json: -------------------------------------------------------------------------------- 1 | { 2 | "start-scene": "current", 3 | "group-list": [ 4 | "default" 5 | ], 6 | "collision-matrix": [ 7 | [ 8 | true 9 | ] 10 | ], 11 | "excluded-modules": [], 12 | "last-module-event-record-time": 0, 13 | "design-resolution-width": 960, 14 | "design-resolution-height": 640, 15 | "fit-width": false, 16 | "fit-height": true, 17 | "use-project-simulator-setting": false, 18 | "simulator-orientation": false, 19 | "use-customize-simulator": false, 20 | "simulator-resolution": { 21 | "width": 960, 22 | "height": 640 23 | }, 24 | "assets-sort-type": "name", 25 | "facebook": { 26 | "enable": false, 27 | "appID": "", 28 | "live": { 29 | "enable": false 30 | }, 31 | "audience": { 32 | "enable": false 33 | } 34 | } 35 | } -------------------------------------------------------------------------------- /code/4/settings/project.json: -------------------------------------------------------------------------------- 1 | { 2 | "start-scene": "current", 3 | "group-list": [ 4 | "default" 5 | ], 6 | "collision-matrix": [ 7 | [ 8 | true 9 | ] 10 | ], 11 | "excluded-modules": [], 12 | "last-module-event-record-time": 0, 13 | "design-resolution-width": 960, 14 | "design-resolution-height": 640, 15 | "fit-width": false, 16 | "fit-height": true, 17 | "use-project-simulator-setting": false, 18 | "simulator-orientation": false, 19 | "use-customize-simulator": false, 20 | "simulator-resolution": { 21 | "width": 960, 22 | "height": 640 23 | }, 24 | "assets-sort-type": "name", 25 | "facebook": { 26 | "enable": false, 27 | "appID": "", 28 | "live": { 29 | "enable": false 30 | }, 31 | "audience": { 32 | "enable": false 33 | } 34 | } 35 | } -------------------------------------------------------------------------------- /code/4/assets/Texture/progressbar_bg.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.0", 3 | "uuid": "fe3d1b46-0b6f-4d73-8e4e-a09d8cbd7510", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "progressbar_bg": { 11 | "ver": "1.0.4", 12 | "uuid": "06e18442-4cee-40a1-b765-a1e246ec9c06", 13 | "rawTextureUuid": "fe3d1b46-0b6f-4d73-8e4e-a09d8cbd7510", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 60, 22 | "height": 15, 23 | "rawWidth": 60, 24 | "rawHeight": 15, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /code/4/assets/Texture/Player/sheep_down_0.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.0", 3 | "uuid": "dd845774-0b71-42be-b577-5033755e3f49", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "sheep_down_0": { 11 | "ver": "1.0.4", 12 | "uuid": "eb612056-a425-4c2f-832a-bb31c38d3aa1", 13 | "rawTextureUuid": "dd845774-0b71-42be-b577-5033755e3f49", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": -25, 19 | "trimX": 2, 20 | "trimY": 61, 21 | "width": 224, 22 | "height": 87, 23 | "rawWidth": 228, 24 | "rawHeight": 159, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /code/2/assets/Script/UI/MainUI.js: -------------------------------------------------------------------------------- 1 | // Learn cc.Class: 2 | // - [Chinese] https://docs.cocos.com/creator/manual/zh/scripting/class.html 3 | // - [English] http://docs.cocos2d-x.org/creator/manual/en/scripting/class.html 4 | // Learn Attribute: 5 | // - [Chinese] https://docs.cocos.com/creator/manual/zh/scripting/reference/attributes.html 6 | // - [English] http://docs.cocos2d-x.org/creator/manual/en/scripting/reference/attributes.html 7 | // Learn life-cycle callbacks: 8 | // - [Chinese] https://docs.cocos.com/creator/manual/zh/scripting/life-cycle-callbacks.html 9 | // - [English] https://www.cocos2d-x.org/docs/creator/manual/en/scripting/life-cycle-callbacks.html 10 | 11 | cc.Class({ 12 | extends: cc.Component, 13 | 14 | properties: { 15 | 16 | }, 17 | 18 | // LIFE-CYCLE CALLBACKS: 19 | 20 | // onLoad () {}, 21 | 22 | start() { 23 | 24 | }, 25 | 26 | handleBtn1() { 27 | cc.Global.uiManager.showUI1("MainUI 传入信息") 28 | } 29 | 30 | // update (dt) {}, 31 | }); 32 | -------------------------------------------------------------------------------- /doc/1.md: -------------------------------------------------------------------------------- 1 | # 基础 2 | ## **编辑器推荐** 3 | > [VSCode](https://code.visualstudio.com/) 4 | > 速度快,插件丰富,外观好看~ 没理由不选择它~ 5 | 6 | > 推荐开打文件保存时自动格式化代码,这样代码会很规范。 7 | > ![](1/2.png) ![](1/3.png) 8 | 9 | *** 10 | ## **git工具推荐** 11 | >Git 客户端 —— Sourcetree [安装教程](https://docs.cocos.com/creator/manual/zh/submit-pr/submit-pr.html) 12 | *** 13 | ## **文件夹命名推荐** 14 | >![](1/1.png) 15 | * Anim-动画文件 16 | * Audios-音效文件 17 | * Config-配置文件 18 | * Loading-不用管这个, 这个是之前为了实现微信小游戏加载界面,把单独加载界面资源都放到里面。 19 | * Prefab-就是Prefab 20 | * resources-cocos creator默认的 动态加载的文件夹 cc.loader 加载路径。 21 | * Scene-场景 22 | * Script-代码 23 | * Texture-UI和游戏图片资源 24 | 25 | *** 26 | ## **代码规范** 27 | > [骆驼命名法](https://baike.baidu.com/item/%E9%AA%86%E9%A9%BC%E5%91%BD%E5%90%8D%E6%B3%95) 28 | *** 29 | ## **.gitignore 配置** 30 | > Cocos Creator 创建新项目已经会自动生成。 重要的是如下几行 31 | ``` 32 | #///////////////////////////////////////////////////////////////////////////// 33 | # Cocos Projects 34 | #///////////////////////////////////////////////////////////////////////////// 35 | 36 | library/ 37 | temp/ 38 | local/ 39 | build/ 40 | 41 | ``` 42 | 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /code/2/assets/Script/UIManager.js: -------------------------------------------------------------------------------- 1 | // Learn cc.Class: 2 | // - [Chinese] https://docs.cocos.com/creator/manual/zh/scripting/class.html 3 | // - [English] http://docs.cocos2d-x.org/creator/manual/en/scripting/class.html 4 | // Learn Attribute: 5 | // - [Chinese] https://docs.cocos.com/creator/manual/zh/scripting/reference/attributes.html 6 | // - [English] http://docs.cocos2d-x.org/creator/manual/en/scripting/reference/attributes.html 7 | // Learn life-cycle callbacks: 8 | // - [Chinese] https://docs.cocos.com/creator/manual/zh/scripting/life-cycle-callbacks.html 9 | // - [English] https://www.cocos2d-x.org/docs/creator/manual/en/scripting/life-cycle-callbacks.html 10 | 11 | cc.Class({ 12 | extends: cc.Component, 13 | 14 | properties: { 15 | ui1: cc.Node, 16 | }, 17 | 18 | // LIFE-CYCLE CALLBACKS: 19 | 20 | onLoad() { 21 | cc.Global.uiManager = this; 22 | }, 23 | 24 | start() { 25 | }, 26 | 27 | showUI1(title) { 28 | this.ui1.getComponent("UI1").initData(title); 29 | this.ui1.active = true; 30 | }, 31 | 32 | //接受回调UI1关闭 33 | //比如关闭UI1时候 打开某个界面。 34 | //由UI1 里面直接调用 35 | handleCloseUI1() { 36 | 37 | }, 38 | 39 | // update (dt) {}, 40 | }); 41 | -------------------------------------------------------------------------------- /code/2/.gitignore: -------------------------------------------------------------------------------- 1 | #///////////////////////////////////////////////////////////////////////////// 2 | # Fireball Projects 3 | #///////////////////////////////////////////////////////////////////////////// 4 | 5 | /library/ 6 | /temp/ 7 | /local/ 8 | /build/ 9 | 10 | #///////////////////////////////////////////////////////////////////////////// 11 | # npm files 12 | #///////////////////////////////////////////////////////////////////////////// 13 | 14 | npm-debug.log 15 | node_modules/ 16 | 17 | #///////////////////////////////////////////////////////////////////////////// 18 | # Logs and databases 19 | #///////////////////////////////////////////////////////////////////////////// 20 | 21 | *.log 22 | *.sql 23 | *.sqlite 24 | 25 | #///////////////////////////////////////////////////////////////////////////// 26 | # files for debugger 27 | #///////////////////////////////////////////////////////////////////////////// 28 | 29 | *.sln 30 | *.csproj 31 | *.pidb 32 | *.unityproj 33 | *.suo 34 | 35 | #///////////////////////////////////////////////////////////////////////////// 36 | # OS generated files 37 | #///////////////////////////////////////////////////////////////////////////// 38 | 39 | .DS_Store 40 | ehthumbs.db 41 | Thumbs.db 42 | 43 | #///////////////////////////////////////////////////////////////////////////// 44 | # WebStorm files 45 | #///////////////////////////////////////////////////////////////////////////// 46 | 47 | .idea/ 48 | 49 | #////////////////////////// 50 | # VS Code files 51 | #////////////////////////// 52 | 53 | .vscode/ 54 | -------------------------------------------------------------------------------- /code/4/.gitignore: -------------------------------------------------------------------------------- 1 | #///////////////////////////////////////////////////////////////////////////// 2 | # Fireball Projects 3 | #///////////////////////////////////////////////////////////////////////////// 4 | 5 | /library/ 6 | /temp/ 7 | /local/ 8 | /build/ 9 | 10 | #///////////////////////////////////////////////////////////////////////////// 11 | # npm files 12 | #///////////////////////////////////////////////////////////////////////////// 13 | 14 | npm-debug.log 15 | node_modules/ 16 | 17 | #///////////////////////////////////////////////////////////////////////////// 18 | # Logs and databases 19 | #///////////////////////////////////////////////////////////////////////////// 20 | 21 | *.log 22 | *.sql 23 | *.sqlite 24 | 25 | #///////////////////////////////////////////////////////////////////////////// 26 | # files for debugger 27 | #///////////////////////////////////////////////////////////////////////////// 28 | 29 | *.sln 30 | *.csproj 31 | *.pidb 32 | *.unityproj 33 | *.suo 34 | 35 | #///////////////////////////////////////////////////////////////////////////// 36 | # OS generated files 37 | #///////////////////////////////////////////////////////////////////////////// 38 | 39 | .DS_Store 40 | ehthumbs.db 41 | Thumbs.db 42 | 43 | #///////////////////////////////////////////////////////////////////////////// 44 | # WebStorm files 45 | #///////////////////////////////////////////////////////////////////////////// 46 | 47 | .idea/ 48 | 49 | #////////////////////////// 50 | # VS Code files 51 | #////////////////////////// 52 | 53 | .vscode/ 54 | -------------------------------------------------------------------------------- /code/4/assets/Main.js: -------------------------------------------------------------------------------- 1 | // Learn cc.Class: 2 | // - [Chinese] https://docs.cocos.com/creator/manual/zh/scripting/class.html 3 | // - [English] http://docs.cocos2d-x.org/creator/manual/en/scripting/class.html 4 | // Learn Attribute: 5 | // - [Chinese] https://docs.cocos.com/creator/manual/zh/scripting/reference/attributes.html 6 | // - [English] http://docs.cocos2d-x.org/creator/manual/en/scripting/reference/attributes.html 7 | // Learn life-cycle callbacks: 8 | // - [Chinese] https://docs.cocos.com/creator/manual/zh/scripting/life-cycle-callbacks.html 9 | // - [English] https://www.cocos2d-x.org/docs/creator/manual/en/scripting/life-cycle-callbacks.html 10 | 11 | cc.Class({ 12 | extends: cc.Component, 13 | 14 | properties: { 15 | // foo: { 16 | // // ATTRIBUTES: 17 | // default: null, // The default value will be used only when the component attaching 18 | // // to a node for the first time 19 | // type: cc.SpriteFrame, // optional, default is typeof default 20 | // serializable: true, // optional, default is true 21 | // }, 22 | // bar: { 23 | // get () { 24 | // return this._bar; 25 | // }, 26 | // set (value) { 27 | // this._bar = value; 28 | // } 29 | // }, 30 | }, 31 | 32 | // LIFE-CYCLE CALLBACKS: 33 | 34 | onLoad() { 35 | 36 | }, 37 | 38 | start() { 39 | cc.dynamicAtlasManager.showDebug(true); 40 | }, 41 | 42 | // update (dt) {}, 43 | }); 44 | -------------------------------------------------------------------------------- /doc/3.md: -------------------------------------------------------------------------------- 1 | ## **对象池封装** 2 | *** 3 | > [Cocos Creator- NodePool 介绍 ](https://docs.cocos.com/creator/manual/zh/scripting/pooling.html) 4 | 5 | > 编辑器 6 | > ![](3/1.png) 7 | 8 | > 使用 9 | 10 | ```js 11 | window.PoolType = cc.Enum({ 12 | BULLET: 0, 13 | GOLD: 1, 14 | }); 15 | //获得节点 16 | window.poolManager.getNode(PoolType.GOLD) 17 | //返还节点 18 | window.poolManager.putNode(PoolType.GOLD) 19 | ``` 20 | 21 | PoolManager.js 22 | ```js 23 | cc.Class({ 24 | extends: cc.Component, 25 | 26 | properties: { 27 | poolPrefabs: [cc.Prefab], //需要管理的prefab 放入进来 28 | _nodesPool: [], // 存储对应的cc.NodePool 29 | }, 30 | 31 | // LIFE-CYCLE CALLBACKS: 32 | 33 | onLoad() { 34 | window.poolManager = this;// 全局方便使用 35 | this.poolPrefabs.forEach(element => { 36 | let np = new cc.NodePool(); 37 | this._nodesPool.push(np); 38 | }); 39 | }, 40 | 41 | start() { 42 | 43 | }, 44 | 45 | // 创建并缓存节点 - 如果需要提前缓存,可以调用。 46 | genNode(type) { 47 | let prefab = this.poolPrefabs[type]; 48 | let node = cc.instantiate(prefab); 49 | node.active = false; 50 | this._nodesPool[type].put(node); 51 | }, 52 | //获得节点 53 | getNode(type) { 54 | let node = null; 55 | if (this._nodesPool[type].size() > 0) { // 通过 size 接口判断对象池中是否有空闲的对象 56 | node = this._nodesPool[type].get(); 57 | } else { // 如果没有空闲对象,也就是对象池中备用对象不够时,我们就用 cc.instantiate 重新创建 58 | node = cc.instantiate(this.poolPrefabs[type]); 59 | } 60 | return node; 61 | }, 62 | //返还节点 63 | putNode(type, node) { 64 | this._nodesPool[type].put(node); 65 | }, 66 | //释放所有节点 67 | clearAllNode(type) { 68 | this._nodesPool[type].clear(); 69 | } 70 | 71 | // update (dt) {}, 72 | }); 73 | ``` -------------------------------------------------------------------------------- /code/2/assets/Script/UI/UI1.js: -------------------------------------------------------------------------------- 1 | // Learn cc.Class: 2 | // - [Chinese] https://docs.cocos.com/creator/manual/zh/scripting/class.html 3 | // - [English] http://docs.cocos2d-x.org/creator/manual/en/scripting/class.html 4 | // Learn Attribute: 5 | // - [Chinese] https://docs.cocos.com/creator/manual/zh/scripting/reference/attributes.html 6 | // - [English] http://docs.cocos2d-x.org/creator/manual/en/scripting/reference/attributes.html 7 | // Learn life-cycle callbacks: 8 | // - [Chinese] https://docs.cocos.com/creator/manual/zh/scripting/life-cycle-callbacks.html 9 | // - [English] https://www.cocos2d-x.org/docs/creator/manual/en/scripting/life-cycle-callbacks.html 10 | 11 | cc.Class({ 12 | extends: cc.Component, 13 | 14 | properties: { 15 | titleLabel: cc.Label, 16 | }, 17 | 18 | // LIFE-CYCLE CALLBACKS: 19 | 20 | //初始化地方,可以用来获得一些节点信息 21 | //注意:当在Scene 如果active 为false。会在active为true 的时候调用一次。并且在onEnable之前 22 | onLoad() { 23 | this.title2Label = this.node.getChildByName("Title2").getComponent(cc.Label); 24 | 25 | //注意 如果外部会通过initData 修改。 不要再这边初始化, 放到onEnable函数里面 26 | //当Scene中节点active false时, 函数被调用流程 initData->onLoad->onEnable 27 | //this.title2Label.string = "哈哈哈"; 28 | }, 29 | 30 | //外部信息传入, 存储纯数据,之后由onEnable去配置到对应节点信息。 31 | //建议在设置active 为true 前调用 32 | initData(title) { 33 | this.titleString = title; 34 | }, 35 | //当active false=>true 时触发。 36 | //Scene 如果设置active 为true 时,Scene加载后会被调用 37 | //注意:父节点的active 变化并不会触发。 38 | onEnable() { 39 | this.titleLabel.string = this.titleString; 40 | this.title2Label.string = "呵呵呵"; 41 | }, 42 | 43 | //active true=>false 时候触发 44 | //注意:父节点的active 变化并不会触发。 45 | onDisable() { 46 | 47 | }, 48 | 49 | start() { 50 | 51 | }, 52 | 53 | handleBtn1() { 54 | this.titleLabel.string = "UI1 按下按钮"; 55 | }, 56 | 57 | handleClose() { 58 | this.node.active = false; 59 | //告诉外面 此界面关闭 60 | cc.Global.uiManager.handleCloseUI1(); 61 | }, 62 | 63 | // update (dt) {}, 64 | }); 65 | -------------------------------------------------------------------------------- /doc/2.md: -------------------------------------------------------------------------------- 1 | ## **单件和UI管理** 2 | 3 | [talk is cheap, show me the code 本章代码链接](code/2) 4 | ### **生命周期** 5 | > [**Cocos creator 组件生命周期**](https://docs.cocos.com/creator/manual/zh/scripting/life-cycle-callbacks.html) 6 | > 很重要,需要仔细阅读 7 | ### **单件** 8 | > 全局唯一变量或模块,方便别的模块直接调用 9 | > 游戏中的各种管理模块:UI管理,音效管理,存档管理和游戏管理,都可以做成单件。 10 | 11 | Global.js 12 | ```js 13 | var Global = { 14 | uiManager: null, 15 | //全局变量 16 | APPID: "123456", 17 | } 18 | 19 | module.exports = cc.Global = Global; 20 | ``` 21 | > 别的代码模块可以通过 cc.Global.uiManager 来获取到uiManager(现在时null,可以再别的地方初始化)。cc.Global.APPID 获取游戏ID 22 | > 也可以存储全局 23 | *** 24 | > 其他项目 我写了好多Manager,方便调用 25 | ![](2/3.png) 26 | 比如专门用来存储SpriteFrame的Manager,json配置文件的Manager,都和UIManager类似 27 | 28 | *** 29 | ### **UI管理** 30 | > 先参考下编辑器里面的结构 31 | ![](2/1.png) 32 | ![](2/2.png) 33 | > * DEMO 主要是MainUI上面弹出UI1界面的逻辑,UI1可扩展为各种弹框 34 | > * UI1是默认关闭的 35 | > * UIManager为管理所有UI的开启 36 | 37 | > 先看下UIManager.js 38 | ```js 39 | cc.Class({ 40 | extends: cc.Component, 41 | 42 | properties: { 43 | ui1: cc.Node, 44 | }, 45 | 46 | // LIFE-CYCLE CALLBACKS: 47 | 48 | onLoad() { 49 | cc.Global.uiManager = this; 50 | }, 51 | 52 | start() { 53 | }, 54 | 55 | showUI1(title) { 56 | this.ui1.getComponent("UI1").initData(title); 57 | this.ui1.active = true; 58 | }, 59 | 60 | //接受回调UI1关闭 61 | //比如关闭UI1时候 打开某个界面。 62 | //由UI1 里面直接调用 63 | handleCloseUI1() { 64 | 65 | }, 66 | 67 | // update (dt) {}, 68 | }); 69 | ``` 70 | > 注意: onLoad 函数把自己赋值给了全局的Global.uiManager 71 | *** 72 | > MainUI.js 中按钮回调 显示UI1 73 | ```js 74 | handleBtn1() { 75 | cc.Global.uiManager.showUI1("MainUI 传入信息") 76 | } 77 | ``` 78 | *** 79 | > 稍微复杂些的 UI1.js 代码。 直接看注释就行 80 | ```js 81 | cc.Class({ 82 | extends: cc.Component, 83 | 84 | properties: { 85 | titleLabel: cc.Label, 86 | }, 87 | 88 | // LIFE-CYCLE CALLBACKS: 89 | 90 | //初始化地方,可以用来获得一些节点信息 91 | //注意:当在Scene 如果active 为false。会在active为true 的时候调用一次。并且在onEnable之前 92 | onLoad() { 93 | this.title2Label = this.node.getChildByName("Title2").getComponent(cc.Label); 94 | 95 | //注意 如果外部会通过initData 修改。 不要再这边初始化, 放到onEnable函数里面 96 | //当Scene中节点active false时, 函数被调用流程 initData->onLoad->onEnable 97 | //this.title2Label.string = "哈哈哈"; 98 | }, 99 | 100 | //外部信息传入, 存储纯数据,之后由onEnable去配置到对应节点信息。 101 | //建议在设置active 为true 前调用 102 | initData(title) { 103 | this.titleString = title; 104 | }, 105 | //当active false=>true 时触发。 106 | //Scene 如果设置active 为true 时,Scene加载后会被调用 107 | //注意:父节点的active 变化并不会触发。 108 | onEnable() { 109 | this.titleLabel.string = this.titleString; 110 | this.title2Label.string = "呵呵呵"; 111 | }, 112 | 113 | //active true=>false 时候触发 114 | //注意:父节点的active 变化并不会触发。 115 | onDisable() { 116 | 117 | }, 118 | 119 | start() { 120 | 121 | }, 122 | 123 | handleBtn1() { 124 | this.titleLabel.string = "UI1 按下按钮"; 125 | }, 126 | 127 | handleClose() { 128 | this.node.active = false; 129 | //告诉外面 此界面关闭 130 | cc.Global.uiManager.handleCloseUI1(); 131 | }, 132 | 133 | // update (dt) {}, 134 | }); 135 | ``` 136 | *** 137 | ### **UIManager扩展** 138 | > 当整体需要只显示一个界面,比如 139 | ```js 140 | UIBoards = cc.Enum({ 141 | GAMING: 0,//游戏界面 142 | START: 1,//开始界面 143 | GAMEEND: 2,//结算界面 144 | SHOP: 3, //商城界面 145 | }); 146 | ``` 147 | > 这些界面都是单独直接显示的。 148 | > 我们可以 UIManager里面修改 149 | ```js 150 | properties: { 151 | boards: [cc.Node], 152 | }, 153 | //界面切换函数 154 | switchBoard(index) { 155 | this.boards.forEach(node => { 156 | node.active = false; 157 | }); 158 | this._preBoardIndex = this._curBoardIndex; 159 | this.boards[index].active = true; 160 | this._curBoardIndex = index; 161 | }, 162 | ``` 163 | > 我们通过 外部代码通过 switchBoard 函数切换界面 164 | 165 | 166 | 167 | 168 | 169 | -------------------------------------------------------------------------------- /code/2/settings/services.json: -------------------------------------------------------------------------------- 1 | { 2 | "services": [ 3 | { 4 | "service_id": "235", 5 | "service_name": "Cocos Analytics", 6 | "service_icon": "https://account.cocos.com/client/3f8f31ccf66995e183044f167c092395.png", 7 | "service_desc": "提供最核心最基本的数据、标准化界面功能简洁易用、数据准确性最好", 8 | "service_title": "精准了解游戏的新增、活跃、留存、付费等数据", 9 | "service_guide_url": "https://n-analytics.cocos.com/docs/", 10 | "service_sample_url": "https://github.com/cocos-creator/tutorial-dark-slash/tree/analytics", 11 | "service_dev_url": "http://analytics.cocos.com/realtime/jump_to/", 12 | "service_type": "3", 13 | "service_type_zh": "公司和个人游戏", 14 | "support_platform": [ 15 | "Android", 16 | "iOS", 17 | "HTML5" 18 | ], 19 | "package_download_url": "http://download.cocos.com/CocosServices/plugins/service-analytics/1.2.0_2.1.0.zip", 20 | "package_version_desc": "1、优化SDK,修复H5-SDK 与多个小游戏平台适配问题,删除和优化init事件无用接口
2、 如有相关问题咨询或者需求, 可以联系我们技术支持邮箱 support-cocos@cocos.com", 21 | "service_component_name": "service-analytics", 22 | "package_versions": [ 23 | "1.0.0_1.0.5", 24 | "1.1.2_2.0.0", 25 | "1.1.3_2.0.1", 26 | "1.1.4_2.0.1", 27 | "1.1.5_2.0.1", 28 | "1.1.6_2.0.1_2.0.2", 29 | "1.1.7_2.0.3", 30 | "1.1.8_2.0.4", 31 | "1.1.9_2.1.0", 32 | "1.2.0_2.1.0" 33 | ], 34 | "build_platform": [ 35 | "web-mobile", 36 | "web-desktop", 37 | "wechatgame", 38 | "android", 39 | "ios", 40 | "fb-instant-games", 41 | "android-instant", 42 | "baidugame", 43 | "quickgame", 44 | "qgame", 45 | "qqplay", 46 | "huawei" 47 | ], 48 | "require_verify": 0, 49 | "service_price": "", 50 | "packpage_version_desc": "", 51 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》" 52 | }, 53 | { 54 | "service_id": "241", 55 | "service_name": "Matchvs", 56 | "service_icon": "https://account.cocos.com/client/14406719a07eb3d714d36e5edc6e06fa.png", 57 | "service_desc": "通过SDK接入快速实现联网功能、帧同步、国内外多节点、服务器独立部署、gameServer自定义游戏服务端逻辑。\n技术支持群QQ群:822523258", 58 | "service_title": "专业成熟的移动游戏联网与服务端解决方案", 59 | "service_guide_url": "http://doc.matchvs.com/QuickStart/QuickStart-CocosCreator", 60 | "service_sample_url": "http://www.matchvs.com/serviceCourse", 61 | "service_dev_url": "http://www.matchvs.com/cocosLogin", 62 | "service_type": "3", 63 | "service_type_zh": "公司和个人游戏", 64 | "support_platform": [ 65 | "Android", 66 | "iOS", 67 | "HTML5" 68 | ], 69 | "package_download_url": "http://download.cocos.com/CocosServices/plugins/service-matchvs/1.0.7_3.7.9.6.zip", 70 | "package_version_desc": "更新日期:2019-05-15
更新内容:
1、调整getRoomListEx接口,获取系统创建房间
2、增加appkey等的校验
3、新增以下平台支持:
  • VIVO 小游戏
  • OPPO 小游戏
  • HUAWEI 快游戏
  • 百度小游戏(默认不支持,需修改代码强制开启WSS选项)", 71 | "service_component_name": "service-matchvs", 72 | "package_versions": [ 73 | "1.0.3_3.7.6.4", 74 | "1.0.5_3.7.7.3", 75 | "1.0.6_3.7.9.2", 76 | "1.0.7_3.7.9.6" 77 | ], 78 | "build_platform": [ 79 | "web-mobile", 80 | "web-desktop", 81 | "fb-instant-games", 82 | "wechatgame", 83 | "wechatgame-subcontext", 84 | "qqplay", 85 | "android", 86 | "android-instant", 87 | "ios", 88 | "mac", 89 | "quickgame", 90 | "qgame", 91 | "huawei" 92 | ], 93 | "require_verify": 0, 94 | "service_price": "该服务按使用量计费,计费规则,所产生的费用将由第三方从您的 Cocos 账户余额 中扣除。", 95 | "packpage_version_desc": "", 96 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》" 97 | }, 98 | { 99 | "service_id": "242", 100 | "service_name": "Agora Voice", 101 | "service_icon": "https://account.cocos.com/uploads/client_icon/date(\"Y-m-d\")/50fe52b789c2fc1e1fff9eec161c1bb3.png", 102 | "service_desc": "稳定、低耗、76ms超低延时、全球200+数据中心覆盖;变声器、超高音质、听声辩位等丰富玩法极速接入;全平台支持:Android、iOS、Web。\n技术支持群QQ群:799099183\n", 103 | "service_title": "游戏内置实时语音", 104 | "service_guide_url": "https://docs.agora.io/cn/Interactive Gaming/game_c", 105 | "service_sample_url": "https://github.com/AgoraIO/Voice-Call-for-Mobile-Gaming/tree/master/Basic-Voice-Call-for-Gaming/Hello-CocosCreator-Voice-Agora", 106 | "service_dev_url": "https://sso.agora.io/api/oauth/cocos/login", 107 | "service_type": "3", 108 | "service_type_zh": "公司和个人游戏", 109 | "support_platform": [ 110 | "Android", 111 | "iOS", 112 | "HTML5" 113 | ], 114 | "package_download_url": "http://download.cocos.com/CocosServices/plugins/service-agora/1.0.2_2.2.3.20_2.5.2.zip", 115 | "package_version_desc": "解决Bug:onAudioVolumeIndication 回调收不到.", 116 | "service_component_name": "service-agora", 117 | "package_versions": [ 118 | "1.0.1_2.2.3.20_2.5.2", 119 | "1.0.2_2.2.3.20_2.5.2" 120 | ], 121 | "build_platform": [ 122 | "web-mobile", 123 | "web-desktop", 124 | "android", 125 | "ios" 126 | ], 127 | "require_verify": 1, 128 | "service_price": "该服务按使用量计费,计费规则,所产生的费用将由第三方从您的 Cocos 账户余额 中扣除。", 129 | "packpage_version_desc": "", 130 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》" 131 | } 132 | ], 133 | "game": { 134 | "name": "未知游戏", 135 | "appid": "UNKNOW" 136 | } 137 | } -------------------------------------------------------------------------------- /code/4/settings/services.json: -------------------------------------------------------------------------------- 1 | { 2 | "services": [ 3 | { 4 | "service_id": "235", 5 | "service_name": "Cocos Analytics", 6 | "service_icon": "https://account.cocos.com/client/3f8f31ccf66995e183044f167c092395.png", 7 | "service_desc": "提供最核心最基本的数据、标准化界面功能简洁易用、数据准确性最好", 8 | "service_title": "精准了解游戏的新增、活跃、留存、付费等数据", 9 | "service_guide_url": "https://n-analytics.cocos.com/docs/", 10 | "service_sample_url": "https://github.com/cocos-creator/tutorial-dark-slash/tree/analytics", 11 | "service_dev_url": "http://analytics.cocos.com/realtime/jump_to/", 12 | "service_type": "3", 13 | "service_type_zh": "公司和个人游戏", 14 | "support_platform": [ 15 | "Android", 16 | "iOS", 17 | "HTML5" 18 | ], 19 | "package_download_url": "http://download.cocos.com/CocosServices/plugins/service-analytics/1.2.0_2.1.0.zip", 20 | "package_version_desc": "1、优化SDK,修复H5-SDK 与多个小游戏平台适配问题,删除和优化init事件无用接口
    2、 如有相关问题咨询或者需求, 可以联系我们技术支持邮箱 support-cocos@cocos.com", 21 | "service_component_name": "service-analytics", 22 | "package_versions": [ 23 | "1.0.0_1.0.5", 24 | "1.1.2_2.0.0", 25 | "1.1.3_2.0.1", 26 | "1.1.4_2.0.1", 27 | "1.1.5_2.0.1", 28 | "1.1.6_2.0.1_2.0.2", 29 | "1.1.7_2.0.3", 30 | "1.1.8_2.0.4", 31 | "1.1.9_2.1.0", 32 | "1.2.0_2.1.0" 33 | ], 34 | "build_platform": [ 35 | "web-mobile", 36 | "web-desktop", 37 | "wechatgame", 38 | "android", 39 | "ios", 40 | "fb-instant-games", 41 | "android-instant", 42 | "baidugame", 43 | "quickgame", 44 | "qgame", 45 | "qqplay", 46 | "huawei" 47 | ], 48 | "require_verify": 0, 49 | "service_price": "", 50 | "packpage_version_desc": "", 51 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》" 52 | }, 53 | { 54 | "service_id": "241", 55 | "service_name": "Matchvs", 56 | "service_icon": "https://account.cocos.com/client/14406719a07eb3d714d36e5edc6e06fa.png", 57 | "service_desc": "通过SDK接入快速实现联网功能、帧同步、国内外多节点、服务器独立部署、gameServer自定义游戏服务端逻辑。\n技术支持群QQ群:822523258", 58 | "service_title": "专业成熟的移动游戏联网与服务端解决方案", 59 | "service_guide_url": "http://doc.matchvs.com/QuickStart/QuickStart-CocosCreator", 60 | "service_sample_url": "http://www.matchvs.com/serviceCourse", 61 | "service_dev_url": "http://www.matchvs.com/cocosLogin", 62 | "service_type": "3", 63 | "service_type_zh": "公司和个人游戏", 64 | "support_platform": [ 65 | "Android", 66 | "iOS", 67 | "HTML5" 68 | ], 69 | "package_download_url": "http://download.cocos.com/CocosServices/plugins/service-matchvs/1.0.7_3.7.9.6.zip", 70 | "package_version_desc": "更新日期:2019-05-15
    更新内容:
    1、调整getRoomListEx接口,获取系统创建房间
    2、增加appkey等的校验
    3、新增以下平台支持:
  • VIVO 小游戏
  • OPPO 小游戏
  • HUAWEI 快游戏
  • 百度小游戏(默认不支持,需修改代码强制开启WSS选项)", 71 | "service_component_name": "service-matchvs", 72 | "package_versions": [ 73 | "1.0.3_3.7.6.4", 74 | "1.0.5_3.7.7.3", 75 | "1.0.6_3.7.9.2", 76 | "1.0.7_3.7.9.6" 77 | ], 78 | "build_platform": [ 79 | "web-mobile", 80 | "web-desktop", 81 | "fb-instant-games", 82 | "wechatgame", 83 | "wechatgame-subcontext", 84 | "qqplay", 85 | "android", 86 | "android-instant", 87 | "ios", 88 | "mac", 89 | "quickgame", 90 | "qgame", 91 | "huawei" 92 | ], 93 | "require_verify": 0, 94 | "service_price": "该服务按使用量计费,计费规则,所产生的费用将由第三方从您的 Cocos 账户余额 中扣除。", 95 | "packpage_version_desc": "", 96 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》" 97 | }, 98 | { 99 | "service_id": "242", 100 | "service_name": "Agora Voice", 101 | "service_icon": "https://account.cocos.com/uploads/client_icon/date(\"Y-m-d\")/50fe52b789c2fc1e1fff9eec161c1bb3.png", 102 | "service_desc": "稳定、低耗、76ms超低延时、全球200+数据中心覆盖;变声器、超高音质、听声辩位等丰富玩法极速接入;全平台支持:Android、iOS、Web。\n技术支持群QQ群:799099183\n", 103 | "service_title": "游戏内置实时语音", 104 | "service_guide_url": "https://docs.agora.io/cn/Interactive Gaming/game_c", 105 | "service_sample_url": "https://github.com/AgoraIO/Voice-Call-for-Mobile-Gaming/tree/master/Basic-Voice-Call-for-Gaming/Hello-CocosCreator-Voice-Agora", 106 | "service_dev_url": "https://sso.agora.io/api/oauth/cocos/login", 107 | "service_type": "3", 108 | "service_type_zh": "公司和个人游戏", 109 | "support_platform": [ 110 | "Android", 111 | "iOS", 112 | "HTML5" 113 | ], 114 | "package_download_url": "http://download.cocos.com/CocosServices/plugins/service-agora/1.0.2_2.2.3.20_2.5.2.zip", 115 | "package_version_desc": "解决Bug:onAudioVolumeIndication 回调收不到.", 116 | "service_component_name": "service-agora", 117 | "package_versions": [ 118 | "1.0.1_2.2.3.20_2.5.2", 119 | "1.0.2_2.2.3.20_2.5.2" 120 | ], 121 | "build_platform": [ 122 | "web-mobile", 123 | "web-desktop", 124 | "android", 125 | "ios" 126 | ], 127 | "require_verify": 1, 128 | "service_price": "该服务按使用量计费,计费规则,所产生的费用将由第三方从您的 Cocos 账户余额 中扣除。", 129 | "packpage_version_desc": "", 130 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》" 131 | } 132 | ], 133 | "game": { 134 | "name": "未知游戏", 135 | "appid": "UNKNOW" 136 | } 137 | } -------------------------------------------------------------------------------- /code/4/assets/Scene/未优化.fire: -------------------------------------------------------------------------------- 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 | "_objFlags": 0, 14 | "_parent": null, 15 | "_children": [ 16 | { 17 | "__id__": 2 18 | } 19 | ], 20 | "_active": false, 21 | "_level": 0, 22 | "_components": [], 23 | "_prefab": null, 24 | "_opacity": 255, 25 | "_color": { 26 | "__type__": "cc.Color", 27 | "r": 255, 28 | "g": 255, 29 | "b": 255, 30 | "a": 255 31 | }, 32 | "_contentSize": { 33 | "__type__": "cc.Size", 34 | "width": 0, 35 | "height": 0 36 | }, 37 | "_anchorPoint": { 38 | "__type__": "cc.Vec2", 39 | "x": 0, 40 | "y": 0 41 | }, 42 | "_scale": { 43 | "__type__": "cc.Vec3", 44 | "x": 1, 45 | "y": 1, 46 | "z": 1 47 | }, 48 | "_quat": { 49 | "__type__": "cc.Quat", 50 | "x": 0, 51 | "y": 0, 52 | "z": 0, 53 | "w": 1 54 | }, 55 | "_is3DNode": true, 56 | "groupIndex": 0, 57 | "autoReleaseAssets": false, 58 | "_id": "af1ce967-723d-47ac-8b86-f3546a8031f6" 59 | }, 60 | { 61 | "__type__": "cc.Node", 62 | "_name": "Canvas", 63 | "_objFlags": 0, 64 | "_parent": { 65 | "__id__": 1 66 | }, 67 | "_children": [ 68 | { 69 | "__id__": 3 70 | }, 71 | { 72 | "__id__": 5 73 | } 74 | ], 75 | "_active": true, 76 | "_level": 1, 77 | "_components": [ 78 | { 79 | "__id__": 30 80 | }, 81 | { 82 | "__id__": 31 83 | } 84 | ], 85 | "_prefab": null, 86 | "_opacity": 255, 87 | "_color": { 88 | "__type__": "cc.Color", 89 | "r": 255, 90 | "g": 255, 91 | "b": 255, 92 | "a": 255 93 | }, 94 | "_contentSize": { 95 | "__type__": "cc.Size", 96 | "width": 960, 97 | "height": 640 98 | }, 99 | "_anchorPoint": { 100 | "__type__": "cc.Vec2", 101 | "x": 0.5, 102 | "y": 0.5 103 | }, 104 | "_position": { 105 | "__type__": "cc.Vec3", 106 | "x": 480, 107 | "y": 320, 108 | "z": 0 109 | }, 110 | "_scale": { 111 | "__type__": "cc.Vec3", 112 | "x": 1, 113 | "y": 1, 114 | "z": 1 115 | }, 116 | "_quat": { 117 | "__type__": "cc.Quat", 118 | "x": 0, 119 | "y": 0, 120 | "z": 0, 121 | "w": 1 122 | }, 123 | "_skewX": 0, 124 | "_skewY": 0, 125 | "_is3DNode": false, 126 | "groupIndex": 0, 127 | "_id": "eb9YZQUdJJ76ss07dJ9wG4" 128 | }, 129 | { 130 | "__type__": "cc.Node", 131 | "_name": "Main Camera", 132 | "_objFlags": 0, 133 | "_parent": { 134 | "__id__": 2 135 | }, 136 | "_children": [], 137 | "_active": true, 138 | "_level": 1, 139 | "_components": [ 140 | { 141 | "__id__": 4 142 | } 143 | ], 144 | "_prefab": null, 145 | "_opacity": 255, 146 | "_color": { 147 | "__type__": "cc.Color", 148 | "r": 255, 149 | "g": 255, 150 | "b": 255, 151 | "a": 255 152 | }, 153 | "_contentSize": { 154 | "__type__": "cc.Size", 155 | "width": 0, 156 | "height": 0 157 | }, 158 | "_anchorPoint": { 159 | "__type__": "cc.Vec2", 160 | "x": 0.5, 161 | "y": 0.5 162 | }, 163 | "_position": { 164 | "__type__": "cc.Vec3", 165 | "x": 0, 166 | "y": 0, 167 | "z": 0 168 | }, 169 | "_scale": { 170 | "__type__": "cc.Vec3", 171 | "x": 1, 172 | "y": 1, 173 | "z": 1 174 | }, 175 | "_quat": { 176 | "__type__": "cc.Quat", 177 | "x": 0, 178 | "y": 0, 179 | "z": 0, 180 | "w": 1 181 | }, 182 | "_skewX": 0, 183 | "_skewY": 0, 184 | "_is3DNode": false, 185 | "groupIndex": 0, 186 | "_id": "0arO2lzWFLQLlw14m0xq6j" 187 | }, 188 | { 189 | "__type__": "cc.Camera", 190 | "_name": "", 191 | "_objFlags": 0, 192 | "node": { 193 | "__id__": 3 194 | }, 195 | "_enabled": true, 196 | "_cullingMask": 4294967295, 197 | "_clearFlags": 7, 198 | "_backgroundColor": { 199 | "__type__": "cc.Color", 200 | "r": 0, 201 | "g": 0, 202 | "b": 0, 203 | "a": 255 204 | }, 205 | "_depth": -1, 206 | "_zoomRatio": 1, 207 | "_targetTexture": null, 208 | "_fov": 60, 209 | "_orthoSize": 10, 210 | "_nearClip": 0.1, 211 | "_farClip": 4096, 212 | "_ortho": true, 213 | "_rect": { 214 | "__type__": "cc.Rect", 215 | "x": 0, 216 | "y": 0, 217 | "width": 1, 218 | "height": 1 219 | }, 220 | "_renderStages": 1, 221 | "_id": "d3h5ONbgJJI7i715WQLPW5" 222 | }, 223 | { 224 | "__type__": "cc.Node", 225 | "_name": "角色总结点", 226 | "_objFlags": 0, 227 | "_parent": { 228 | "__id__": 2 229 | }, 230 | "_children": [ 231 | { 232 | "__id__": 6 233 | }, 234 | { 235 | "__id__": 11 236 | }, 237 | { 238 | "__id__": 16 239 | }, 240 | { 241 | "__id__": 21 242 | } 243 | ], 244 | "_active": true, 245 | "_level": 1, 246 | "_components": [], 247 | "_prefab": null, 248 | "_opacity": 255, 249 | "_color": { 250 | "__type__": "cc.Color", 251 | "r": 255, 252 | "g": 255, 253 | "b": 255, 254 | "a": 255 255 | }, 256 | "_contentSize": { 257 | "__type__": "cc.Size", 258 | "width": 0, 259 | "height": 0 260 | }, 261 | "_anchorPoint": { 262 | "__type__": "cc.Vec2", 263 | "x": 0.5, 264 | "y": 0.5 265 | }, 266 | "_position": { 267 | "__type__": "cc.Vec3", 268 | "x": 0, 269 | "y": 0, 270 | "z": 0 271 | }, 272 | "_scale": { 273 | "__type__": "cc.Vec3", 274 | "x": 1, 275 | "y": 1, 276 | "z": 1 277 | }, 278 | "_quat": { 279 | "__type__": "cc.Quat", 280 | "x": 0, 281 | "y": 0, 282 | "z": 0, 283 | "w": 1 284 | }, 285 | "_skewX": 0, 286 | "_skewY": 0, 287 | "_is3DNode": false, 288 | "groupIndex": 0, 289 | "_id": "b5GR0/VwhPYbaNpCk/JB1Q" 290 | }, 291 | { 292 | "__type__": "cc.Node", 293 | "_name": "Player", 294 | "_objFlags": 0, 295 | "_parent": { 296 | "__id__": 5 297 | }, 298 | "_children": [ 299 | { 300 | "__id__": 7 301 | }, 302 | { 303 | "__id__": 9 304 | } 305 | ], 306 | "_active": true, 307 | "_level": 2, 308 | "_components": [], 309 | "_prefab": null, 310 | "_opacity": 255, 311 | "_color": { 312 | "__type__": "cc.Color", 313 | "r": 255, 314 | "g": 255, 315 | "b": 255, 316 | "a": 255 317 | }, 318 | "_contentSize": { 319 | "__type__": "cc.Size", 320 | "width": 0, 321 | "height": 0 322 | }, 323 | "_anchorPoint": { 324 | "__type__": "cc.Vec2", 325 | "x": 0.5, 326 | "y": 0.5 327 | }, 328 | "_position": { 329 | "__type__": "cc.Vec3", 330 | "x": -354.166, 331 | "y": 213.053, 332 | "z": 0 333 | }, 334 | "_scale": { 335 | "__type__": "cc.Vec3", 336 | "x": 0.5, 337 | "y": 0.5, 338 | "z": 0.5 339 | }, 340 | "_quat": { 341 | "__type__": "cc.Quat", 342 | "x": 0, 343 | "y": 0, 344 | "z": 0, 345 | "w": 1 346 | }, 347 | "_skewX": 0, 348 | "_skewY": 0, 349 | "_is3DNode": false, 350 | "groupIndex": 0, 351 | "_id": "59bNB84klLQ5KP/LpBsJQ4" 352 | }, 353 | { 354 | "__type__": "cc.Node", 355 | "_name": "Sprite", 356 | "_objFlags": 0, 357 | "_parent": { 358 | "__id__": 6 359 | }, 360 | "_children": [], 361 | "_active": true, 362 | "_level": 3, 363 | "_components": [ 364 | { 365 | "__id__": 8 366 | } 367 | ], 368 | "_prefab": null, 369 | "_opacity": 255, 370 | "_color": { 371 | "__type__": "cc.Color", 372 | "r": 255, 373 | "g": 255, 374 | "b": 255, 375 | "a": 255 376 | }, 377 | "_contentSize": { 378 | "__type__": "cc.Size", 379 | "width": 224, 380 | "height": 87 381 | }, 382 | "_anchorPoint": { 383 | "__type__": "cc.Vec2", 384 | "x": 0.5, 385 | "y": 0.5 386 | }, 387 | "_position": { 388 | "__type__": "cc.Vec3", 389 | "x": 0, 390 | "y": 0, 391 | "z": 0 392 | }, 393 | "_scale": { 394 | "__type__": "cc.Vec3", 395 | "x": 1, 396 | "y": 1, 397 | "z": 1 398 | }, 399 | "_quat": { 400 | "__type__": "cc.Quat", 401 | "x": 0, 402 | "y": 0, 403 | "z": 0, 404 | "w": 1 405 | }, 406 | "_skewX": 0, 407 | "_skewY": 0, 408 | "_is3DNode": false, 409 | "groupIndex": 0, 410 | "_rotationX": 0, 411 | "_rotationY": 0, 412 | "_id": "02g5kw5G5MUI4XtVtSiqdD" 413 | }, 414 | { 415 | "__type__": "cc.Sprite", 416 | "_name": "Sprite", 417 | "_objFlags": 0, 418 | "node": { 419 | "__id__": 7 420 | }, 421 | "_enabled": true, 422 | "_materials": [], 423 | "_srcBlendFactor": 770, 424 | "_dstBlendFactor": 771, 425 | "_spriteFrame": { 426 | "__uuid__": "eb612056-a425-4c2f-832a-bb31c38d3aa1" 427 | }, 428 | "_type": 0, 429 | "_sizeMode": 1, 430 | "_fillType": 0, 431 | "_fillCenter": { 432 | "__type__": "cc.Vec2", 433 | "x": 0, 434 | "y": 0 435 | }, 436 | "_fillStart": 0, 437 | "_fillRange": 0, 438 | "_isTrimmedMode": true, 439 | "_atlas": null, 440 | "_id": "ccC+hIef5LxbraSSQ7NTtZ" 441 | }, 442 | { 443 | "__type__": "cc.Node", 444 | "_name": "HP", 445 | "_objFlags": 0, 446 | "_parent": { 447 | "__id__": 6 448 | }, 449 | "_children": [], 450 | "_active": true, 451 | "_level": 3, 452 | "_components": [ 453 | { 454 | "__id__": 10 455 | } 456 | ], 457 | "_prefab": null, 458 | "_opacity": 255, 459 | "_color": { 460 | "__type__": "cc.Color", 461 | "r": 255, 462 | "g": 255, 463 | "b": 255, 464 | "a": 255 465 | }, 466 | "_contentSize": { 467 | "__type__": "cc.Size", 468 | "width": 60, 469 | "height": 15 470 | }, 471 | "_anchorPoint": { 472 | "__type__": "cc.Vec2", 473 | "x": 0.5, 474 | "y": 0.5 475 | }, 476 | "_position": { 477 | "__type__": "cc.Vec3", 478 | "x": -8, 479 | "y": 72, 480 | "z": 0 481 | }, 482 | "_scale": { 483 | "__type__": "cc.Vec3", 484 | "x": 1, 485 | "y": 1, 486 | "z": 1 487 | }, 488 | "_quat": { 489 | "__type__": "cc.Quat", 490 | "x": 0, 491 | "y": 0, 492 | "z": 0, 493 | "w": 1 494 | }, 495 | "_skewX": 0, 496 | "_skewY": 0, 497 | "_is3DNode": false, 498 | "groupIndex": 0, 499 | "_id": "082wHWntBIW7nb2z+oYnhT" 500 | }, 501 | { 502 | "__type__": "cc.Sprite", 503 | "_name": "HP", 504 | "_objFlags": 0, 505 | "node": { 506 | "__id__": 9 507 | }, 508 | "_enabled": true, 509 | "_materials": [], 510 | "_srcBlendFactor": 770, 511 | "_dstBlendFactor": 771, 512 | "_spriteFrame": { 513 | "__uuid__": "06e18442-4cee-40a1-b765-a1e246ec9c06" 514 | }, 515 | "_type": 0, 516 | "_sizeMode": 1, 517 | "_fillType": 0, 518 | "_fillCenter": { 519 | "__type__": "cc.Vec2", 520 | "x": 0, 521 | "y": 0 522 | }, 523 | "_fillStart": 0, 524 | "_fillRange": 0, 525 | "_isTrimmedMode": true, 526 | "_atlas": null, 527 | "_id": "849lBzyaZKa4USV3tkLVXd" 528 | }, 529 | { 530 | "__type__": "cc.Node", 531 | "_name": "Player", 532 | "_objFlags": 0, 533 | "_parent": { 534 | "__id__": 5 535 | }, 536 | "_children": [ 537 | { 538 | "__id__": 12 539 | }, 540 | { 541 | "__id__": 14 542 | } 543 | ], 544 | "_active": false, 545 | "_level": 2, 546 | "_components": [], 547 | "_prefab": null, 548 | "_opacity": 255, 549 | "_color": { 550 | "__type__": "cc.Color", 551 | "r": 255, 552 | "g": 255, 553 | "b": 255, 554 | "a": 255 555 | }, 556 | "_contentSize": { 557 | "__type__": "cc.Size", 558 | "width": 0, 559 | "height": 0 560 | }, 561 | "_anchorPoint": { 562 | "__type__": "cc.Vec2", 563 | "x": 0.5, 564 | "y": 0.5 565 | }, 566 | "_position": { 567 | "__type__": "cc.Vec3", 568 | "x": -354.166, 569 | "y": 213.053, 570 | "z": 0 571 | }, 572 | "_scale": { 573 | "__type__": "cc.Vec3", 574 | "x": 0.5, 575 | "y": 0.5, 576 | "z": 0.5 577 | }, 578 | "_quat": { 579 | "__type__": "cc.Quat", 580 | "x": 0, 581 | "y": 0, 582 | "z": 0, 583 | "w": 1 584 | }, 585 | "_skewX": 0, 586 | "_skewY": 0, 587 | "_is3DNode": false, 588 | "groupIndex": 0, 589 | "_id": "130sipYNNIjI09wTZJJMa0" 590 | }, 591 | { 592 | "__type__": "cc.Node", 593 | "_name": "Sprite", 594 | "_objFlags": 0, 595 | "_parent": { 596 | "__id__": 11 597 | }, 598 | "_children": [], 599 | "_active": true, 600 | "_level": 3, 601 | "_components": [ 602 | { 603 | "__id__": 13 604 | } 605 | ], 606 | "_prefab": null, 607 | "_opacity": 255, 608 | "_color": { 609 | "__type__": "cc.Color", 610 | "r": 255, 611 | "g": 255, 612 | "b": 255, 613 | "a": 255 614 | }, 615 | "_contentSize": { 616 | "__type__": "cc.Size", 617 | "width": 224, 618 | "height": 87 619 | }, 620 | "_anchorPoint": { 621 | "__type__": "cc.Vec2", 622 | "x": 0.5, 623 | "y": 0.5 624 | }, 625 | "_position": { 626 | "__type__": "cc.Vec3", 627 | "x": 0, 628 | "y": 0, 629 | "z": 0 630 | }, 631 | "_scale": { 632 | "__type__": "cc.Vec3", 633 | "x": 1, 634 | "y": 1, 635 | "z": 1 636 | }, 637 | "_quat": { 638 | "__type__": "cc.Quat", 639 | "x": 0, 640 | "y": 0, 641 | "z": 0, 642 | "w": 1 643 | }, 644 | "_skewX": 0, 645 | "_skewY": 0, 646 | "_is3DNode": false, 647 | "groupIndex": 0, 648 | "_rotationX": 0, 649 | "_rotationY": 0, 650 | "_id": "e0FBhYWXhDuLl5E7yNsl8i" 651 | }, 652 | { 653 | "__type__": "cc.Sprite", 654 | "_name": "Sprite", 655 | "_objFlags": 0, 656 | "node": { 657 | "__id__": 12 658 | }, 659 | "_enabled": true, 660 | "_materials": [], 661 | "_srcBlendFactor": 770, 662 | "_dstBlendFactor": 771, 663 | "_spriteFrame": { 664 | "__uuid__": "eb612056-a425-4c2f-832a-bb31c38d3aa1" 665 | }, 666 | "_type": 0, 667 | "_sizeMode": 1, 668 | "_fillType": 0, 669 | "_fillCenter": { 670 | "__type__": "cc.Vec2", 671 | "x": 0, 672 | "y": 0 673 | }, 674 | "_fillStart": 0, 675 | "_fillRange": 0, 676 | "_isTrimmedMode": true, 677 | "_atlas": null, 678 | "_id": "fdvZX2UchLkYtDgWmwCBFD" 679 | }, 680 | { 681 | "__type__": "cc.Node", 682 | "_name": "HP", 683 | "_objFlags": 0, 684 | "_parent": { 685 | "__id__": 11 686 | }, 687 | "_children": [], 688 | "_active": true, 689 | "_level": 3, 690 | "_components": [ 691 | { 692 | "__id__": 15 693 | } 694 | ], 695 | "_prefab": null, 696 | "_opacity": 255, 697 | "_color": { 698 | "__type__": "cc.Color", 699 | "r": 255, 700 | "g": 255, 701 | "b": 255, 702 | "a": 255 703 | }, 704 | "_contentSize": { 705 | "__type__": "cc.Size", 706 | "width": 60, 707 | "height": 15 708 | }, 709 | "_anchorPoint": { 710 | "__type__": "cc.Vec2", 711 | "x": 0.5, 712 | "y": 0.5 713 | }, 714 | "_position": { 715 | "__type__": "cc.Vec3", 716 | "x": -8, 717 | "y": 72, 718 | "z": 0 719 | }, 720 | "_scale": { 721 | "__type__": "cc.Vec3", 722 | "x": 1, 723 | "y": 1, 724 | "z": 1 725 | }, 726 | "_quat": { 727 | "__type__": "cc.Quat", 728 | "x": 0, 729 | "y": 0, 730 | "z": 0, 731 | "w": 1 732 | }, 733 | "_skewX": 0, 734 | "_skewY": 0, 735 | "_is3DNode": false, 736 | "groupIndex": 0, 737 | "_id": "d84rheJ1ZEI7WovGL8oLLK" 738 | }, 739 | { 740 | "__type__": "cc.Sprite", 741 | "_name": "HP", 742 | "_objFlags": 0, 743 | "node": { 744 | "__id__": 14 745 | }, 746 | "_enabled": true, 747 | "_materials": [], 748 | "_srcBlendFactor": 770, 749 | "_dstBlendFactor": 771, 750 | "_spriteFrame": { 751 | "__uuid__": "06e18442-4cee-40a1-b765-a1e246ec9c06" 752 | }, 753 | "_type": 0, 754 | "_sizeMode": 1, 755 | "_fillType": 0, 756 | "_fillCenter": { 757 | "__type__": "cc.Vec2", 758 | "x": 0, 759 | "y": 0 760 | }, 761 | "_fillStart": 0, 762 | "_fillRange": 0, 763 | "_isTrimmedMode": true, 764 | "_atlas": null, 765 | "_id": "f8wewj7NdMN6Z+wcP3koFA" 766 | }, 767 | { 768 | "__type__": "cc.Node", 769 | "_name": "Player", 770 | "_objFlags": 0, 771 | "_parent": { 772 | "__id__": 5 773 | }, 774 | "_children": [ 775 | { 776 | "__id__": 17 777 | }, 778 | { 779 | "__id__": 19 780 | } 781 | ], 782 | "_active": false, 783 | "_level": 2, 784 | "_components": [], 785 | "_prefab": null, 786 | "_opacity": 255, 787 | "_color": { 788 | "__type__": "cc.Color", 789 | "r": 255, 790 | "g": 255, 791 | "b": 255, 792 | "a": 255 793 | }, 794 | "_contentSize": { 795 | "__type__": "cc.Size", 796 | "width": 0, 797 | "height": 0 798 | }, 799 | "_anchorPoint": { 800 | "__type__": "cc.Vec2", 801 | "x": 0.5, 802 | "y": 0.5 803 | }, 804 | "_position": { 805 | "__type__": "cc.Vec3", 806 | "x": -354.166, 807 | "y": 213.053, 808 | "z": 0 809 | }, 810 | "_scale": { 811 | "__type__": "cc.Vec3", 812 | "x": 0.5, 813 | "y": 0.5, 814 | "z": 0.5 815 | }, 816 | "_quat": { 817 | "__type__": "cc.Quat", 818 | "x": 0, 819 | "y": 0, 820 | "z": 0, 821 | "w": 1 822 | }, 823 | "_skewX": 0, 824 | "_skewY": 0, 825 | "_is3DNode": false, 826 | "groupIndex": 0, 827 | "_id": "4dTxQ7vZZLtYB+pb9SRcXE" 828 | }, 829 | { 830 | "__type__": "cc.Node", 831 | "_name": "Sprite", 832 | "_objFlags": 0, 833 | "_parent": { 834 | "__id__": 16 835 | }, 836 | "_children": [], 837 | "_active": true, 838 | "_level": 3, 839 | "_components": [ 840 | { 841 | "__id__": 18 842 | } 843 | ], 844 | "_prefab": null, 845 | "_opacity": 255, 846 | "_color": { 847 | "__type__": "cc.Color", 848 | "r": 255, 849 | "g": 255, 850 | "b": 255, 851 | "a": 255 852 | }, 853 | "_contentSize": { 854 | "__type__": "cc.Size", 855 | "width": 224, 856 | "height": 87 857 | }, 858 | "_anchorPoint": { 859 | "__type__": "cc.Vec2", 860 | "x": 0.5, 861 | "y": 0.5 862 | }, 863 | "_position": { 864 | "__type__": "cc.Vec3", 865 | "x": 0, 866 | "y": 0, 867 | "z": 0 868 | }, 869 | "_scale": { 870 | "__type__": "cc.Vec3", 871 | "x": 1, 872 | "y": 1, 873 | "z": 1 874 | }, 875 | "_quat": { 876 | "__type__": "cc.Quat", 877 | "x": 0, 878 | "y": 0, 879 | "z": 0, 880 | "w": 1 881 | }, 882 | "_skewX": 0, 883 | "_skewY": 0, 884 | "_is3DNode": false, 885 | "groupIndex": 0, 886 | "_rotationX": 0, 887 | "_rotationY": 0, 888 | "_id": "f1swRAJbpELYHAa2axU3aX" 889 | }, 890 | { 891 | "__type__": "cc.Sprite", 892 | "_name": "Sprite", 893 | "_objFlags": 0, 894 | "node": { 895 | "__id__": 17 896 | }, 897 | "_enabled": true, 898 | "_materials": [], 899 | "_srcBlendFactor": 770, 900 | "_dstBlendFactor": 771, 901 | "_spriteFrame": { 902 | "__uuid__": "eb612056-a425-4c2f-832a-bb31c38d3aa1" 903 | }, 904 | "_type": 0, 905 | "_sizeMode": 1, 906 | "_fillType": 0, 907 | "_fillCenter": { 908 | "__type__": "cc.Vec2", 909 | "x": 0, 910 | "y": 0 911 | }, 912 | "_fillStart": 0, 913 | "_fillRange": 0, 914 | "_isTrimmedMode": true, 915 | "_atlas": null, 916 | "_id": "a6ZMhokQdJ/5QVgjq/vsd6" 917 | }, 918 | { 919 | "__type__": "cc.Node", 920 | "_name": "HP", 921 | "_objFlags": 0, 922 | "_parent": { 923 | "__id__": 16 924 | }, 925 | "_children": [], 926 | "_active": true, 927 | "_level": 3, 928 | "_components": [ 929 | { 930 | "__id__": 20 931 | } 932 | ], 933 | "_prefab": null, 934 | "_opacity": 255, 935 | "_color": { 936 | "__type__": "cc.Color", 937 | "r": 255, 938 | "g": 255, 939 | "b": 255, 940 | "a": 255 941 | }, 942 | "_contentSize": { 943 | "__type__": "cc.Size", 944 | "width": 60, 945 | "height": 15 946 | }, 947 | "_anchorPoint": { 948 | "__type__": "cc.Vec2", 949 | "x": 0.5, 950 | "y": 0.5 951 | }, 952 | "_position": { 953 | "__type__": "cc.Vec3", 954 | "x": -8, 955 | "y": 72, 956 | "z": 0 957 | }, 958 | "_scale": { 959 | "__type__": "cc.Vec3", 960 | "x": 1, 961 | "y": 1, 962 | "z": 1 963 | }, 964 | "_quat": { 965 | "__type__": "cc.Quat", 966 | "x": 0, 967 | "y": 0, 968 | "z": 0, 969 | "w": 1 970 | }, 971 | "_skewX": 0, 972 | "_skewY": 0, 973 | "_is3DNode": false, 974 | "groupIndex": 0, 975 | "_id": "37VNyxJ7VJnZVfWLhhLB+5" 976 | }, 977 | { 978 | "__type__": "cc.Sprite", 979 | "_name": "HP", 980 | "_objFlags": 0, 981 | "node": { 982 | "__id__": 19 983 | }, 984 | "_enabled": true, 985 | "_materials": [], 986 | "_srcBlendFactor": 770, 987 | "_dstBlendFactor": 771, 988 | "_spriteFrame": { 989 | "__uuid__": "06e18442-4cee-40a1-b765-a1e246ec9c06" 990 | }, 991 | "_type": 0, 992 | "_sizeMode": 1, 993 | "_fillType": 0, 994 | "_fillCenter": { 995 | "__type__": "cc.Vec2", 996 | "x": 0, 997 | "y": 0 998 | }, 999 | "_fillStart": 0, 1000 | "_fillRange": 0, 1001 | "_isTrimmedMode": true, 1002 | "_atlas": null, 1003 | "_id": "a6sfrhDERBVLJzVDWzJ6AZ" 1004 | }, 1005 | { 1006 | "__type__": "cc.Node", 1007 | "_name": "New Node", 1008 | "_objFlags": 0, 1009 | "_parent": { 1010 | "__id__": 5 1011 | }, 1012 | "_children": [ 1013 | { 1014 | "__id__": 22 1015 | }, 1016 | { 1017 | "__id__": 24 1018 | }, 1019 | { 1020 | "__id__": 26 1021 | }, 1022 | { 1023 | "__id__": 28 1024 | } 1025 | ], 1026 | "_active": false, 1027 | "_level": 2, 1028 | "_components": [], 1029 | "_prefab": null, 1030 | "_opacity": 255, 1031 | "_color": { 1032 | "__type__": "cc.Color", 1033 | "r": 255, 1034 | "g": 255, 1035 | "b": 255, 1036 | "a": 255 1037 | }, 1038 | "_contentSize": { 1039 | "__type__": "cc.Size", 1040 | "width": 0, 1041 | "height": 0 1042 | }, 1043 | "_anchorPoint": { 1044 | "__type__": "cc.Vec2", 1045 | "x": 0.5, 1046 | "y": 0.5 1047 | }, 1048 | "_position": { 1049 | "__type__": "cc.Vec3", 1050 | "x": 0, 1051 | "y": 0, 1052 | "z": 0 1053 | }, 1054 | "_scale": { 1055 | "__type__": "cc.Vec3", 1056 | "x": 1, 1057 | "y": 1, 1058 | "z": 1 1059 | }, 1060 | "_quat": { 1061 | "__type__": "cc.Quat", 1062 | "x": 0, 1063 | "y": 0, 1064 | "z": 0, 1065 | "w": 1 1066 | }, 1067 | "_skewX": 0, 1068 | "_skewY": 0, 1069 | "_is3DNode": false, 1070 | "groupIndex": 0, 1071 | "_id": "9czABPmttFE7wzlC4qj4KT" 1072 | }, 1073 | { 1074 | "__type__": "cc.Node", 1075 | "_name": "New Label", 1076 | "_objFlags": 0, 1077 | "_parent": { 1078 | "__id__": 21 1079 | }, 1080 | "_children": [], 1081 | "_active": true, 1082 | "_level": 3, 1083 | "_components": [ 1084 | { 1085 | "__id__": 23 1086 | } 1087 | ], 1088 | "_prefab": null, 1089 | "_opacity": 255, 1090 | "_color": { 1091 | "__type__": "cc.Color", 1092 | "r": 255, 1093 | "g": 255, 1094 | "b": 255, 1095 | "a": 255 1096 | }, 1097 | "_contentSize": { 1098 | "__type__": "cc.Size", 1099 | "width": 97.87, 1100 | "height": 50.4 1101 | }, 1102 | "_anchorPoint": { 1103 | "__type__": "cc.Vec2", 1104 | "x": 0.5, 1105 | "y": 0.5 1106 | }, 1107 | "_position": { 1108 | "__type__": "cc.Vec3", 1109 | "x": -363.166, 1110 | "y": 269.053, 1111 | "z": 0 1112 | }, 1113 | "_scale": { 1114 | "__type__": "cc.Vec3", 1115 | "x": 0.5, 1116 | "y": 0.5, 1117 | "z": 0.5 1118 | }, 1119 | "_quat": { 1120 | "__type__": "cc.Quat", 1121 | "x": 0, 1122 | "y": 0, 1123 | "z": 0, 1124 | "w": 1 1125 | }, 1126 | "_skewX": 0, 1127 | "_skewY": 0, 1128 | "_is3DNode": false, 1129 | "groupIndex": 0, 1130 | "_rotationX": 0, 1131 | "_rotationY": 0, 1132 | "_id": "d4dcPoYINLap6FsCmgM1or" 1133 | }, 1134 | { 1135 | "__type__": "cc.Label", 1136 | "_name": "", 1137 | "_objFlags": 0, 1138 | "node": { 1139 | "__id__": 22 1140 | }, 1141 | "_enabled": true, 1142 | "_materials": [], 1143 | "_useOriginalSize": false, 1144 | "_string": "Label", 1145 | "_N$string": "Label", 1146 | "_fontSize": 40, 1147 | "_lineHeight": 40, 1148 | "_enableWrapText": true, 1149 | "_N$file": null, 1150 | "_isSystemFontUsed": true, 1151 | "_spacingX": 0, 1152 | "_batchAsBitmap": false, 1153 | "_N$horizontalAlign": 1, 1154 | "_N$verticalAlign": 1, 1155 | "_N$fontFamily": "Arial", 1156 | "_N$overflow": 0, 1157 | "_N$cacheMode": 0, 1158 | "_id": "2aI6nRFYxAw6VzxEocSfgh" 1159 | }, 1160 | { 1161 | "__type__": "cc.Node", 1162 | "_name": "New Label", 1163 | "_objFlags": 0, 1164 | "_parent": { 1165 | "__id__": 21 1166 | }, 1167 | "_children": [], 1168 | "_active": true, 1169 | "_level": 3, 1170 | "_components": [ 1171 | { 1172 | "__id__": 25 1173 | } 1174 | ], 1175 | "_prefab": null, 1176 | "_opacity": 255, 1177 | "_color": { 1178 | "__type__": "cc.Color", 1179 | "r": 255, 1180 | "g": 255, 1181 | "b": 255, 1182 | "a": 255 1183 | }, 1184 | "_contentSize": { 1185 | "__type__": "cc.Size", 1186 | "width": 97.87, 1187 | "height": 50.4 1188 | }, 1189 | "_anchorPoint": { 1190 | "__type__": "cc.Vec2", 1191 | "x": 0.5, 1192 | "y": 0.5 1193 | }, 1194 | "_position": { 1195 | "__type__": "cc.Vec3", 1196 | "x": -363.166, 1197 | "y": 269.053, 1198 | "z": 0 1199 | }, 1200 | "_scale": { 1201 | "__type__": "cc.Vec3", 1202 | "x": 0.5, 1203 | "y": 0.5, 1204 | "z": 0.5 1205 | }, 1206 | "_quat": { 1207 | "__type__": "cc.Quat", 1208 | "x": 0, 1209 | "y": 0, 1210 | "z": 0, 1211 | "w": 1 1212 | }, 1213 | "_skewX": 0, 1214 | "_skewY": 0, 1215 | "_is3DNode": false, 1216 | "groupIndex": 0, 1217 | "_rotationX": 0, 1218 | "_rotationY": 0, 1219 | "_id": "75m7kF3otMurRu8umXvxjr" 1220 | }, 1221 | { 1222 | "__type__": "cc.Label", 1223 | "_name": "", 1224 | "_objFlags": 0, 1225 | "node": { 1226 | "__id__": 24 1227 | }, 1228 | "_enabled": true, 1229 | "_materials": [], 1230 | "_useOriginalSize": false, 1231 | "_string": "Label", 1232 | "_N$string": "Label", 1233 | "_fontSize": 40, 1234 | "_lineHeight": 40, 1235 | "_enableWrapText": true, 1236 | "_N$file": null, 1237 | "_isSystemFontUsed": true, 1238 | "_spacingX": 0, 1239 | "_batchAsBitmap": false, 1240 | "_N$horizontalAlign": 1, 1241 | "_N$verticalAlign": 1, 1242 | "_N$fontFamily": "Arial", 1243 | "_N$overflow": 0, 1244 | "_N$cacheMode": 0, 1245 | "_id": "03lVIqgHJNUIX+w/KFgyeb" 1246 | }, 1247 | { 1248 | "__type__": "cc.Node", 1249 | "_name": "New Label", 1250 | "_objFlags": 0, 1251 | "_parent": { 1252 | "__id__": 21 1253 | }, 1254 | "_children": [], 1255 | "_active": true, 1256 | "_level": 3, 1257 | "_components": [ 1258 | { 1259 | "__id__": 27 1260 | } 1261 | ], 1262 | "_prefab": null, 1263 | "_opacity": 255, 1264 | "_color": { 1265 | "__type__": "cc.Color", 1266 | "r": 255, 1267 | "g": 255, 1268 | "b": 255, 1269 | "a": 255 1270 | }, 1271 | "_contentSize": { 1272 | "__type__": "cc.Size", 1273 | "width": 97.87, 1274 | "height": 50.4 1275 | }, 1276 | "_anchorPoint": { 1277 | "__type__": "cc.Vec2", 1278 | "x": 0.5, 1279 | "y": 0.5 1280 | }, 1281 | "_position": { 1282 | "__type__": "cc.Vec3", 1283 | "x": -363.166, 1284 | "y": 269.053, 1285 | "z": 0 1286 | }, 1287 | "_scale": { 1288 | "__type__": "cc.Vec3", 1289 | "x": 0.5, 1290 | "y": 0.5, 1291 | "z": 0.5 1292 | }, 1293 | "_quat": { 1294 | "__type__": "cc.Quat", 1295 | "x": 0, 1296 | "y": 0, 1297 | "z": 0, 1298 | "w": 1 1299 | }, 1300 | "_skewX": 0, 1301 | "_skewY": 0, 1302 | "_is3DNode": false, 1303 | "groupIndex": 0, 1304 | "_rotationX": 0, 1305 | "_rotationY": 0, 1306 | "_id": "29Hi3OompM8r4x7Zv4uvnJ" 1307 | }, 1308 | { 1309 | "__type__": "cc.Label", 1310 | "_name": "", 1311 | "_objFlags": 0, 1312 | "node": { 1313 | "__id__": 26 1314 | }, 1315 | "_enabled": true, 1316 | "_materials": [], 1317 | "_useOriginalSize": false, 1318 | "_string": "Label", 1319 | "_N$string": "Label", 1320 | "_fontSize": 40, 1321 | "_lineHeight": 40, 1322 | "_enableWrapText": true, 1323 | "_N$file": null, 1324 | "_isSystemFontUsed": true, 1325 | "_spacingX": 0, 1326 | "_batchAsBitmap": false, 1327 | "_N$horizontalAlign": 1, 1328 | "_N$verticalAlign": 1, 1329 | "_N$fontFamily": "Arial", 1330 | "_N$overflow": 0, 1331 | "_N$cacheMode": 0, 1332 | "_id": "94RMDNvVRDdrUpNs9VeMII" 1333 | }, 1334 | { 1335 | "__type__": "cc.Node", 1336 | "_name": "New Label", 1337 | "_objFlags": 0, 1338 | "_parent": { 1339 | "__id__": 21 1340 | }, 1341 | "_children": [], 1342 | "_active": true, 1343 | "_level": 3, 1344 | "_components": [ 1345 | { 1346 | "__id__": 29 1347 | } 1348 | ], 1349 | "_prefab": null, 1350 | "_opacity": 255, 1351 | "_color": { 1352 | "__type__": "cc.Color", 1353 | "r": 255, 1354 | "g": 255, 1355 | "b": 255, 1356 | "a": 255 1357 | }, 1358 | "_contentSize": { 1359 | "__type__": "cc.Size", 1360 | "width": 97.87, 1361 | "height": 50.4 1362 | }, 1363 | "_anchorPoint": { 1364 | "__type__": "cc.Vec2", 1365 | "x": 0.5, 1366 | "y": 0.5 1367 | }, 1368 | "_position": { 1369 | "__type__": "cc.Vec3", 1370 | "x": -363.166, 1371 | "y": 269.053, 1372 | "z": 0 1373 | }, 1374 | "_scale": { 1375 | "__type__": "cc.Vec3", 1376 | "x": 0.5, 1377 | "y": 0.5, 1378 | "z": 0.5 1379 | }, 1380 | "_quat": { 1381 | "__type__": "cc.Quat", 1382 | "x": 0, 1383 | "y": 0, 1384 | "z": 0, 1385 | "w": 1 1386 | }, 1387 | "_skewX": 0, 1388 | "_skewY": 0, 1389 | "_is3DNode": false, 1390 | "groupIndex": 0, 1391 | "_rotationX": 0, 1392 | "_rotationY": 0, 1393 | "_id": "39yNkuyWVPNpTtufrCHEAr" 1394 | }, 1395 | { 1396 | "__type__": "cc.Label", 1397 | "_name": "", 1398 | "_objFlags": 0, 1399 | "node": { 1400 | "__id__": 28 1401 | }, 1402 | "_enabled": true, 1403 | "_materials": [], 1404 | "_useOriginalSize": false, 1405 | "_string": "Label", 1406 | "_N$string": "Label", 1407 | "_fontSize": 40, 1408 | "_lineHeight": 40, 1409 | "_enableWrapText": true, 1410 | "_N$file": null, 1411 | "_isSystemFontUsed": true, 1412 | "_spacingX": 0, 1413 | "_batchAsBitmap": false, 1414 | "_N$horizontalAlign": 1, 1415 | "_N$verticalAlign": 1, 1416 | "_N$fontFamily": "Arial", 1417 | "_N$overflow": 0, 1418 | "_N$cacheMode": 0, 1419 | "_id": "abTfJfLUxCS5Wz2pw1x0FS" 1420 | }, 1421 | { 1422 | "__type__": "cc.Canvas", 1423 | "_name": "", 1424 | "_objFlags": 0, 1425 | "node": { 1426 | "__id__": 2 1427 | }, 1428 | "_enabled": true, 1429 | "_designResolution": { 1430 | "__type__": "cc.Size", 1431 | "width": 960, 1432 | "height": 640 1433 | }, 1434 | "_fitWidth": false, 1435 | "_fitHeight": true, 1436 | "_id": "1cHNp95phJPZv4133pc9B5" 1437 | }, 1438 | { 1439 | "__type__": "e88f9SYMP9OobFG4PeNEURX", 1440 | "_name": "", 1441 | "_objFlags": 0, 1442 | "node": { 1443 | "__id__": 2 1444 | }, 1445 | "_enabled": true, 1446 | "_id": "49wElqciVMsL6/wF2527tr" 1447 | } 1448 | ] -------------------------------------------------------------------------------- /code/2/assets/Scene/Main.fire: -------------------------------------------------------------------------------- 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 | "_objFlags": 0, 14 | "_parent": null, 15 | "_children": [ 16 | { 17 | "__id__": 2 18 | }, 19 | { 20 | "__id__": 6 21 | } 22 | ], 23 | "_active": true, 24 | "_level": 0, 25 | "_components": [], 26 | "_prefab": null, 27 | "_opacity": 255, 28 | "_color": { 29 | "__type__": "cc.Color", 30 | "r": 255, 31 | "g": 255, 32 | "b": 255, 33 | "a": 255 34 | }, 35 | "_contentSize": { 36 | "__type__": "cc.Size", 37 | "width": 0, 38 | "height": 0 39 | }, 40 | "_anchorPoint": { 41 | "__type__": "cc.Vec2", 42 | "x": 0, 43 | "y": 0 44 | }, 45 | "_scale": { 46 | "__type__": "cc.Vec3", 47 | "x": 1, 48 | "y": 1, 49 | "z": 1 50 | }, 51 | "_quat": { 52 | "__type__": "cc.Quat", 53 | "x": 0, 54 | "y": 0, 55 | "z": 0, 56 | "w": 1 57 | }, 58 | "_is3DNode": true, 59 | "groupIndex": 0, 60 | "autoReleaseAssets": false, 61 | "_id": "2b344c0a-e213-4a1a-b7a7-07a98787b837" 62 | }, 63 | { 64 | "__type__": "cc.Node", 65 | "_name": "UIManager", 66 | "_objFlags": 0, 67 | "_parent": { 68 | "__id__": 1 69 | }, 70 | "_children": [], 71 | "_active": true, 72 | "_level": 1, 73 | "_components": [ 74 | { 75 | "__id__": 3 76 | } 77 | ], 78 | "_prefab": null, 79 | "_opacity": 255, 80 | "_color": { 81 | "__type__": "cc.Color", 82 | "r": 255, 83 | "g": 255, 84 | "b": 255, 85 | "a": 255 86 | }, 87 | "_contentSize": { 88 | "__type__": "cc.Size", 89 | "width": 0, 90 | "height": 0 91 | }, 92 | "_anchorPoint": { 93 | "__type__": "cc.Vec2", 94 | "x": 0.5, 95 | "y": 0.5 96 | }, 97 | "_position": { 98 | "__type__": "cc.Vec3", 99 | "x": 320, 100 | "y": 568, 101 | "z": 0 102 | }, 103 | "_scale": { 104 | "__type__": "cc.Vec3", 105 | "x": 1, 106 | "y": 1, 107 | "z": 1 108 | }, 109 | "_quat": { 110 | "__type__": "cc.Quat", 111 | "x": 0, 112 | "y": 0, 113 | "z": 0, 114 | "w": 1 115 | }, 116 | "_skewX": 0, 117 | "_skewY": 0, 118 | "_is3DNode": false, 119 | "groupIndex": 0, 120 | "_id": "cfKmfBpLFOMKBrKdfUowom" 121 | }, 122 | { 123 | "__type__": "7b30fSjPfpIxIdTQ0n+MZ3W", 124 | "_name": "", 125 | "_objFlags": 0, 126 | "node": { 127 | "__id__": 2 128 | }, 129 | "_enabled": true, 130 | "ui1": { 131 | "__id__": 4 132 | }, 133 | "_id": "74xrf3Xl9EI4hCnljcprrX" 134 | }, 135 | { 136 | "__type__": "cc.Node", 137 | "_name": "UI1", 138 | "_objFlags": 0, 139 | "_parent": { 140 | "__id__": 5 141 | }, 142 | "_children": [ 143 | { 144 | "__id__": 20 145 | }, 146 | { 147 | "__id__": 22 148 | }, 149 | { 150 | "__id__": 24 151 | }, 152 | { 153 | "__id__": 26 154 | }, 155 | { 156 | "__id__": 34 157 | } 158 | ], 159 | "_active": false, 160 | "_level": 3, 161 | "_components": [ 162 | { 163 | "__id__": 42 164 | } 165 | ], 166 | "_prefab": null, 167 | "_opacity": 255, 168 | "_color": { 169 | "__type__": "cc.Color", 170 | "r": 255, 171 | "g": 255, 172 | "b": 255, 173 | "a": 255 174 | }, 175 | "_contentSize": { 176 | "__type__": "cc.Size", 177 | "width": 0, 178 | "height": 0 179 | }, 180 | "_anchorPoint": { 181 | "__type__": "cc.Vec2", 182 | "x": 0.5, 183 | "y": 0.5 184 | }, 185 | "_position": { 186 | "__type__": "cc.Vec3", 187 | "x": 0, 188 | "y": 0, 189 | "z": 0 190 | }, 191 | "_scale": { 192 | "__type__": "cc.Vec3", 193 | "x": 1, 194 | "y": 1, 195 | "z": 1 196 | }, 197 | "_quat": { 198 | "__type__": "cc.Quat", 199 | "x": 0, 200 | "y": 0, 201 | "z": 0, 202 | "w": 1 203 | }, 204 | "_skewX": 0, 205 | "_skewY": 0, 206 | "_is3DNode": false, 207 | "groupIndex": 0, 208 | "_id": "6fZa6czmNEE6REHkBVsNbc" 209 | }, 210 | { 211 | "__type__": "cc.Node", 212 | "_name": "UI", 213 | "_objFlags": 0, 214 | "_parent": { 215 | "__id__": 6 216 | }, 217 | "_children": [ 218 | { 219 | "__id__": 10 220 | }, 221 | { 222 | "__id__": 4 223 | } 224 | ], 225 | "_active": true, 226 | "_level": 2, 227 | "_components": [], 228 | "_prefab": null, 229 | "_opacity": 255, 230 | "_color": { 231 | "__type__": "cc.Color", 232 | "r": 255, 233 | "g": 255, 234 | "b": 255, 235 | "a": 255 236 | }, 237 | "_contentSize": { 238 | "__type__": "cc.Size", 239 | "width": 0, 240 | "height": 0 241 | }, 242 | "_anchorPoint": { 243 | "__type__": "cc.Vec2", 244 | "x": 0.5, 245 | "y": 0.5 246 | }, 247 | "_position": { 248 | "__type__": "cc.Vec3", 249 | "x": 0, 250 | "y": 0, 251 | "z": 0 252 | }, 253 | "_scale": { 254 | "__type__": "cc.Vec3", 255 | "x": 1, 256 | "y": 1, 257 | "z": 1 258 | }, 259 | "_quat": { 260 | "__type__": "cc.Quat", 261 | "x": 0, 262 | "y": 0, 263 | "z": 0, 264 | "w": 1 265 | }, 266 | "_skewX": 0, 267 | "_skewY": 0, 268 | "_is3DNode": false, 269 | "groupIndex": 0, 270 | "_id": "01r/VaN35ON5qcBaNroGy2" 271 | }, 272 | { 273 | "__type__": "cc.Node", 274 | "_name": "Canvas", 275 | "_objFlags": 0, 276 | "_parent": { 277 | "__id__": 1 278 | }, 279 | "_children": [ 280 | { 281 | "__id__": 7 282 | }, 283 | { 284 | "__id__": 5 285 | } 286 | ], 287 | "_active": true, 288 | "_level": 1, 289 | "_components": [ 290 | { 291 | "__id__": 9 292 | } 293 | ], 294 | "_prefab": null, 295 | "_opacity": 255, 296 | "_color": { 297 | "__type__": "cc.Color", 298 | "r": 255, 299 | "g": 255, 300 | "b": 255, 301 | "a": 255 302 | }, 303 | "_contentSize": { 304 | "__type__": "cc.Size", 305 | "width": 640, 306 | "height": 1136 307 | }, 308 | "_anchorPoint": { 309 | "__type__": "cc.Vec2", 310 | "x": 0.5, 311 | "y": 0.5 312 | }, 313 | "_position": { 314 | "__type__": "cc.Vec3", 315 | "x": 320, 316 | "y": 568, 317 | "z": 0 318 | }, 319 | "_scale": { 320 | "__type__": "cc.Vec3", 321 | "x": 1, 322 | "y": 1, 323 | "z": 1 324 | }, 325 | "_quat": { 326 | "__type__": "cc.Quat", 327 | "x": 0, 328 | "y": 0, 329 | "z": 0, 330 | "w": 1 331 | }, 332 | "_skewX": 0, 333 | "_skewY": 0, 334 | "_is3DNode": false, 335 | "groupIndex": 0, 336 | "_id": "fdLllam0JLX7tSzZqXwLF0" 337 | }, 338 | { 339 | "__type__": "cc.Node", 340 | "_name": "Main Camera", 341 | "_objFlags": 0, 342 | "_parent": { 343 | "__id__": 6 344 | }, 345 | "_children": [], 346 | "_active": true, 347 | "_level": 2, 348 | "_components": [ 349 | { 350 | "__id__": 8 351 | } 352 | ], 353 | "_prefab": null, 354 | "_opacity": 255, 355 | "_color": { 356 | "__type__": "cc.Color", 357 | "r": 255, 358 | "g": 255, 359 | "b": 255, 360 | "a": 255 361 | }, 362 | "_contentSize": { 363 | "__type__": "cc.Size", 364 | "width": 0, 365 | "height": 0 366 | }, 367 | "_anchorPoint": { 368 | "__type__": "cc.Vec2", 369 | "x": 0.5, 370 | "y": 0.5 371 | }, 372 | "_position": { 373 | "__type__": "cc.Vec3", 374 | "x": 0, 375 | "y": 0, 376 | "z": 0 377 | }, 378 | "_scale": { 379 | "__type__": "cc.Vec3", 380 | "x": 1, 381 | "y": 1, 382 | "z": 1 383 | }, 384 | "_quat": { 385 | "__type__": "cc.Quat", 386 | "x": 0, 387 | "y": 0, 388 | "z": 0, 389 | "w": 1 390 | }, 391 | "_skewX": 0, 392 | "_skewY": 0, 393 | "_is3DNode": false, 394 | "groupIndex": 0, 395 | "_id": "05fGqhfhJLELi/Fgm8NJtT" 396 | }, 397 | { 398 | "__type__": "cc.Camera", 399 | "_name": "", 400 | "_objFlags": 0, 401 | "node": { 402 | "__id__": 7 403 | }, 404 | "_enabled": true, 405 | "_cullingMask": 4294967295, 406 | "_clearFlags": 7, 407 | "_backgroundColor": { 408 | "__type__": "cc.Color", 409 | "r": 0, 410 | "g": 0, 411 | "b": 0, 412 | "a": 255 413 | }, 414 | "_depth": -1, 415 | "_zoomRatio": 1, 416 | "_targetTexture": null, 417 | "_fov": 60, 418 | "_orthoSize": 10, 419 | "_nearClip": 0.1, 420 | "_farClip": 4096, 421 | "_ortho": true, 422 | "_rect": { 423 | "__type__": "cc.Rect", 424 | "x": 0, 425 | "y": 0, 426 | "width": 1, 427 | "height": 1 428 | }, 429 | "_renderStages": 1, 430 | "_id": "dcUlz662BAqaBJUrf0uQ2t" 431 | }, 432 | { 433 | "__type__": "cc.Canvas", 434 | "_name": "", 435 | "_objFlags": 0, 436 | "node": { 437 | "__id__": 6 438 | }, 439 | "_enabled": true, 440 | "_designResolution": { 441 | "__type__": "cc.Size", 442 | "width": 640, 443 | "height": 1136 444 | }, 445 | "_fitWidth": true, 446 | "_fitHeight": false, 447 | "_id": "29IozydWBOebzH2bWlJTUT" 448 | }, 449 | { 450 | "__type__": "cc.Node", 451 | "_name": "MainUI", 452 | "_objFlags": 0, 453 | "_parent": { 454 | "__id__": 5 455 | }, 456 | "_children": [ 457 | { 458 | "__id__": 11 459 | } 460 | ], 461 | "_active": true, 462 | "_level": 3, 463 | "_components": [ 464 | { 465 | "__id__": 19 466 | } 467 | ], 468 | "_prefab": null, 469 | "_opacity": 255, 470 | "_color": { 471 | "__type__": "cc.Color", 472 | "r": 255, 473 | "g": 255, 474 | "b": 255, 475 | "a": 255 476 | }, 477 | "_contentSize": { 478 | "__type__": "cc.Size", 479 | "width": 0, 480 | "height": 0 481 | }, 482 | "_anchorPoint": { 483 | "__type__": "cc.Vec2", 484 | "x": 0.5, 485 | "y": 0.5 486 | }, 487 | "_position": { 488 | "__type__": "cc.Vec3", 489 | "x": 0, 490 | "y": 0, 491 | "z": 0 492 | }, 493 | "_scale": { 494 | "__type__": "cc.Vec3", 495 | "x": 1, 496 | "y": 1, 497 | "z": 1 498 | }, 499 | "_quat": { 500 | "__type__": "cc.Quat", 501 | "x": 0, 502 | "y": 0, 503 | "z": 0, 504 | "w": 1 505 | }, 506 | "_skewX": 0, 507 | "_skewY": 0, 508 | "_is3DNode": false, 509 | "groupIndex": 0, 510 | "_id": "991AQhZvJJGpto/SKujY4A" 511 | }, 512 | { 513 | "__type__": "cc.Node", 514 | "_name": "Btn1", 515 | "_objFlags": 0, 516 | "_parent": { 517 | "__id__": 10 518 | }, 519 | "_children": [ 520 | { 521 | "__id__": 12 522 | } 523 | ], 524 | "_active": true, 525 | "_level": 4, 526 | "_components": [ 527 | { 528 | "__id__": 17 529 | } 530 | ], 531 | "_prefab": null, 532 | "_opacity": 255, 533 | "_color": { 534 | "__type__": "cc.Color", 535 | "r": 255, 536 | "g": 255, 537 | "b": 255, 538 | "a": 255 539 | }, 540 | "_contentSize": { 541 | "__type__": "cc.Size", 542 | "width": 100, 543 | "height": 40 544 | }, 545 | "_anchorPoint": { 546 | "__type__": "cc.Vec2", 547 | "x": 0.5, 548 | "y": 0.5 549 | }, 550 | "_position": { 551 | "__type__": "cc.Vec3", 552 | "x": 0, 553 | "y": 0, 554 | "z": 0 555 | }, 556 | "_scale": { 557 | "__type__": "cc.Vec3", 558 | "x": 1, 559 | "y": 1, 560 | "z": 1 561 | }, 562 | "_quat": { 563 | "__type__": "cc.Quat", 564 | "x": 0, 565 | "y": 0, 566 | "z": 0, 567 | "w": 1 568 | }, 569 | "_skewX": 0, 570 | "_skewY": 0, 571 | "_is3DNode": false, 572 | "groupIndex": 0, 573 | "_rotationX": 0, 574 | "_rotationY": 0, 575 | "_id": "9fLO/HS0FEQqGPepD+u7Ug" 576 | }, 577 | { 578 | "__type__": "cc.Node", 579 | "_name": "Background", 580 | "_objFlags": 0, 581 | "_parent": { 582 | "__id__": 11 583 | }, 584 | "_children": [ 585 | { 586 | "__id__": 13 587 | } 588 | ], 589 | "_active": true, 590 | "_level": 2, 591 | "_components": [ 592 | { 593 | "__id__": 15 594 | }, 595 | { 596 | "__id__": 16 597 | } 598 | ], 599 | "_prefab": null, 600 | "_opacity": 255, 601 | "_color": { 602 | "__type__": "cc.Color", 603 | "r": 230, 604 | "g": 230, 605 | "b": 230, 606 | "a": 255 607 | }, 608 | "_contentSize": { 609 | "__type__": "cc.Size", 610 | "width": 100, 611 | "height": 40 612 | }, 613 | "_anchorPoint": { 614 | "__type__": "cc.Vec2", 615 | "x": 0.5, 616 | "y": 0.5 617 | }, 618 | "_position": { 619 | "__type__": "cc.Vec3", 620 | "x": 0, 621 | "y": 0, 622 | "z": 0 623 | }, 624 | "_scale": { 625 | "__type__": "cc.Vec3", 626 | "x": 1, 627 | "y": 1, 628 | "z": 1 629 | }, 630 | "_quat": { 631 | "__type__": "cc.Quat", 632 | "x": 0, 633 | "y": 0, 634 | "z": 0, 635 | "w": 1 636 | }, 637 | "_skewX": 0, 638 | "_skewY": 0, 639 | "_is3DNode": false, 640 | "groupIndex": 0, 641 | "_rotationX": 0, 642 | "_rotationY": 0, 643 | "_id": "84vNfctrNB0ZOfwZofxwX1" 644 | }, 645 | { 646 | "__type__": "cc.Node", 647 | "_name": "Label", 648 | "_objFlags": 0, 649 | "_parent": { 650 | "__id__": 12 651 | }, 652 | "_children": [], 653 | "_active": true, 654 | "_level": 3, 655 | "_components": [ 656 | { 657 | "__id__": 14 658 | } 659 | ], 660 | "_prefab": null, 661 | "_opacity": 255, 662 | "_color": { 663 | "__type__": "cc.Color", 664 | "r": 0, 665 | "g": 0, 666 | "b": 0, 667 | "a": 255 668 | }, 669 | "_contentSize": { 670 | "__type__": "cc.Size", 671 | "width": 100, 672 | "height": 40 673 | }, 674 | "_anchorPoint": { 675 | "__type__": "cc.Vec2", 676 | "x": 0.5, 677 | "y": 0.5 678 | }, 679 | "_position": { 680 | "__type__": "cc.Vec3", 681 | "x": 0, 682 | "y": 0, 683 | "z": 0 684 | }, 685 | "_scale": { 686 | "__type__": "cc.Vec3", 687 | "x": 1, 688 | "y": 1, 689 | "z": 1 690 | }, 691 | "_quat": { 692 | "__type__": "cc.Quat", 693 | "x": 0, 694 | "y": 0, 695 | "z": 0, 696 | "w": 1 697 | }, 698 | "_skewX": 0, 699 | "_skewY": 0, 700 | "_is3DNode": false, 701 | "groupIndex": 0, 702 | "_rotationX": 0, 703 | "_rotationY": 0, 704 | "_id": "685KY+qBVAspE3orLDgi0z" 705 | }, 706 | { 707 | "__type__": "cc.Label", 708 | "_name": "", 709 | "_objFlags": 0, 710 | "node": { 711 | "__id__": 13 712 | }, 713 | "_enabled": true, 714 | "_materials": [], 715 | "_useOriginalSize": false, 716 | "_string": "显示UI1", 717 | "_N$string": "显示UI1", 718 | "_fontSize": 20, 719 | "_lineHeight": 40, 720 | "_enableWrapText": false, 721 | "_N$file": null, 722 | "_isSystemFontUsed": true, 723 | "_spacingX": 0, 724 | "_batchAsBitmap": false, 725 | "_N$horizontalAlign": 1, 726 | "_N$verticalAlign": 1, 727 | "_N$fontFamily": "Arial", 728 | "_N$overflow": 1, 729 | "_N$cacheMode": 0, 730 | "_id": "daKip+Z+dOFoyHWqhoRbmn" 731 | }, 732 | { 733 | "__type__": "cc.Sprite", 734 | "_name": "", 735 | "_objFlags": 0, 736 | "node": { 737 | "__id__": 12 738 | }, 739 | "_enabled": true, 740 | "_materials": [], 741 | "_srcBlendFactor": 770, 742 | "_dstBlendFactor": 771, 743 | "_spriteFrame": { 744 | "__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952" 745 | }, 746 | "_type": 1, 747 | "_sizeMode": 0, 748 | "_fillType": 0, 749 | "_fillCenter": { 750 | "__type__": "cc.Vec2", 751 | "x": 0, 752 | "y": 0 753 | }, 754 | "_fillStart": 0, 755 | "_fillRange": 0, 756 | "_isTrimmedMode": true, 757 | "_atlas": null, 758 | "_id": "35g1oclZpFN7ksfqBHn4bH" 759 | }, 760 | { 761 | "__type__": "cc.Widget", 762 | "_name": "", 763 | "_objFlags": 0, 764 | "node": { 765 | "__id__": 12 766 | }, 767 | "_enabled": true, 768 | "alignMode": 0, 769 | "_target": null, 770 | "_alignFlags": 45, 771 | "_left": 0, 772 | "_right": 0, 773 | "_top": 0, 774 | "_bottom": 0, 775 | "_verticalCenter": 0, 776 | "_horizontalCenter": 0, 777 | "_isAbsLeft": true, 778 | "_isAbsRight": true, 779 | "_isAbsTop": true, 780 | "_isAbsBottom": true, 781 | "_isAbsHorizontalCenter": true, 782 | "_isAbsVerticalCenter": true, 783 | "_originalWidth": 100, 784 | "_originalHeight": 40, 785 | "_id": "a1O64bkP5BH5eSMiH/cjwp" 786 | }, 787 | { 788 | "__type__": "cc.Button", 789 | "_name": "", 790 | "_objFlags": 0, 791 | "node": { 792 | "__id__": 11 793 | }, 794 | "_enabled": true, 795 | "duration": 0.1, 796 | "zoomScale": 1.2, 797 | "clickEvents": [ 798 | { 799 | "__id__": 18 800 | } 801 | ], 802 | "_N$interactable": true, 803 | "_N$enableAutoGrayEffect": false, 804 | "_N$transition": 2, 805 | "transition": 2, 806 | "_N$normalColor": { 807 | "__type__": "cc.Color", 808 | "r": 230, 809 | "g": 230, 810 | "b": 230, 811 | "a": 255 812 | }, 813 | "_N$pressedColor": { 814 | "__type__": "cc.Color", 815 | "r": 200, 816 | "g": 200, 817 | "b": 200, 818 | "a": 255 819 | }, 820 | "pressedColor": { 821 | "__type__": "cc.Color", 822 | "r": 200, 823 | "g": 200, 824 | "b": 200, 825 | "a": 255 826 | }, 827 | "_N$hoverColor": { 828 | "__type__": "cc.Color", 829 | "r": 255, 830 | "g": 255, 831 | "b": 255, 832 | "a": 255 833 | }, 834 | "hoverColor": { 835 | "__type__": "cc.Color", 836 | "r": 255, 837 | "g": 255, 838 | "b": 255, 839 | "a": 255 840 | }, 841 | "_N$disabledColor": { 842 | "__type__": "cc.Color", 843 | "r": 120, 844 | "g": 120, 845 | "b": 120, 846 | "a": 200 847 | }, 848 | "_N$normalSprite": { 849 | "__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952" 850 | }, 851 | "_N$pressedSprite": { 852 | "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" 853 | }, 854 | "pressedSprite": { 855 | "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" 856 | }, 857 | "_N$hoverSprite": { 858 | "__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952" 859 | }, 860 | "hoverSprite": { 861 | "__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952" 862 | }, 863 | "_N$disabledSprite": { 864 | "__uuid__": "29158224-f8dd-4661-a796-1ffab537140e" 865 | }, 866 | "_N$target": { 867 | "__id__": 12 868 | }, 869 | "_id": "e6rHtwpoRPJZ8uVIaywFom" 870 | }, 871 | { 872 | "__type__": "cc.ClickEvent", 873 | "target": { 874 | "__id__": 2 875 | }, 876 | "component": "", 877 | "_componentId": "7b30fSjPfpIxIdTQ0n+MZ3W", 878 | "handler": "showUI1", 879 | "customEventData": "" 880 | }, 881 | { 882 | "__type__": "64d1dBfXYxBTo/D0ybqYJ+R", 883 | "_name": "", 884 | "_objFlags": 0, 885 | "node": { 886 | "__id__": 10 887 | }, 888 | "_enabled": true, 889 | "_id": "23d77aESJJF51tUargR+/+" 890 | }, 891 | { 892 | "__type__": "cc.Node", 893 | "_name": "New Sprite(Splash)", 894 | "_objFlags": 0, 895 | "_parent": { 896 | "__id__": 4 897 | }, 898 | "_children": [], 899 | "_active": true, 900 | "_level": 4, 901 | "_components": [ 902 | { 903 | "__id__": 21 904 | } 905 | ], 906 | "_prefab": null, 907 | "_opacity": 255, 908 | "_color": { 909 | "__type__": "cc.Color", 910 | "r": 255, 911 | "g": 255, 912 | "b": 255, 913 | "a": 255 914 | }, 915 | "_contentSize": { 916 | "__type__": "cc.Size", 917 | "width": 640, 918 | "height": 1136 919 | }, 920 | "_anchorPoint": { 921 | "__type__": "cc.Vec2", 922 | "x": 0.5, 923 | "y": 0.5 924 | }, 925 | "_position": { 926 | "__type__": "cc.Vec3", 927 | "x": 0, 928 | "y": 0, 929 | "z": 0 930 | }, 931 | "_scale": { 932 | "__type__": "cc.Vec3", 933 | "x": 1, 934 | "y": 1, 935 | "z": 1 936 | }, 937 | "_quat": { 938 | "__type__": "cc.Quat", 939 | "x": 0, 940 | "y": 0, 941 | "z": 0, 942 | "w": 1 943 | }, 944 | "_skewX": 0, 945 | "_skewY": 0, 946 | "_is3DNode": false, 947 | "groupIndex": 0, 948 | "_rotationX": 0, 949 | "_rotationY": 0, 950 | "_id": "1eCAdZAE5ExqJlQmZ7eDeA" 951 | }, 952 | { 953 | "__type__": "cc.Sprite", 954 | "_name": "", 955 | "_objFlags": 0, 956 | "node": { 957 | "__id__": 20 958 | }, 959 | "_enabled": true, 960 | "_materials": [], 961 | "_srcBlendFactor": 770, 962 | "_dstBlendFactor": 771, 963 | "_spriteFrame": { 964 | "__uuid__": "a23235d1-15db-4b95-8439-a2e005bfff91" 965 | }, 966 | "_type": 0, 967 | "_sizeMode": 0, 968 | "_fillType": 0, 969 | "_fillCenter": { 970 | "__type__": "cc.Vec2", 971 | "x": 0, 972 | "y": 0 973 | }, 974 | "_fillStart": 0, 975 | "_fillRange": 0, 976 | "_isTrimmedMode": true, 977 | "_atlas": null, 978 | "_id": "13lSkD589Gi4zLPdL+7K1S" 979 | }, 980 | { 981 | "__type__": "cc.Node", 982 | "_name": "Title", 983 | "_objFlags": 0, 984 | "_parent": { 985 | "__id__": 4 986 | }, 987 | "_children": [], 988 | "_active": true, 989 | "_level": 4, 990 | "_components": [ 991 | { 992 | "__id__": 23 993 | } 994 | ], 995 | "_prefab": null, 996 | "_opacity": 255, 997 | "_color": { 998 | "__type__": "cc.Color", 999 | "r": 0, 1000 | "g": 0, 1001 | "b": 0, 1002 | "a": 255 1003 | }, 1004 | "_contentSize": { 1005 | "__type__": "cc.Size", 1006 | "width": 62.25, 1007 | "height": 50.4 1008 | }, 1009 | "_anchorPoint": { 1010 | "__type__": "cc.Vec2", 1011 | "x": 0.5, 1012 | "y": 0.5 1013 | }, 1014 | "_position": { 1015 | "__type__": "cc.Vec3", 1016 | "x": 0, 1017 | "y": 336.574, 1018 | "z": 0 1019 | }, 1020 | "_scale": { 1021 | "__type__": "cc.Vec3", 1022 | "x": 1, 1023 | "y": 1, 1024 | "z": 1 1025 | }, 1026 | "_quat": { 1027 | "__type__": "cc.Quat", 1028 | "x": 0, 1029 | "y": 0, 1030 | "z": 0, 1031 | "w": 1 1032 | }, 1033 | "_skewX": 0, 1034 | "_skewY": 0, 1035 | "_is3DNode": false, 1036 | "groupIndex": 0, 1037 | "_rotationX": 0, 1038 | "_rotationY": 0, 1039 | "_id": "58ngx+cPdEC73hK1Lrf9YH" 1040 | }, 1041 | { 1042 | "__type__": "cc.Label", 1043 | "_name": "", 1044 | "_objFlags": 0, 1045 | "node": { 1046 | "__id__": 22 1047 | }, 1048 | "_enabled": true, 1049 | "_materials": [], 1050 | "_useOriginalSize": false, 1051 | "_string": "UI1", 1052 | "_N$string": "UI1", 1053 | "_fontSize": 40, 1054 | "_lineHeight": 40, 1055 | "_enableWrapText": true, 1056 | "_N$file": null, 1057 | "_isSystemFontUsed": true, 1058 | "_spacingX": 0, 1059 | "_batchAsBitmap": false, 1060 | "_N$horizontalAlign": 1, 1061 | "_N$verticalAlign": 1, 1062 | "_N$fontFamily": "Arial", 1063 | "_N$overflow": 0, 1064 | "_N$cacheMode": 0, 1065 | "_id": "b8HG0mBVRGZ4kHOUVxGtex" 1066 | }, 1067 | { 1068 | "__type__": "cc.Node", 1069 | "_name": "Title2", 1070 | "_objFlags": 0, 1071 | "_parent": { 1072 | "__id__": 4 1073 | }, 1074 | "_children": [], 1075 | "_active": true, 1076 | "_level": 4, 1077 | "_components": [ 1078 | { 1079 | "__id__": 25 1080 | } 1081 | ], 1082 | "_prefab": null, 1083 | "_opacity": 255, 1084 | "_color": { 1085 | "__type__": "cc.Color", 1086 | "r": 0, 1087 | "g": 0, 1088 | "b": 0, 1089 | "a": 255 1090 | }, 1091 | "_contentSize": { 1092 | "__type__": "cc.Size", 1093 | "width": 84.49, 1094 | "height": 50.4 1095 | }, 1096 | "_anchorPoint": { 1097 | "__type__": "cc.Vec2", 1098 | "x": 0.5, 1099 | "y": 0.5 1100 | }, 1101 | "_position": { 1102 | "__type__": "cc.Vec3", 1103 | "x": 0, 1104 | "y": 152.052, 1105 | "z": 0 1106 | }, 1107 | "_scale": { 1108 | "__type__": "cc.Vec3", 1109 | "x": 1, 1110 | "y": 1, 1111 | "z": 1 1112 | }, 1113 | "_quat": { 1114 | "__type__": "cc.Quat", 1115 | "x": 0, 1116 | "y": 0, 1117 | "z": 0, 1118 | "w": 1 1119 | }, 1120 | "_skewX": 0, 1121 | "_skewY": 0, 1122 | "_is3DNode": false, 1123 | "groupIndex": 0, 1124 | "_rotationX": 0, 1125 | "_rotationY": 0, 1126 | "_id": "54O4/2cH5O0oz/S+mEfLlp" 1127 | }, 1128 | { 1129 | "__type__": "cc.Label", 1130 | "_name": "", 1131 | "_objFlags": 0, 1132 | "node": { 1133 | "__id__": 24 1134 | }, 1135 | "_enabled": true, 1136 | "_materials": [], 1137 | "_useOriginalSize": false, 1138 | "_string": "title2", 1139 | "_N$string": "title2", 1140 | "_fontSize": 40, 1141 | "_lineHeight": 40, 1142 | "_enableWrapText": true, 1143 | "_N$file": null, 1144 | "_isSystemFontUsed": true, 1145 | "_spacingX": 0, 1146 | "_batchAsBitmap": false, 1147 | "_N$horizontalAlign": 1, 1148 | "_N$verticalAlign": 1, 1149 | "_N$fontFamily": "Arial", 1150 | "_N$overflow": 0, 1151 | "_N$cacheMode": 0, 1152 | "_id": "f2ZT2omQpD6qh0OIwdCgYY" 1153 | }, 1154 | { 1155 | "__type__": "cc.Node", 1156 | "_name": "Btn1", 1157 | "_objFlags": 0, 1158 | "_parent": { 1159 | "__id__": 4 1160 | }, 1161 | "_children": [ 1162 | { 1163 | "__id__": 27 1164 | } 1165 | ], 1166 | "_active": true, 1167 | "_level": 4, 1168 | "_components": [ 1169 | { 1170 | "__id__": 32 1171 | } 1172 | ], 1173 | "_prefab": null, 1174 | "_opacity": 255, 1175 | "_color": { 1176 | "__type__": "cc.Color", 1177 | "r": 255, 1178 | "g": 255, 1179 | "b": 255, 1180 | "a": 255 1181 | }, 1182 | "_contentSize": { 1183 | "__type__": "cc.Size", 1184 | "width": 100, 1185 | "height": 40 1186 | }, 1187 | "_anchorPoint": { 1188 | "__type__": "cc.Vec2", 1189 | "x": 0.5, 1190 | "y": 0.5 1191 | }, 1192 | "_position": { 1193 | "__type__": "cc.Vec3", 1194 | "x": 0, 1195 | "y": 13.071, 1196 | "z": 0 1197 | }, 1198 | "_scale": { 1199 | "__type__": "cc.Vec3", 1200 | "x": 1, 1201 | "y": 1, 1202 | "z": 1 1203 | }, 1204 | "_quat": { 1205 | "__type__": "cc.Quat", 1206 | "x": 0, 1207 | "y": 0, 1208 | "z": 0, 1209 | "w": 1 1210 | }, 1211 | "_skewX": 0, 1212 | "_skewY": 0, 1213 | "_is3DNode": false, 1214 | "groupIndex": 0, 1215 | "_rotationX": 0, 1216 | "_rotationY": 0, 1217 | "_id": "faNNU+sG5AKZN7jBhveWEH" 1218 | }, 1219 | { 1220 | "__type__": "cc.Node", 1221 | "_name": "Background", 1222 | "_objFlags": 0, 1223 | "_parent": { 1224 | "__id__": 26 1225 | }, 1226 | "_children": [ 1227 | { 1228 | "__id__": 28 1229 | } 1230 | ], 1231 | "_active": true, 1232 | "_level": 2, 1233 | "_components": [ 1234 | { 1235 | "__id__": 30 1236 | }, 1237 | { 1238 | "__id__": 31 1239 | } 1240 | ], 1241 | "_prefab": null, 1242 | "_opacity": 255, 1243 | "_color": { 1244 | "__type__": "cc.Color", 1245 | "r": 230, 1246 | "g": 230, 1247 | "b": 230, 1248 | "a": 255 1249 | }, 1250 | "_contentSize": { 1251 | "__type__": "cc.Size", 1252 | "width": 100, 1253 | "height": 40 1254 | }, 1255 | "_anchorPoint": { 1256 | "__type__": "cc.Vec2", 1257 | "x": 0.5, 1258 | "y": 0.5 1259 | }, 1260 | "_position": { 1261 | "__type__": "cc.Vec3", 1262 | "x": 0, 1263 | "y": 0, 1264 | "z": 0 1265 | }, 1266 | "_scale": { 1267 | "__type__": "cc.Vec3", 1268 | "x": 1, 1269 | "y": 1, 1270 | "z": 1 1271 | }, 1272 | "_quat": { 1273 | "__type__": "cc.Quat", 1274 | "x": 0, 1275 | "y": 0, 1276 | "z": 0, 1277 | "w": 1 1278 | }, 1279 | "_skewX": 0, 1280 | "_skewY": 0, 1281 | "_is3DNode": false, 1282 | "groupIndex": 0, 1283 | "_rotationX": 0, 1284 | "_rotationY": 0, 1285 | "_id": "73VCRYuw9MVaw7ldNyk8nD" 1286 | }, 1287 | { 1288 | "__type__": "cc.Node", 1289 | "_name": "Label", 1290 | "_objFlags": 0, 1291 | "_parent": { 1292 | "__id__": 27 1293 | }, 1294 | "_children": [], 1295 | "_active": true, 1296 | "_level": 3, 1297 | "_components": [ 1298 | { 1299 | "__id__": 29 1300 | } 1301 | ], 1302 | "_prefab": null, 1303 | "_opacity": 255, 1304 | "_color": { 1305 | "__type__": "cc.Color", 1306 | "r": 0, 1307 | "g": 0, 1308 | "b": 0, 1309 | "a": 255 1310 | }, 1311 | "_contentSize": { 1312 | "__type__": "cc.Size", 1313 | "width": 100, 1314 | "height": 40 1315 | }, 1316 | "_anchorPoint": { 1317 | "__type__": "cc.Vec2", 1318 | "x": 0.5, 1319 | "y": 0.5 1320 | }, 1321 | "_position": { 1322 | "__type__": "cc.Vec3", 1323 | "x": 0, 1324 | "y": 0, 1325 | "z": 0 1326 | }, 1327 | "_scale": { 1328 | "__type__": "cc.Vec3", 1329 | "x": 1, 1330 | "y": 1, 1331 | "z": 1 1332 | }, 1333 | "_quat": { 1334 | "__type__": "cc.Quat", 1335 | "x": 0, 1336 | "y": 0, 1337 | "z": 0, 1338 | "w": 1 1339 | }, 1340 | "_skewX": 0, 1341 | "_skewY": 0, 1342 | "_is3DNode": false, 1343 | "groupIndex": 0, 1344 | "_rotationX": 0, 1345 | "_rotationY": 0, 1346 | "_id": "c0NxU7YCVG5Zkw7iPohlhQ" 1347 | }, 1348 | { 1349 | "__type__": "cc.Label", 1350 | "_name": "", 1351 | "_objFlags": 0, 1352 | "node": { 1353 | "__id__": 28 1354 | }, 1355 | "_enabled": true, 1356 | "_materials": [], 1357 | "_useOriginalSize": false, 1358 | "_string": "按钮1", 1359 | "_N$string": "按钮1", 1360 | "_fontSize": 20, 1361 | "_lineHeight": 40, 1362 | "_enableWrapText": false, 1363 | "_N$file": null, 1364 | "_isSystemFontUsed": true, 1365 | "_spacingX": 0, 1366 | "_batchAsBitmap": false, 1367 | "_N$horizontalAlign": 1, 1368 | "_N$verticalAlign": 1, 1369 | "_N$fontFamily": "Arial", 1370 | "_N$overflow": 1, 1371 | "_N$cacheMode": 0, 1372 | "_id": "7cqyrRezlP9YHwH6pALiVo" 1373 | }, 1374 | { 1375 | "__type__": "cc.Sprite", 1376 | "_name": "", 1377 | "_objFlags": 0, 1378 | "node": { 1379 | "__id__": 27 1380 | }, 1381 | "_enabled": true, 1382 | "_materials": [], 1383 | "_srcBlendFactor": 770, 1384 | "_dstBlendFactor": 771, 1385 | "_spriteFrame": { 1386 | "__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952" 1387 | }, 1388 | "_type": 1, 1389 | "_sizeMode": 0, 1390 | "_fillType": 0, 1391 | "_fillCenter": { 1392 | "__type__": "cc.Vec2", 1393 | "x": 0, 1394 | "y": 0 1395 | }, 1396 | "_fillStart": 0, 1397 | "_fillRange": 0, 1398 | "_isTrimmedMode": true, 1399 | "_atlas": null, 1400 | "_id": "64SnW7hFFEJJ9RZKVvd/S2" 1401 | }, 1402 | { 1403 | "__type__": "cc.Widget", 1404 | "_name": "", 1405 | "_objFlags": 0, 1406 | "node": { 1407 | "__id__": 27 1408 | }, 1409 | "_enabled": true, 1410 | "alignMode": 0, 1411 | "_target": null, 1412 | "_alignFlags": 45, 1413 | "_left": 0, 1414 | "_right": 0, 1415 | "_top": 0, 1416 | "_bottom": 0, 1417 | "_verticalCenter": 0, 1418 | "_horizontalCenter": 0, 1419 | "_isAbsLeft": true, 1420 | "_isAbsRight": true, 1421 | "_isAbsTop": true, 1422 | "_isAbsBottom": true, 1423 | "_isAbsHorizontalCenter": true, 1424 | "_isAbsVerticalCenter": true, 1425 | "_originalWidth": 100, 1426 | "_originalHeight": 40, 1427 | "_id": "ebnyLleadASo7MdZdN0/dk" 1428 | }, 1429 | { 1430 | "__type__": "cc.Button", 1431 | "_name": "", 1432 | "_objFlags": 0, 1433 | "node": { 1434 | "__id__": 26 1435 | }, 1436 | "_enabled": true, 1437 | "duration": 0.1, 1438 | "zoomScale": 1.2, 1439 | "clickEvents": [ 1440 | { 1441 | "__id__": 33 1442 | } 1443 | ], 1444 | "_N$interactable": true, 1445 | "_N$enableAutoGrayEffect": false, 1446 | "_N$transition": 2, 1447 | "transition": 2, 1448 | "_N$normalColor": { 1449 | "__type__": "cc.Color", 1450 | "r": 230, 1451 | "g": 230, 1452 | "b": 230, 1453 | "a": 255 1454 | }, 1455 | "_N$pressedColor": { 1456 | "__type__": "cc.Color", 1457 | "r": 200, 1458 | "g": 200, 1459 | "b": 200, 1460 | "a": 255 1461 | }, 1462 | "pressedColor": { 1463 | "__type__": "cc.Color", 1464 | "r": 200, 1465 | "g": 200, 1466 | "b": 200, 1467 | "a": 255 1468 | }, 1469 | "_N$hoverColor": { 1470 | "__type__": "cc.Color", 1471 | "r": 255, 1472 | "g": 255, 1473 | "b": 255, 1474 | "a": 255 1475 | }, 1476 | "hoverColor": { 1477 | "__type__": "cc.Color", 1478 | "r": 255, 1479 | "g": 255, 1480 | "b": 255, 1481 | "a": 255 1482 | }, 1483 | "_N$disabledColor": { 1484 | "__type__": "cc.Color", 1485 | "r": 120, 1486 | "g": 120, 1487 | "b": 120, 1488 | "a": 200 1489 | }, 1490 | "_N$normalSprite": { 1491 | "__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952" 1492 | }, 1493 | "_N$pressedSprite": { 1494 | "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" 1495 | }, 1496 | "pressedSprite": { 1497 | "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" 1498 | }, 1499 | "_N$hoverSprite": { 1500 | "__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952" 1501 | }, 1502 | "hoverSprite": { 1503 | "__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952" 1504 | }, 1505 | "_N$disabledSprite": { 1506 | "__uuid__": "29158224-f8dd-4661-a796-1ffab537140e" 1507 | }, 1508 | "_N$target": { 1509 | "__id__": 27 1510 | }, 1511 | "_id": "4dR59Yj7pKb70bLBgPrQRS" 1512 | }, 1513 | { 1514 | "__type__": "cc.ClickEvent", 1515 | "target": { 1516 | "__id__": 4 1517 | }, 1518 | "component": "", 1519 | "_componentId": "6ca4cN5wthNpbZKI8WBXFF3", 1520 | "handler": "handleBtn1", 1521 | "customEventData": "" 1522 | }, 1523 | { 1524 | "__type__": "cc.Node", 1525 | "_name": "CloseBtn", 1526 | "_objFlags": 0, 1527 | "_parent": { 1528 | "__id__": 4 1529 | }, 1530 | "_children": [ 1531 | { 1532 | "__id__": 35 1533 | } 1534 | ], 1535 | "_active": true, 1536 | "_level": 4, 1537 | "_components": [ 1538 | { 1539 | "__id__": 40 1540 | } 1541 | ], 1542 | "_prefab": null, 1543 | "_opacity": 255, 1544 | "_color": { 1545 | "__type__": "cc.Color", 1546 | "r": 255, 1547 | "g": 255, 1548 | "b": 255, 1549 | "a": 255 1550 | }, 1551 | "_contentSize": { 1552 | "__type__": "cc.Size", 1553 | "width": 100, 1554 | "height": 40 1555 | }, 1556 | "_anchorPoint": { 1557 | "__type__": "cc.Vec2", 1558 | "x": 0.5, 1559 | "y": 0.5 1560 | }, 1561 | "_position": { 1562 | "__type__": "cc.Vec3", 1563 | "x": 0, 1564 | "y": -94.764, 1565 | "z": 0 1566 | }, 1567 | "_scale": { 1568 | "__type__": "cc.Vec3", 1569 | "x": 1, 1570 | "y": 1, 1571 | "z": 1 1572 | }, 1573 | "_quat": { 1574 | "__type__": "cc.Quat", 1575 | "x": 0, 1576 | "y": 0, 1577 | "z": 0, 1578 | "w": 1 1579 | }, 1580 | "_skewX": 0, 1581 | "_skewY": 0, 1582 | "_is3DNode": false, 1583 | "groupIndex": 0, 1584 | "_rotationX": 0, 1585 | "_rotationY": 0, 1586 | "_id": "82QIe4kQ1OYpC/59H/B2oR" 1587 | }, 1588 | { 1589 | "__type__": "cc.Node", 1590 | "_name": "Background", 1591 | "_objFlags": 0, 1592 | "_parent": { 1593 | "__id__": 34 1594 | }, 1595 | "_children": [ 1596 | { 1597 | "__id__": 36 1598 | } 1599 | ], 1600 | "_active": true, 1601 | "_level": 2, 1602 | "_components": [ 1603 | { 1604 | "__id__": 38 1605 | }, 1606 | { 1607 | "__id__": 39 1608 | } 1609 | ], 1610 | "_prefab": null, 1611 | "_opacity": 255, 1612 | "_color": { 1613 | "__type__": "cc.Color", 1614 | "r": 230, 1615 | "g": 230, 1616 | "b": 230, 1617 | "a": 255 1618 | }, 1619 | "_contentSize": { 1620 | "__type__": "cc.Size", 1621 | "width": 100, 1622 | "height": 40 1623 | }, 1624 | "_anchorPoint": { 1625 | "__type__": "cc.Vec2", 1626 | "x": 0.5, 1627 | "y": 0.5 1628 | }, 1629 | "_position": { 1630 | "__type__": "cc.Vec3", 1631 | "x": 0, 1632 | "y": 0, 1633 | "z": 0 1634 | }, 1635 | "_scale": { 1636 | "__type__": "cc.Vec3", 1637 | "x": 1, 1638 | "y": 1, 1639 | "z": 1 1640 | }, 1641 | "_quat": { 1642 | "__type__": "cc.Quat", 1643 | "x": 0, 1644 | "y": 0, 1645 | "z": 0, 1646 | "w": 1 1647 | }, 1648 | "_skewX": 0, 1649 | "_skewY": 0, 1650 | "_is3DNode": false, 1651 | "groupIndex": 0, 1652 | "_rotationX": 0, 1653 | "_rotationY": 0, 1654 | "_id": "e2HlZ2QYtG2rY5pwDpwal9" 1655 | }, 1656 | { 1657 | "__type__": "cc.Node", 1658 | "_name": "Label", 1659 | "_objFlags": 0, 1660 | "_parent": { 1661 | "__id__": 35 1662 | }, 1663 | "_children": [], 1664 | "_active": true, 1665 | "_level": 3, 1666 | "_components": [ 1667 | { 1668 | "__id__": 37 1669 | } 1670 | ], 1671 | "_prefab": null, 1672 | "_opacity": 255, 1673 | "_color": { 1674 | "__type__": "cc.Color", 1675 | "r": 0, 1676 | "g": 0, 1677 | "b": 0, 1678 | "a": 255 1679 | }, 1680 | "_contentSize": { 1681 | "__type__": "cc.Size", 1682 | "width": 100, 1683 | "height": 40 1684 | }, 1685 | "_anchorPoint": { 1686 | "__type__": "cc.Vec2", 1687 | "x": 0.5, 1688 | "y": 0.5 1689 | }, 1690 | "_position": { 1691 | "__type__": "cc.Vec3", 1692 | "x": 0, 1693 | "y": 0, 1694 | "z": 0 1695 | }, 1696 | "_scale": { 1697 | "__type__": "cc.Vec3", 1698 | "x": 1, 1699 | "y": 1, 1700 | "z": 1 1701 | }, 1702 | "_quat": { 1703 | "__type__": "cc.Quat", 1704 | "x": 0, 1705 | "y": 0, 1706 | "z": 0, 1707 | "w": 1 1708 | }, 1709 | "_skewX": 0, 1710 | "_skewY": 0, 1711 | "_is3DNode": false, 1712 | "groupIndex": 0, 1713 | "_rotationX": 0, 1714 | "_rotationY": 0, 1715 | "_id": "f2jWK2ojFNdocWf+gvEIBe" 1716 | }, 1717 | { 1718 | "__type__": "cc.Label", 1719 | "_name": "", 1720 | "_objFlags": 0, 1721 | "node": { 1722 | "__id__": 36 1723 | }, 1724 | "_enabled": true, 1725 | "_materials": [], 1726 | "_useOriginalSize": false, 1727 | "_string": "关闭", 1728 | "_N$string": "关闭", 1729 | "_fontSize": 20, 1730 | "_lineHeight": 40, 1731 | "_enableWrapText": false, 1732 | "_N$file": null, 1733 | "_isSystemFontUsed": true, 1734 | "_spacingX": 0, 1735 | "_batchAsBitmap": false, 1736 | "_N$horizontalAlign": 1, 1737 | "_N$verticalAlign": 1, 1738 | "_N$fontFamily": "Arial", 1739 | "_N$overflow": 1, 1740 | "_N$cacheMode": 0, 1741 | "_id": "98E6+Opp5DQqWVrWBCgCuB" 1742 | }, 1743 | { 1744 | "__type__": "cc.Sprite", 1745 | "_name": "", 1746 | "_objFlags": 0, 1747 | "node": { 1748 | "__id__": 35 1749 | }, 1750 | "_enabled": true, 1751 | "_materials": [], 1752 | "_srcBlendFactor": 770, 1753 | "_dstBlendFactor": 771, 1754 | "_spriteFrame": { 1755 | "__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952" 1756 | }, 1757 | "_type": 1, 1758 | "_sizeMode": 0, 1759 | "_fillType": 0, 1760 | "_fillCenter": { 1761 | "__type__": "cc.Vec2", 1762 | "x": 0, 1763 | "y": 0 1764 | }, 1765 | "_fillStart": 0, 1766 | "_fillRange": 0, 1767 | "_isTrimmedMode": true, 1768 | "_atlas": null, 1769 | "_id": "22dY5YeFtC3K5FOE8hwvAo" 1770 | }, 1771 | { 1772 | "__type__": "cc.Widget", 1773 | "_name": "", 1774 | "_objFlags": 0, 1775 | "node": { 1776 | "__id__": 35 1777 | }, 1778 | "_enabled": true, 1779 | "alignMode": 0, 1780 | "_target": null, 1781 | "_alignFlags": 45, 1782 | "_left": 0, 1783 | "_right": 0, 1784 | "_top": 0, 1785 | "_bottom": 0, 1786 | "_verticalCenter": 0, 1787 | "_horizontalCenter": 0, 1788 | "_isAbsLeft": true, 1789 | "_isAbsRight": true, 1790 | "_isAbsTop": true, 1791 | "_isAbsBottom": true, 1792 | "_isAbsHorizontalCenter": true, 1793 | "_isAbsVerticalCenter": true, 1794 | "_originalWidth": 100, 1795 | "_originalHeight": 40, 1796 | "_id": "45dhYW+/xAf7XqPhpaZF5A" 1797 | }, 1798 | { 1799 | "__type__": "cc.Button", 1800 | "_name": "", 1801 | "_objFlags": 0, 1802 | "node": { 1803 | "__id__": 34 1804 | }, 1805 | "_enabled": true, 1806 | "duration": 0.1, 1807 | "zoomScale": 1.2, 1808 | "clickEvents": [ 1809 | { 1810 | "__id__": 41 1811 | } 1812 | ], 1813 | "_N$interactable": true, 1814 | "_N$enableAutoGrayEffect": false, 1815 | "_N$transition": 2, 1816 | "transition": 2, 1817 | "_N$normalColor": { 1818 | "__type__": "cc.Color", 1819 | "r": 230, 1820 | "g": 230, 1821 | "b": 230, 1822 | "a": 255 1823 | }, 1824 | "_N$pressedColor": { 1825 | "__type__": "cc.Color", 1826 | "r": 200, 1827 | "g": 200, 1828 | "b": 200, 1829 | "a": 255 1830 | }, 1831 | "pressedColor": { 1832 | "__type__": "cc.Color", 1833 | "r": 200, 1834 | "g": 200, 1835 | "b": 200, 1836 | "a": 255 1837 | }, 1838 | "_N$hoverColor": { 1839 | "__type__": "cc.Color", 1840 | "r": 255, 1841 | "g": 255, 1842 | "b": 255, 1843 | "a": 255 1844 | }, 1845 | "hoverColor": { 1846 | "__type__": "cc.Color", 1847 | "r": 255, 1848 | "g": 255, 1849 | "b": 255, 1850 | "a": 255 1851 | }, 1852 | "_N$disabledColor": { 1853 | "__type__": "cc.Color", 1854 | "r": 120, 1855 | "g": 120, 1856 | "b": 120, 1857 | "a": 200 1858 | }, 1859 | "_N$normalSprite": { 1860 | "__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952" 1861 | }, 1862 | "_N$pressedSprite": { 1863 | "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" 1864 | }, 1865 | "pressedSprite": { 1866 | "__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a" 1867 | }, 1868 | "_N$hoverSprite": { 1869 | "__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952" 1870 | }, 1871 | "hoverSprite": { 1872 | "__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952" 1873 | }, 1874 | "_N$disabledSprite": { 1875 | "__uuid__": "29158224-f8dd-4661-a796-1ffab537140e" 1876 | }, 1877 | "_N$target": { 1878 | "__id__": 35 1879 | }, 1880 | "_id": "91XKyA3DBGA7Hj9zmYb+/L" 1881 | }, 1882 | { 1883 | "__type__": "cc.ClickEvent", 1884 | "target": { 1885 | "__id__": 4 1886 | }, 1887 | "component": "", 1888 | "_componentId": "6ca4cN5wthNpbZKI8WBXFF3", 1889 | "handler": "handleClose", 1890 | "customEventData": "" 1891 | }, 1892 | { 1893 | "__type__": "6ca4cN5wthNpbZKI8WBXFF3", 1894 | "_name": "", 1895 | "_objFlags": 0, 1896 | "node": { 1897 | "__id__": 4 1898 | }, 1899 | "_enabled": true, 1900 | "titleLabel": { 1901 | "__id__": 23 1902 | }, 1903 | "_id": "6f9fvreZlNg4ARRxWeraZk" 1904 | } 1905 | ] --------------------------------------------------------------------------------