├── .gitattributes ├── .gitignore ├── README.md ├── assets ├── Anim.meta ├── Anim │ ├── dead.anim │ ├── dead.anim.meta │ ├── entityGlimpse.anim │ ├── entityGlimpse.anim.meta │ ├── glimpse.anim │ └── glimpse.anim.meta ├── Audio.meta ├── Audio │ ├── bullet.mp3 │ ├── bullet.mp3.meta │ ├── dead.mp3 │ └── dead.mp3.meta ├── Prefab.meta ├── Prefab │ ├── Alert.prefab │ ├── Alert.prefab.meta │ ├── bullet.prefab │ ├── bullet.prefab.meta │ ├── entity.prefab │ ├── entity.prefab.meta │ ├── rankItem.prefab │ └── rankItem.prefab.meta ├── Scene.meta ├── Scene │ ├── end.fire │ ├── end.fire.meta │ ├── game.fire │ ├── game.fire.meta │ ├── start.fire │ └── start.fire.meta ├── Script.meta ├── Script │ ├── ActionLayer.js │ ├── ActionLayer.js.meta │ ├── Alert.js │ ├── Alert.js.meta │ ├── Bullet.js │ ├── Bullet.js.meta │ ├── CmdLogon.js │ ├── CmdLogon.js.meta │ ├── EndCtrl.js │ ├── EndCtrl.js.meta │ ├── Entity.js │ ├── Entity.js.meta │ ├── GameCtrl.js │ ├── GameCtrl.js.meta │ ├── GlobalConfig.js │ ├── GlobalConfig.js.meta │ ├── GlobalNode.js │ ├── GlobalNode.js.meta │ ├── JoyStick.js │ ├── JoyStick.js.meta │ ├── MsgMgr.js │ ├── MsgMgr.js.meta │ ├── NetCtrl.js │ ├── NetCtrl.js.meta │ ├── RankItem.js │ ├── RankItem.js.meta │ ├── RankLabel.js │ ├── RankLabel.js.meta │ ├── RankLayer.js │ ├── RankLayer.js.meta │ ├── ShowingLayer.js │ ├── ShowingLayer.js.meta │ ├── StartLayer.js │ ├── StartLayer.js.meta │ ├── Util.js │ ├── Util.js.meta │ ├── crc32.js │ ├── crc32.js.meta │ ├── msg.js │ ├── msg.js.meta │ ├── protobuf.js │ └── protobuf.js.meta ├── Texture.meta └── Texture │ ├── alert.meta │ ├── alert │ ├── Alert.png │ ├── Alert.png.meta │ ├── cancel.png │ ├── cancel.png.meta │ ├── ok.png │ └── ok.png.meta │ ├── avatar.jpg │ ├── avatar.jpg.meta │ ├── bg.png │ ├── bg.png.meta │ ├── bullet.png │ ├── bullet.png.meta │ ├── cao.jpg │ ├── cao.jpg.meta │ ├── cao.png │ ├── cao.png.meta │ ├── default_sprite_splash.png │ ├── default_sprite_splash.png.meta │ ├── fei.png │ ├── fei.png.meta │ ├── gameRankBG.png │ ├── gameRankBG.png.meta │ ├── green.png │ ├── green.png.meta │ ├── joystick.png │ ├── joystick.png.meta │ ├── joystickBG.png │ ├── joystickBG.png.meta │ ├── rankBG.png │ ├── rankBG.png.meta │ ├── rankTitle.png │ ├── rankTitle.png.meta │ ├── red.png │ ├── red.png.meta │ ├── shoot.plist │ ├── shoot.plist.meta │ ├── shoot.png │ ├── shoot.png.meta │ ├── start.png │ ├── start.png.meta │ ├── title.png │ ├── title.png.meta │ ├── yellow.png │ └── yellow.png.meta ├── creator.d.ts ├── doc ├── game.png └── login.png ├── jsconfig.json ├── project.json ├── settings ├── builder.json ├── builder.panel.json ├── project.json └── services.json ├── template-banner.png └── template.json /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | #///////////////////////////////////////////////////////////////////////////// 2 | # Fireball Projects 3 | #///////////////////////////////////////////////////////////////////////////// 4 | 5 | library/ 6 | temp/ 7 | local/ 8 | build/ 9 | 10 | #///////////////////////////////////////////////////////////////////////////// 11 | # Logs and databases 12 | #///////////////////////////////////////////////////////////////////////////// 13 | 14 | *.log 15 | *.sql 16 | *.sqlite 17 | 18 | #///////////////////////////////////////////////////////////////////////////// 19 | # files for debugger 20 | #///////////////////////////////////////////////////////////////////////////// 21 | 22 | *.sln 23 | *.csproj 24 | *.pidb 25 | *.unityproj 26 | *.suo 27 | 28 | #///////////////////////////////////////////////////////////////////////////// 29 | # OS generated files 30 | #///////////////////////////////////////////////////////////////////////////// 31 | 32 | .DS_Store 33 | ehthumbs.db 34 | Thumbs.db 35 | 36 | #///////////////////////////////////////////////////////////////////////////// 37 | # exvim files 38 | #///////////////////////////////////////////////////////////////////////////// 39 | 40 | *UnityVS.meta 41 | *.err 42 | *.err.meta 43 | *.exvim 44 | *.exvim.meta 45 | *.vimentry 46 | *.vimentry.meta 47 | *.vimproject 48 | *.vimproject.meta 49 | .vimfiles.*/ 50 | .exvim.*/ 51 | quick_gen_project_*_autogen.bat 52 | quick_gen_project_*_autogen.bat.meta 53 | quick_gen_project_*_autogen.sh 54 | quick_gen_project_*_autogen.sh.meta 55 | .exvim.app 56 | 57 | #///////////////////////////////////////////////////////////////////////////// 58 | # webstorm files 59 | #///////////////////////////////////////////////////////////////////////////// 60 | 61 | .idea/ 62 | 63 | #////////////////////////// 64 | # VS Code 65 | #////////////////////////// 66 | 67 | .vscode/ -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # 头像大乱战 2 | cocos creator开发的对战小游戏客户端protobuf通信版([桌面端试玩](http://af.09900990.xyz:5050/),[手机端试玩](http://af.0990.tech:5000/))
3 | 4 | # 操作 5 | ![login](doc/login.png)
6 | ![game](doc/game.png)
7 | 使用上下左右控制键转向(或摇杆),鼠标点击发射子弹,消灭其它人,其它人可随时加入游戏 8 | 9 | # 编译运行 10 | 客户端使用cocos creator2.1.2打开项目,运行即可 11 | 12 | [服务端代码在此(golang)](https://github.com/0990/avatar-fight-server) 13 | -------------------------------------------------------------------------------- /assets/Anim.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.1", 3 | "uuid": "42ace4ad-8412-4757-9b14-3e8e2205fa53", 4 | "subMetas": {} 5 | } -------------------------------------------------------------------------------- /assets/Anim/dead.anim: -------------------------------------------------------------------------------- 1 | { 2 | "__type__": "cc.AnimationClip", 3 | "_name": "dead", 4 | "_objFlags": 0, 5 | "_rawFiles": null, 6 | "_duration": 0.18333333333333332, 7 | "sample": 60, 8 | "speed": 1, 9 | "wrapMode": 1, 10 | "curveData": { 11 | "comps": { 12 | "cc.Sprite": { 13 | "spriteFrame": [ 14 | { 15 | "frame": 0, 16 | "value": { 17 | "__uuid__": "ed48f322-1cd9-473c-aacb-689a1bb2f770" 18 | } 19 | }, 20 | { 21 | "frame": 0.08333333333333333, 22 | "value": { 23 | "__uuid__": "d9b97614-a4fe-4f5f-b5de-8f9a718aad2b" 24 | } 25 | }, 26 | { 27 | "frame": 0.16666666666666666, 28 | "value": { 29 | "__uuid__": "757294e3-de13-4a1c-9c8d-f5f33e2d1583" 30 | } 31 | } 32 | ] 33 | } 34 | } 35 | }, 36 | "events": [] 37 | } -------------------------------------------------------------------------------- /assets/Anim/dead.anim.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.1.0", 3 | "uuid": "27951031-6646-4fe1-a310-bd0422ec3369", 4 | "subMetas": {} 5 | } -------------------------------------------------------------------------------- /assets/Anim/entityGlimpse.anim: -------------------------------------------------------------------------------- 1 | { 2 | "__type__": "cc.AnimationClip", 3 | "_name": "entityGlimpse", 4 | "_objFlags": 0, 5 | "_rawFiles": null, 6 | "_duration": 1.3333333333333333, 7 | "sample": 15, 8 | "speed": 1, 9 | "wrapMode": 1, 10 | "curveData": { 11 | "props": { 12 | "opacity": [ 13 | { 14 | "frame": 0, 15 | "value": 255 16 | }, 17 | { 18 | "frame": 0.3333333333333333, 19 | "value": 50 20 | }, 21 | { 22 | "frame": 0.6666666666666666, 23 | "value": 255 24 | }, 25 | { 26 | "frame": 1, 27 | "value": 50 28 | }, 29 | { 30 | "frame": 1.3333333333333333, 31 | "value": 255 32 | } 33 | ] 34 | } 35 | }, 36 | "events": [] 37 | } -------------------------------------------------------------------------------- /assets/Anim/entityGlimpse.anim.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.1.0", 3 | "uuid": "05bf7653-a06b-4067-a19e-30892059871d", 4 | "subMetas": {} 5 | } -------------------------------------------------------------------------------- /assets/Anim/glimpse.anim: -------------------------------------------------------------------------------- 1 | { 2 | "__type__": "cc.AnimationClip", 3 | "_name": "glimpse", 4 | "_objFlags": 0, 5 | "_rawFiles": null, 6 | "_duration": 0.75, 7 | "sample": 20, 8 | "speed": 1, 9 | "wrapMode": 1, 10 | "curveData": { 11 | "props": { 12 | "opacity": [ 13 | { 14 | "frame": 0, 15 | "value": 0 16 | }, 17 | { 18 | "frame": 0.25, 19 | "value": 255 20 | }, 21 | { 22 | "frame": 0.5, 23 | "value": 255 24 | }, 25 | { 26 | "frame": 0.75, 27 | "value": 0 28 | } 29 | ] 30 | } 31 | }, 32 | "events": [] 33 | } -------------------------------------------------------------------------------- /assets/Anim/glimpse.anim.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.1.0", 3 | "uuid": "18b4637d-a0cc-4f47-9e90-0e1a9fa06e32", 4 | "subMetas": {} 5 | } -------------------------------------------------------------------------------- /assets/Audio.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.1", 3 | "uuid": "67768a05-c9ed-4e13-b902-0856ed9895fc", 4 | "subMetas": {} 5 | } -------------------------------------------------------------------------------- /assets/Audio/bullet.mp3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Audio/bullet.mp3 -------------------------------------------------------------------------------- /assets/Audio/bullet.mp3.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.0.0", 3 | "uuid": "cb06c1b7-1a2d-4f84-be24-77a1c3642b80", 4 | "downloadMode": 0, 5 | "subMetas": {} 6 | } -------------------------------------------------------------------------------- /assets/Audio/dead.mp3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Audio/dead.mp3 -------------------------------------------------------------------------------- /assets/Audio/dead.mp3.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.0.0", 3 | "uuid": "6645eb0c-9b8a-41d6-abf6-05c68fad8fe7", 4 | "downloadMode": 0, 5 | "subMetas": {} 6 | } -------------------------------------------------------------------------------- /assets/Prefab.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.1", 3 | "uuid": "a667703c-7b0c-4e6e-bd8b-645436558836", 4 | "isGroup": false, 5 | "subMetas": {} 6 | } -------------------------------------------------------------------------------- /assets/Prefab/Alert.prefab.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.2.0", 3 | "uuid": "f48ce7f1-b5a4-43d2-8dea-0763a2414e41", 4 | "optimizationPolicy": "AUTO", 5 | "asyncLoadAssets": false, 6 | "readonly": false, 7 | "subMetas": {} 8 | } -------------------------------------------------------------------------------- /assets/Prefab/bullet.prefab: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "__type__": "cc.Prefab", 4 | "_name": "", 5 | "_objFlags": 0, 6 | "_rawFiles": null, 7 | "data": { 8 | "__id__": 1 9 | } 10 | }, 11 | { 12 | "__type__": "cc.Node", 13 | "_name": "bullet", 14 | "_objFlags": 0, 15 | "_parent": null, 16 | "_children": [], 17 | "_tag": -1, 18 | "_active": true, 19 | "_components": [ 20 | { 21 | "__id__": 2 22 | }, 23 | { 24 | "__id__": 3 25 | } 26 | ], 27 | "_prefab": { 28 | "__id__": 4 29 | }, 30 | "_id": "", 31 | "_opacity": 255, 32 | "_color": { 33 | "__type__": "cc.Color", 34 | "r": 255, 35 | "g": 255, 36 | "b": 255, 37 | "a": 255 38 | }, 39 | "_cascadeOpacityEnabled": true, 40 | "_anchorPoint": { 41 | "__type__": "cc.Vec2", 42 | "x": 0.5, 43 | "y": 0.5 44 | }, 45 | "_contentSize": { 46 | "__type__": "cc.Size", 47 | "width": 15, 48 | "height": 12 49 | }, 50 | "_rotationX": 0, 51 | "_rotationY": 0, 52 | "_scaleX": 1, 53 | "_scaleY": 1, 54 | "_position": { 55 | "__type__": "cc.Vec2", 56 | "x": 0, 57 | "y": 0 58 | }, 59 | "_skewX": 0, 60 | "_skewY": 0, 61 | "_localZOrder": 0, 62 | "_globalZOrder": 0, 63 | "_opacityModifyRGB": false, 64 | "groupIndex": 0 65 | }, 66 | { 67 | "__type__": "cc.Sprite", 68 | "_name": "", 69 | "_objFlags": 0, 70 | "node": { 71 | "__id__": 1 72 | }, 73 | "_enabled": true, 74 | "_spriteFrame": { 75 | "__uuid__": "2dd208a7-97fc-445d-baf3-eb6a0cdfdfda" 76 | }, 77 | "_type": 0, 78 | "_sizeMode": 0, 79 | "_fillType": 0, 80 | "_fillCenter": { 81 | "__type__": "cc.Vec2", 82 | "x": 0, 83 | "y": 0 84 | }, 85 | "_fillStart": 0, 86 | "_fillRange": 0, 87 | "_isTrimmedMode": true, 88 | "_srcBlendFactor": 770, 89 | "_dstBlendFactor": 771, 90 | "_atlas": null 91 | }, 92 | { 93 | "__type__": "30d2fcgMsRCeJHDhCH/Rrtp", 94 | "_name": "", 95 | "_objFlags": 0, 96 | "node": { 97 | "__id__": 1 98 | }, 99 | "_enabled": true 100 | }, 101 | { 102 | "__type__": "cc.PrefabInfo", 103 | "root": { 104 | "__id__": 1 105 | }, 106 | "asset": { 107 | "__uuid__": "2f20aa99-3ec5-497f-b022-2a42aa91727e" 108 | }, 109 | "fileId": "60/Muf6O9IKah0pAIsIhZB", 110 | "sync": false 111 | } 112 | ] -------------------------------------------------------------------------------- /assets/Prefab/bullet.prefab.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.2.0", 3 | "uuid": "2f20aa99-3ec5-497f-b022-2a42aa91727e", 4 | "optimizationPolicy": "AUTO", 5 | "asyncLoadAssets": false, 6 | "readonly": false, 7 | "subMetas": {} 8 | } -------------------------------------------------------------------------------- /assets/Prefab/entity.prefab: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "__type__": "cc.Prefab", 4 | "_name": "", 5 | "_objFlags": 0, 6 | "_native": "", 7 | "data": { 8 | "__id__": 1 9 | }, 10 | "optimizationPolicy": 0, 11 | "asyncLoadAssets": false, 12 | "readonly": false 13 | }, 14 | { 15 | "__type__": "cc.Node", 16 | "_name": "entity", 17 | "_objFlags": 0, 18 | "_parent": null, 19 | "_children": [ 20 | { 21 | "__id__": 2 22 | }, 23 | { 24 | "__id__": 11 25 | } 26 | ], 27 | "_active": true, 28 | "_level": 1, 29 | "_components": [ 30 | { 31 | "__id__": 15 32 | }, 33 | { 34 | "__id__": 16 35 | }, 36 | { 37 | "__id__": 17 38 | } 39 | ], 40 | "_prefab": { 41 | "__id__": 18 42 | }, 43 | "_opacity": 255, 44 | "_color": { 45 | "__type__": "cc.Color", 46 | "r": 255, 47 | "g": 255, 48 | "b": 255, 49 | "a": 255 50 | }, 51 | "_contentSize": { 52 | "__type__": "cc.Size", 53 | "width": 170, 54 | "height": 170 55 | }, 56 | "_anchorPoint": { 57 | "__type__": "cc.Vec2", 58 | "x": 0.5, 59 | "y": 0.5 60 | }, 61 | "_position": { 62 | "__type__": "cc.Vec3", 63 | "x": 0, 64 | "y": 0, 65 | "z": 0 66 | }, 67 | "_scale": { 68 | "__type__": "cc.Vec3", 69 | "x": 1, 70 | "y": 1, 71 | "z": 1 72 | }, 73 | "_eulerAngles": { 74 | "__type__": "cc.Vec3", 75 | "x": 0, 76 | "y": 0, 77 | "z": 0 78 | }, 79 | "_skewX": 0, 80 | "_skewY": 0, 81 | "_is3DNode": false, 82 | "groupIndex": 0, 83 | "_rotationX": 0, 84 | "_rotationY": 0, 85 | "_id": "" 86 | }, 87 | { 88 | "__type__": "cc.Node", 89 | "_name": "avatarFather", 90 | "_objFlags": 0, 91 | "_parent": { 92 | "__id__": 1 93 | }, 94 | "_children": [ 95 | { 96 | "__id__": 3 97 | } 98 | ], 99 | "_active": true, 100 | "_level": 0, 101 | "_components": [ 102 | { 103 | "__id__": 8 104 | }, 105 | { 106 | "__id__": 9 107 | } 108 | ], 109 | "_prefab": { 110 | "__id__": 10 111 | }, 112 | "_opacity": 255, 113 | "_color": { 114 | "__type__": "cc.Color", 115 | "r": 255, 116 | "g": 255, 117 | "b": 255, 118 | "a": 255 119 | }, 120 | "_contentSize": { 121 | "__type__": "cc.Size", 122 | "width": 100, 123 | "height": 100 124 | }, 125 | "_anchorPoint": { 126 | "__type__": "cc.Vec2", 127 | "x": 0.5, 128 | "y": 0.5 129 | }, 130 | "_position": { 131 | "__type__": "cc.Vec3", 132 | "x": 0, 133 | "y": 0, 134 | "z": 0 135 | }, 136 | "_scale": { 137 | "__type__": "cc.Vec3", 138 | "x": 1, 139 | "y": 1, 140 | "z": 1 141 | }, 142 | "_eulerAngles": { 143 | "__type__": "cc.Vec3", 144 | "x": 0, 145 | "y": 0, 146 | "z": 0 147 | }, 148 | "_skewX": 0, 149 | "_skewY": 0, 150 | "_is3DNode": false, 151 | "groupIndex": 0, 152 | "_rotationX": 0, 153 | "_rotationY": 0, 154 | "_id": "" 155 | }, 156 | { 157 | "__type__": "cc.Node", 158 | "_name": "sprite", 159 | "_objFlags": 0, 160 | "_parent": { 161 | "__id__": 2 162 | }, 163 | "_children": [], 164 | "_active": true, 165 | "_level": 0, 166 | "_components": [ 167 | { 168 | "__id__": 4 169 | }, 170 | { 171 | "__id__": 5 172 | }, 173 | { 174 | "__id__": 6 175 | } 176 | ], 177 | "_prefab": { 178 | "__id__": 7 179 | }, 180 | "_opacity": 255, 181 | "_color": { 182 | "__type__": "cc.Color", 183 | "r": 255, 184 | "g": 255, 185 | "b": 255, 186 | "a": 255 187 | }, 188 | "_contentSize": { 189 | "__type__": "cc.Size", 190 | "width": 100, 191 | "height": 100 192 | }, 193 | "_anchorPoint": { 194 | "__type__": "cc.Vec2", 195 | "x": 0.5, 196 | "y": 0.5 197 | }, 198 | "_position": { 199 | "__type__": "cc.Vec3", 200 | "x": 0, 201 | "y": 0, 202 | "z": 0 203 | }, 204 | "_scale": { 205 | "__type__": "cc.Vec3", 206 | "x": 1, 207 | "y": 1, 208 | "z": 1 209 | }, 210 | "_eulerAngles": { 211 | "__type__": "cc.Vec3", 212 | "x": 0, 213 | "y": 0, 214 | "z": 0 215 | }, 216 | "_skewX": 0, 217 | "_skewY": 0, 218 | "_is3DNode": false, 219 | "groupIndex": 0, 220 | "_rotationX": 0, 221 | "_rotationY": 0, 222 | "_id": "" 223 | }, 224 | { 225 | "__type__": "cc.Sprite", 226 | "_name": "", 227 | "_objFlags": 0, 228 | "node": { 229 | "__id__": 3 230 | }, 231 | "_enabled": true, 232 | "_materials": [ 233 | { 234 | "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" 235 | } 236 | ], 237 | "_srcBlendFactor": 770, 238 | "_dstBlendFactor": 771, 239 | "_spriteFrame": { 240 | "__uuid__": "f6450315-893a-4502-b54b-b088068c9072" 241 | }, 242 | "_type": 0, 243 | "_sizeMode": 0, 244 | "_fillType": 0, 245 | "_fillCenter": { 246 | "__type__": "cc.Vec2", 247 | "x": 0, 248 | "y": 0 249 | }, 250 | "_fillStart": 0, 251 | "_fillRange": 0, 252 | "_isTrimmedMode": true, 253 | "_atlas": null, 254 | "_id": "" 255 | }, 256 | { 257 | "__type__": "cc.Widget", 258 | "_name": "", 259 | "_objFlags": 0, 260 | "node": { 261 | "__id__": 3 262 | }, 263 | "_enabled": true, 264 | "alignMode": 0, 265 | "_target": null, 266 | "_alignFlags": 45, 267 | "_left": 0, 268 | "_right": 0, 269 | "_top": 0, 270 | "_bottom": 0, 271 | "_verticalCenter": 0, 272 | "_horizontalCenter": 0, 273 | "_isAbsLeft": true, 274 | "_isAbsRight": true, 275 | "_isAbsTop": true, 276 | "_isAbsBottom": true, 277 | "_isAbsHorizontalCenter": true, 278 | "_isAbsVerticalCenter": true, 279 | "_originalWidth": 100, 280 | "_originalHeight": 100, 281 | "_id": "" 282 | }, 283 | { 284 | "__type__": "cc.Animation", 285 | "_name": "", 286 | "_objFlags": 0, 287 | "node": { 288 | "__id__": 3 289 | }, 290 | "_enabled": true, 291 | "_defaultClip": { 292 | "__uuid__": "27951031-6646-4fe1-a310-bd0422ec3369" 293 | }, 294 | "_clips": [ 295 | { 296 | "__uuid__": "27951031-6646-4fe1-a310-bd0422ec3369" 297 | } 298 | ], 299 | "playOnLoad": false, 300 | "_id": "" 301 | }, 302 | { 303 | "__type__": "cc.PrefabInfo", 304 | "root": { 305 | "__id__": 1 306 | }, 307 | "asset": { 308 | "__uuid__": "9791d6f0-1b5e-432b-a9eb-a7f910ddd632" 309 | }, 310 | "fileId": "5cLzINAztGdIR0WNtUjt/8", 311 | "sync": false 312 | }, 313 | { 314 | "__type__": "cc.Widget", 315 | "_name": "", 316 | "_objFlags": 0, 317 | "node": { 318 | "__id__": 2 319 | }, 320 | "_enabled": true, 321 | "alignMode": 0, 322 | "_target": null, 323 | "_alignFlags": 45, 324 | "_left": 35, 325 | "_right": 35, 326 | "_top": 35, 327 | "_bottom": 35, 328 | "_verticalCenter": 0, 329 | "_horizontalCenter": 0, 330 | "_isAbsLeft": true, 331 | "_isAbsRight": true, 332 | "_isAbsTop": true, 333 | "_isAbsBottom": true, 334 | "_isAbsHorizontalCenter": true, 335 | "_isAbsVerticalCenter": true, 336 | "_originalWidth": 0, 337 | "_originalHeight": 0, 338 | "_id": "" 339 | }, 340 | { 341 | "__type__": "cc.Mask", 342 | "_name": "", 343 | "_objFlags": 0, 344 | "node": { 345 | "__id__": 2 346 | }, 347 | "_enabled": true, 348 | "_materials": [ 349 | { 350 | "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" 351 | } 352 | ], 353 | "_spriteFrame": null, 354 | "_type": 1, 355 | "_segments": 64, 356 | "_N$alphaThreshold": 1, 357 | "_N$inverted": false, 358 | "_id": "" 359 | }, 360 | { 361 | "__type__": "cc.PrefabInfo", 362 | "root": { 363 | "__id__": 1 364 | }, 365 | "asset": { 366 | "__uuid__": "9791d6f0-1b5e-432b-a9eb-a7f910ddd632" 367 | }, 368 | "fileId": "d6i5lqrPxBp4YE38ylNHYT", 369 | "sync": false 370 | }, 371 | { 372 | "__type__": "cc.Node", 373 | "_name": "name", 374 | "_objFlags": 0, 375 | "_parent": { 376 | "__id__": 1 377 | }, 378 | "_children": [], 379 | "_active": true, 380 | "_level": 0, 381 | "_components": [ 382 | { 383 | "__id__": 12 384 | }, 385 | { 386 | "__id__": 13 387 | } 388 | ], 389 | "_prefab": { 390 | "__id__": 14 391 | }, 392 | "_opacity": 255, 393 | "_color": { 394 | "__type__": "cc.Color", 395 | "r": 24, 396 | "g": 21, 397 | "b": 21, 398 | "a": 255 399 | }, 400 | "_contentSize": { 401 | "__type__": "cc.Size", 402 | "width": 100, 403 | "height": 20 404 | }, 405 | "_anchorPoint": { 406 | "__type__": "cc.Vec2", 407 | "x": 0.5, 408 | "y": 0.5 409 | }, 410 | "_position": { 411 | "__type__": "cc.Vec3", 412 | "x": 0, 413 | "y": 0, 414 | "z": 0 415 | }, 416 | "_scale": { 417 | "__type__": "cc.Vec3", 418 | "x": 1, 419 | "y": 1, 420 | "z": 1 421 | }, 422 | "_eulerAngles": { 423 | "__type__": "cc.Vec3", 424 | "x": 0, 425 | "y": 0, 426 | "z": 0 427 | }, 428 | "_skewX": 0, 429 | "_skewY": 0, 430 | "_is3DNode": false, 431 | "groupIndex": 0, 432 | "_rotationX": 0, 433 | "_rotationY": 0, 434 | "_id": "" 435 | }, 436 | { 437 | "__type__": "cc.Label", 438 | "_name": "", 439 | "_objFlags": 0, 440 | "node": { 441 | "__id__": 11 442 | }, 443 | "_enabled": true, 444 | "_materials": [ 445 | { 446 | "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" 447 | } 448 | ], 449 | "_useOriginalSize": false, 450 | "_string": "小风吹的我乱了", 451 | "_N$string": "小风吹的我乱了", 452 | "_fontSize": 30, 453 | "_lineHeight": 30, 454 | "_enableWrapText": true, 455 | "_N$file": null, 456 | "_isSystemFontUsed": true, 457 | "_spacingX": 0, 458 | "_batchAsBitmap": false, 459 | "_N$horizontalAlign": 1, 460 | "_N$verticalAlign": 1, 461 | "_N$fontFamily": "Arial", 462 | "_N$overflow": 2, 463 | "_N$cacheMode": 0, 464 | "_id": "" 465 | }, 466 | { 467 | "__type__": "cc.Widget", 468 | "_name": "", 469 | "_objFlags": 0, 470 | "node": { 471 | "__id__": 11 472 | }, 473 | "_enabled": true, 474 | "alignMode": 0, 475 | "_target": null, 476 | "_alignFlags": 40, 477 | "_left": 35, 478 | "_right": 35, 479 | "_top": 0, 480 | "_bottom": 0, 481 | "_verticalCenter": 0, 482 | "_horizontalCenter": 0, 483 | "_isAbsLeft": true, 484 | "_isAbsRight": true, 485 | "_isAbsTop": true, 486 | "_isAbsBottom": true, 487 | "_isAbsHorizontalCenter": true, 488 | "_isAbsVerticalCenter": true, 489 | "_originalWidth": 48.94, 490 | "_originalHeight": 0, 491 | "_id": "" 492 | }, 493 | { 494 | "__type__": "cc.PrefabInfo", 495 | "root": { 496 | "__id__": 1 497 | }, 498 | "asset": { 499 | "__uuid__": "9791d6f0-1b5e-432b-a9eb-a7f910ddd632" 500 | }, 501 | "fileId": "a8fNWIUwZPJpQtpfjdGEJI", 502 | "sync": false 503 | }, 504 | { 505 | "__type__": "79099WqO8dLJomB2Yl76WAb", 506 | "_name": "", 507 | "_objFlags": 0, 508 | "node": { 509 | "__id__": 1 510 | }, 511 | "_enabled": true, 512 | "nameLabel": { 513 | "__id__": 12 514 | }, 515 | "avatarSprite": { 516 | "__id__": 4 517 | }, 518 | "defaultFrame": { 519 | "__uuid__": "f6450315-893a-4502-b54b-b088068c9072" 520 | }, 521 | "greenFrame": { 522 | "__uuid__": "8840bdd6-c341-4ad1-9113-5feb8f64b572" 523 | }, 524 | "yellowFrame": { 525 | "__uuid__": "d838d87c-dc65-4023-a2f8-d6eebe97ac6b" 526 | }, 527 | "redFrame": { 528 | "__uuid__": "88bfbfec-b8f6-40ed-a739-753fc39356da" 529 | }, 530 | "_id": "" 531 | }, 532 | { 533 | "__type__": "cc.Sprite", 534 | "_name": "", 535 | "_objFlags": 0, 536 | "node": { 537 | "__id__": 1 538 | }, 539 | "_enabled": true, 540 | "_materials": [ 541 | { 542 | "__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" 543 | } 544 | ], 545 | "_srcBlendFactor": 770, 546 | "_dstBlendFactor": 771, 547 | "_spriteFrame": { 548 | "__uuid__": "8840bdd6-c341-4ad1-9113-5feb8f64b572" 549 | }, 550 | "_type": 0, 551 | "_sizeMode": 0, 552 | "_fillType": 0, 553 | "_fillCenter": { 554 | "__type__": "cc.Vec2", 555 | "x": 0, 556 | "y": 0 557 | }, 558 | "_fillStart": 0, 559 | "_fillRange": 0, 560 | "_isTrimmedMode": false, 561 | "_atlas": null, 562 | "_id": "" 563 | }, 564 | { 565 | "__type__": "cc.Animation", 566 | "_name": "", 567 | "_objFlags": 0, 568 | "node": { 569 | "__id__": 1 570 | }, 571 | "_enabled": true, 572 | "_defaultClip": { 573 | "__uuid__": "05bf7653-a06b-4067-a19e-30892059871d" 574 | }, 575 | "_clips": [ 576 | { 577 | "__uuid__": "05bf7653-a06b-4067-a19e-30892059871d" 578 | } 579 | ], 580 | "playOnLoad": false, 581 | "_id": "" 582 | }, 583 | { 584 | "__type__": "cc.PrefabInfo", 585 | "root": { 586 | "__id__": 1 587 | }, 588 | "asset": { 589 | "__uuid__": "9791d6f0-1b5e-432b-a9eb-a7f910ddd632" 590 | }, 591 | "fileId": "7f2wsMZaNAX7DZERn0xk5f", 592 | "sync": false 593 | } 594 | ] -------------------------------------------------------------------------------- /assets/Prefab/entity.prefab.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.2.0", 3 | "uuid": "9791d6f0-1b5e-432b-a9eb-a7f910ddd632", 4 | "optimizationPolicy": "AUTO", 5 | "asyncLoadAssets": false, 6 | "readonly": false, 7 | "subMetas": {} 8 | } -------------------------------------------------------------------------------- /assets/Prefab/rankItem.prefab: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "__type__": "cc.Prefab", 4 | "_name": "", 5 | "_objFlags": 0, 6 | "_rawFiles": null, 7 | "data": { 8 | "__id__": 1 9 | } 10 | }, 11 | { 12 | "__type__": "cc.Node", 13 | "_name": "rankItem", 14 | "_objFlags": 0, 15 | "_parent": null, 16 | "_children": [ 17 | { 18 | "__id__": 2 19 | }, 20 | { 21 | "__id__": 5 22 | }, 23 | { 24 | "__id__": 8 25 | } 26 | ], 27 | "_tag": -1, 28 | "_active": true, 29 | "_components": [ 30 | { 31 | "__id__": 11 32 | }, 33 | { 34 | "__id__": 12 35 | } 36 | ], 37 | "_prefab": { 38 | "__id__": 13 39 | }, 40 | "_id": "", 41 | "_opacity": 255, 42 | "_color": { 43 | "__type__": "cc.Color", 44 | "r": 255, 45 | "g": 255, 46 | "b": 255, 47 | "a": 255 48 | }, 49 | "_cascadeOpacityEnabled": true, 50 | "_anchorPoint": { 51 | "__type__": "cc.Vec2", 52 | "x": 0.5, 53 | "y": 0.5 54 | }, 55 | "_contentSize": { 56 | "__type__": "cc.Size", 57 | "width": 900, 58 | "height": 63 59 | }, 60 | "_rotationX": 0, 61 | "_rotationY": 0, 62 | "_scaleX": 1, 63 | "_scaleY": 1, 64 | "_position": { 65 | "__type__": "cc.Vec2", 66 | "x": 0, 67 | "y": 189.5 68 | }, 69 | "_skewX": 0, 70 | "_skewY": 0, 71 | "_localZOrder": 0, 72 | "_globalZOrder": 0, 73 | "_opacityModifyRGB": false, 74 | "groupIndex": 0 75 | }, 76 | { 77 | "__type__": "cc.Node", 78 | "_name": "num", 79 | "_objFlags": 0, 80 | "_parent": { 81 | "__id__": 1 82 | }, 83 | "_children": [], 84 | "_tag": -1, 85 | "_active": true, 86 | "_components": [ 87 | { 88 | "__id__": 3 89 | } 90 | ], 91 | "_prefab": { 92 | "__id__": 4 93 | }, 94 | "_id": "", 95 | "_opacity": 255, 96 | "_color": { 97 | "__type__": "cc.Color", 98 | "r": 41, 99 | "g": 35, 100 | "b": 35, 101 | "a": 255 102 | }, 103 | "_cascadeOpacityEnabled": true, 104 | "_anchorPoint": { 105 | "__type__": "cc.Vec2", 106 | "x": 0, 107 | "y": 0.5 108 | }, 109 | "_contentSize": { 110 | "__type__": "cc.Size", 111 | "width": 391.15, 112 | "height": 40 113 | }, 114 | "_rotationX": 0, 115 | "_rotationY": 0, 116 | "_scaleX": 1, 117 | "_scaleY": 1, 118 | "_position": { 119 | "__type__": "cc.Vec2", 120 | "x": -435, 121 | "y": 0 122 | }, 123 | "_skewX": 0, 124 | "_skewY": 0, 125 | "_localZOrder": 0, 126 | "_globalZOrder": 0, 127 | "_opacityModifyRGB": false, 128 | "groupIndex": 0 129 | }, 130 | { 131 | "__type__": "cc.Label", 132 | "_name": "", 133 | "_objFlags": 0, 134 | "node": { 135 | "__id__": 2 136 | }, 137 | "_enabled": true, 138 | "_useOriginalSize": false, 139 | "_actualFontSize": 40, 140 | "_fontSize": 40, 141 | "_lineHeight": 40, 142 | "_enableWrapText": true, 143 | "_N$file": null, 144 | "_isSystemFontUsed": true, 145 | "_spacingX": 0, 146 | "_N$string": "1 小风吹的我乱了 ", 147 | "_N$horizontalAlign": 0, 148 | "_N$verticalAlign": 1, 149 | "_N$fontFamily": "Arial", 150 | "_N$overflow": 0 151 | }, 152 | { 153 | "__type__": "cc.PrefabInfo", 154 | "root": { 155 | "__id__": 1 156 | }, 157 | "asset": { 158 | "__uuid__": "1a78043b-6c75-4903-95f3-afe2940454ab" 159 | }, 160 | "fileId": "6aptCUTWNElrRfBS4pDRlo", 161 | "sync": false 162 | }, 163 | { 164 | "__type__": "cc.Node", 165 | "_name": "avatar", 166 | "_objFlags": 0, 167 | "_parent": { 168 | "__id__": 1 169 | }, 170 | "_children": [], 171 | "_tag": -1, 172 | "_active": true, 173 | "_components": [ 174 | { 175 | "__id__": 6 176 | } 177 | ], 178 | "_prefab": { 179 | "__id__": 7 180 | }, 181 | "_id": "", 182 | "_opacity": 255, 183 | "_color": { 184 | "__type__": "cc.Color", 185 | "r": 255, 186 | "g": 255, 187 | "b": 255, 188 | "a": 255 189 | }, 190 | "_cascadeOpacityEnabled": true, 191 | "_anchorPoint": { 192 | "__type__": "cc.Vec2", 193 | "x": 0.5, 194 | "y": 0.5 195 | }, 196 | "_contentSize": { 197 | "__type__": "cc.Size", 198 | "width": 60, 199 | "height": 60 200 | }, 201 | "_rotationX": 0, 202 | "_rotationY": 0, 203 | "_scaleX": 1, 204 | "_scaleY": 1, 205 | "_position": { 206 | "__type__": "cc.Vec2", 207 | "x": 0, 208 | "y": 0 209 | }, 210 | "_skewX": 0, 211 | "_skewY": 0, 212 | "_localZOrder": 0, 213 | "_globalZOrder": 0, 214 | "_opacityModifyRGB": false, 215 | "groupIndex": 0 216 | }, 217 | { 218 | "__type__": "cc.Sprite", 219 | "_name": "", 220 | "_objFlags": 0, 221 | "node": { 222 | "__id__": 5 223 | }, 224 | "_enabled": true, 225 | "_spriteFrame": { 226 | "__uuid__": "f6450315-893a-4502-b54b-b088068c9072" 227 | }, 228 | "_type": 0, 229 | "_sizeMode": 0, 230 | "_fillType": 0, 231 | "_fillCenter": { 232 | "__type__": "cc.Vec2", 233 | "x": 0, 234 | "y": 0 235 | }, 236 | "_fillStart": 0, 237 | "_fillRange": 0, 238 | "_isTrimmedMode": true, 239 | "_srcBlendFactor": 770, 240 | "_dstBlendFactor": 771, 241 | "_atlas": null 242 | }, 243 | { 244 | "__type__": "cc.PrefabInfo", 245 | "root": { 246 | "__id__": 1 247 | }, 248 | "asset": { 249 | "__uuid__": "1a78043b-6c75-4903-95f3-afe2940454ab" 250 | }, 251 | "fileId": "16YheiIEpEX5Ve6WCU0AH4", 252 | "sync": false 253 | }, 254 | { 255 | "__type__": "cc.Node", 256 | "_name": "score", 257 | "_objFlags": 0, 258 | "_parent": { 259 | "__id__": 1 260 | }, 261 | "_children": [], 262 | "_tag": -1, 263 | "_active": true, 264 | "_components": [ 265 | { 266 | "__id__": 9 267 | } 268 | ], 269 | "_prefab": { 270 | "__id__": 10 271 | }, 272 | "_id": "", 273 | "_opacity": 255, 274 | "_color": { 275 | "__type__": "cc.Color", 276 | "r": 41, 277 | "g": 35, 278 | "b": 35, 279 | "a": 255 280 | }, 281 | "_cascadeOpacityEnabled": true, 282 | "_anchorPoint": { 283 | "__type__": "cc.Vec2", 284 | "x": 0.5, 285 | "y": 0.5 286 | }, 287 | "_contentSize": { 288 | "__type__": "cc.Size", 289 | "width": 133.44, 290 | "height": 40 291 | }, 292 | "_rotationX": 0, 293 | "_rotationY": 0, 294 | "_scaleX": 1, 295 | "_scaleY": 1, 296 | "_position": { 297 | "__type__": "cc.Vec2", 298 | "x": 351, 299 | "y": 0 300 | }, 301 | "_skewX": 0, 302 | "_skewY": 0, 303 | "_localZOrder": 0, 304 | "_globalZOrder": 0, 305 | "_opacityModifyRGB": false, 306 | "groupIndex": 0 307 | }, 308 | { 309 | "__type__": "cc.Label", 310 | "_name": "", 311 | "_objFlags": 0, 312 | "node": { 313 | "__id__": 8 314 | }, 315 | "_enabled": true, 316 | "_useOriginalSize": false, 317 | "_actualFontSize": 40, 318 | "_fontSize": 40, 319 | "_lineHeight": 40, 320 | "_enableWrapText": true, 321 | "_N$file": null, 322 | "_isSystemFontUsed": true, 323 | "_spacingX": 0, 324 | "_N$string": "10 50", 325 | "_N$horizontalAlign": 2, 326 | "_N$verticalAlign": 1, 327 | "_N$fontFamily": "Arial", 328 | "_N$overflow": 0 329 | }, 330 | { 331 | "__type__": "cc.PrefabInfo", 332 | "root": { 333 | "__id__": 1 334 | }, 335 | "asset": { 336 | "__uuid__": "1a78043b-6c75-4903-95f3-afe2940454ab" 337 | }, 338 | "fileId": "5adQpssBhGCbUaiVa/OrRy", 339 | "sync": false 340 | }, 341 | { 342 | "__type__": "cc.Sprite", 343 | "_name": "", 344 | "_objFlags": 0, 345 | "node": { 346 | "__id__": 1 347 | }, 348 | "_enabled": true, 349 | "_spriteFrame": { 350 | "__uuid__": "5e0c3ee3-69e9-4912-af4a-ad01c98a3fed" 351 | }, 352 | "_type": 0, 353 | "_sizeMode": 1, 354 | "_fillType": 0, 355 | "_fillCenter": { 356 | "__type__": "cc.Vec2", 357 | "x": 0, 358 | "y": 0 359 | }, 360 | "_fillStart": 0, 361 | "_fillRange": 0, 362 | "_isTrimmedMode": true, 363 | "_srcBlendFactor": 770, 364 | "_dstBlendFactor": 771, 365 | "_atlas": null 366 | }, 367 | { 368 | "__type__": "bf0abt0A+RNkYNG/EVihaS7", 369 | "_name": "", 370 | "_objFlags": 0, 371 | "node": { 372 | "__id__": 1 373 | }, 374 | "_enabled": true, 375 | "nameLabel": { 376 | "__id__": 3 377 | }, 378 | "avatarSprite": { 379 | "__id__": 6 380 | }, 381 | "scoreLabel": { 382 | "__id__": 9 383 | } 384 | }, 385 | { 386 | "__type__": "cc.PrefabInfo", 387 | "root": { 388 | "__id__": 1 389 | }, 390 | "asset": { 391 | "__uuid__": "1a78043b-6c75-4903-95f3-afe2940454ab" 392 | }, 393 | "fileId": "f9q8DXJ+5M2JP8PCXQmsv6", 394 | "sync": false 395 | } 396 | ] -------------------------------------------------------------------------------- /assets/Prefab/rankItem.prefab.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.2.0", 3 | "uuid": "1a78043b-6c75-4903-95f3-afe2940454ab", 4 | "optimizationPolicy": "AUTO", 5 | "asyncLoadAssets": false, 6 | "readonly": false, 7 | "subMetas": {} 8 | } -------------------------------------------------------------------------------- /assets/Scene.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.1", 3 | "uuid": "29f52784-2fca-467b-92e7-8fd9ef8c57b7", 4 | "isGroup": false, 5 | "subMetas": {} 6 | } -------------------------------------------------------------------------------- /assets/Scene/end.fire.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.2.0", 3 | "uuid": "7488eaf1-0160-4761-ae17-016de1e5c86c", 4 | "asyncLoadAssets": false, 5 | "autoReleaseAssets": false, 6 | "subMetas": {} 7 | } -------------------------------------------------------------------------------- /assets/Scene/game.fire.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.2.0", 3 | "uuid": "2d2f792f-a40c-49bb-a189-ed176a246e49", 4 | "asyncLoadAssets": false, 5 | "autoReleaseAssets": false, 6 | "subMetas": {} 7 | } -------------------------------------------------------------------------------- /assets/Scene/start.fire.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.2.0", 3 | "uuid": "991efca1-4933-478e-b0b0-00c9e48fbbf6", 4 | "asyncLoadAssets": false, 5 | "autoReleaseAssets": false, 6 | "subMetas": {} 7 | } -------------------------------------------------------------------------------- /assets/Script.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.1", 3 | "uuid": "4734c20c-0db8-4eb2-92ea-e692f4d70934", 4 | "isGroup": false, 5 | "subMetas": {} 6 | } -------------------------------------------------------------------------------- /assets/Script/ActionLayer.js: -------------------------------------------------------------------------------- 1 | 2 | cc.Class({ 3 | extends: cc.Component, 4 | 5 | properties: { 6 | joy: cc.Node, 7 | // foo: { 8 | // default: null, // The default value will be used only when the component attaching 9 | // to a node for the first time 10 | // url: cc.Texture2D, // optional, default is typeof default 11 | // serializable: true, // optional, default is true 12 | // visible: true, // optional, default is true 13 | // displayName: 'Foo', // optional 14 | // readonly: false, // optional, default is false 15 | // }, 16 | // ... 17 | }, 18 | 19 | // use this for initialization 20 | onLoad: function () { 21 | // this.node.on(cc.Node.EventType.MOUSE_DOWN, function (event) { 22 | // if (this._managerJS) { 23 | // this._managerJS.shootBullet(event.getLocationX(), event.getLocationY()); 24 | // } 25 | // }, this); 26 | this.node.on(cc.Node.EventType.TOUCH_START, function (event) { 27 | if (this._managerJS) { 28 | this._managerJS.sendShootMessage(event.getLocationX(), event.getLocationY()); 29 | } 30 | }, this); 31 | // add key down and key up event 32 | cc.systemEvent.on(cc.SystemEvent.EventType.KEY_DOWN, this.onKeyDown, this); 33 | cc.systemEvent.on(cc.SystemEvent.EventType.KEY_UP, this.onKeyUp, this); 34 | this._joyJS = this.joy.getComponent('JoyStick'); 35 | }, 36 | clickShoot() { 37 | if (this._managerJS) { 38 | this._managerJS.sendShootMessage(); 39 | } 40 | }, 41 | clickJump() { 42 | if (this._managerJS) { 43 | this._managerJS.sendJumpMessage(); 44 | } 45 | }, 46 | hide() { 47 | this.node.active = false; 48 | }, 49 | show() { 50 | this.node.active = true; 51 | }, 52 | onDestroy() { 53 | cc.systemEvent.off(cc.SystemEvent.EventType.KEY_DOWN, this.onKeyDown, this); 54 | cc.systemEvent.off(cc.SystemEvent.EventType.KEY_UP, this.onKeyUp, this); 55 | }, 56 | getTargetRotation() { 57 | if (this.keyLeft) { 58 | return 180; 59 | } else if (this.keyRight) { 60 | return 0; 61 | } else if (this.keyUp) { 62 | return 90; 63 | } else if (this.keyDown) { 64 | return -90; 65 | } else { 66 | return this._joyJS.getTargetAngle(); 67 | } 68 | }, 69 | onKeyDown: function (event) { 70 | switch (event.keyCode) { 71 | case cc.macro.KEY.left: 72 | { 73 | this.keyLeft = true; 74 | break; 75 | } 76 | case cc.macro.KEY.right: 77 | { 78 | this.keyRight = true; 79 | break; 80 | } 81 | case cc.macro.KEY.up: 82 | { 83 | this.keyUp = true; 84 | break; 85 | } 86 | case cc.macro.KEY.down: 87 | { 88 | this.keyDown = true; 89 | break; 90 | } 91 | 92 | } 93 | }, 94 | onKeyUp: function (event) { 95 | switch (event.keyCode) { 96 | case cc.macro.KEY.left: 97 | { 98 | this.keyLeft = false; 99 | break; 100 | } 101 | case cc.macro.KEY.right: 102 | { 103 | this.keyRight = false; 104 | break; 105 | } 106 | case cc.macro.KEY.up: 107 | { 108 | this.keyUp = false; 109 | break; 110 | } 111 | case cc.macro.KEY.down: 112 | { 113 | this.keyDown = false; 114 | break; 115 | } 116 | } 117 | }, 118 | }); 119 | -------------------------------------------------------------------------------- /assets/Script/ActionLayer.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "f11aa42a-c11f-4b55-86c1-06b94e577d4e", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/Alert.js: -------------------------------------------------------------------------------- 1 | //var Global = require('Global'); 2 | cc.Class({ 3 | extends: cc.Component, 4 | 5 | properties: { 6 | label: cc.Label, 7 | btnLayer_OK: cc.Node, 8 | btnLayer_OKCancel: cc.Node, 9 | // foo: { 10 | // default: null, // The default value will be used only when the component attaching 11 | // to a node for the first time 12 | // url: cc.Texture2D, // optional, default is typeof default 13 | // serializable: true, // optional, default is true 14 | // visible: true, // optional, default is true 15 | // displayName: 'Foo', // optional 16 | // readonly: false, // optional, default is false 17 | // }, 18 | // ... 19 | }, 20 | 21 | // use this for initialization 22 | onLoad: function () { 23 | }, 24 | setString: function (msg) { 25 | this.label.string = msg; 26 | }, 27 | setType: function (type) { 28 | switch (type) { 29 | case G.AT.OK: { 30 | this.btnLayer_OKCancel.active = false; 31 | break; 32 | } 33 | case G.AT.OK_CANCEL: { 34 | this.btnLayer_OK.active = false; 35 | break; 36 | } 37 | default: { 38 | cc.assert(false); 39 | } 40 | } 41 | }, 42 | setCallBack(okCallback, cancelCallback) { 43 | this.okCallback = null; 44 | this.cancelCallback = null; 45 | if (okCallback && typeof (okCallback) === "function") { 46 | this.okCallback = okCallback; 47 | } 48 | if (cancelCallback && typeof (cancelCallback) === "function") { 49 | this.cancelCallback = cancelCallback; 50 | } 51 | }, 52 | clickOKButton: function () { 53 | if (this.okCallback) { 54 | this.okCallback(); 55 | } 56 | this.node.destroy(); 57 | }, 58 | clickCancelButton: function () { 59 | if (this.cancelCallback) { 60 | this.cancelCallback(); 61 | } 62 | this.node.destroy(); 63 | }, 64 | // called every frame, uncomment this function to activate update callback 65 | // update: function (dt) { 66 | 67 | // }, 68 | }); 69 | -------------------------------------------------------------------------------- /assets/Script/Alert.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "1df9574e-a07a-422d-a509-43b5d0fce720", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/Bullet.js: -------------------------------------------------------------------------------- 1 | // Learn cc.Class: 2 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/class.html 3 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/class/index.html 4 | // Learn Attribute: 5 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/reference/attributes.html 6 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/reference/attributes/index.html 7 | // Learn life-cycle callbacks: 8 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/life-cycle-callbacks.html 9 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/life-cycle-callbacks/index.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 | start() { 37 | 38 | }, 39 | init(info) { 40 | this.node.x = info.x; 41 | this.node.y = info.y; 42 | this.rotation = info.rotation; 43 | //this.node.rotation = -this.rotation + 180; 44 | this.node.angle = this.rotation-180; 45 | this.bulletID = info.bulletID; 46 | this.creatorID = info.creatorID; 47 | this.createTime = new Date().getTime(); 48 | this.radian = this.rotation * Math.PI / 180; 49 | }, 50 | 51 | update(dt) { 52 | this.node.x += G.config.bulletSpeed * dt * Math.cos(this.radian); 53 | this.node.y += G.config.bulletSpeed * dt * Math.sin(this.radian); 54 | }, 55 | }); 56 | -------------------------------------------------------------------------------- /assets/Script/Bullet.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "30d2f720-32c4-4278-91c3-8421ff46bb69", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/CmdLogon.js: -------------------------------------------------------------------------------- 1 | var constant = { 2 | OVER_REASON_KILLED: 1, 3 | OVER_REASON_NORMAL: 2, 4 | OVER_REASON_OFFLINE: 3, 5 | 6 | ACCOUNT_TYPE_VISITOR: 1, 7 | ACCOUNT_TYPE_WX: 2, 8 | ACCOUNT_TYPE_ROBOT: 3, 9 | }; 10 | 11 | 12 | module.exports = constant -------------------------------------------------------------------------------- /assets/Script/CmdLogon.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "8f5526be-185d-4ac3-a573-a48d7bfa89bd", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/EndCtrl.js: -------------------------------------------------------------------------------- 1 | // Learn cc.Class: 2 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/class.html 3 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/class/index.html 4 | // Learn Attribute: 5 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/reference/attributes.html 6 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/reference/attributes/index.html 7 | // Learn life-cycle callbacks: 8 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/life-cycle-callbacks.html 9 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/life-cycle-callbacks/index.html 10 | var NetCtrl = require('NetCtrl'); 11 | var Cmd = require('CmdLogon'); 12 | cc.Class({ 13 | extends: cc.Component, 14 | 15 | properties: { 16 | statusLabel: cc.Label, 17 | startBtn: cc.Button, 18 | clockLabel: cc.Label, 19 | rankContent: cc.Node, 20 | rankMeItem: cc.Node, 21 | randItemPrefab: cc.Prefab, 22 | killerPos: cc.Node, 23 | entityPrefab: cc.Prefab, 24 | }, 25 | onLoad() { 26 | let gameEnd = G.gameEnd; 27 | if (gameEnd.overReason === Cmd.OVER_REASON_OFFLINE) { 28 | this.setStatusInfo('断网了,重连?'); 29 | } else if (gameEnd.overReason === Cmd.OVER_REASON_KILLED) { 30 | this.setStatusInfo('击杀了你!请等待下一轮开始'); 31 | this.startBtn.interactable = false; 32 | this.leftTime = gameEnd.gameLeftSec+1; 33 | this.failTime = new Date().getTime(); 34 | this.setLeftClock(); 35 | 36 | let killer = cc.instantiate(this.entityPrefab); 37 | killer.getComponent('Entity').init(gameEnd.killer); 38 | killer.position = cc.v2(0, 0); 39 | this.killerPos.addChild(killer); 40 | let rank = 0; 41 | for (let i = 0; i < gameEnd.rank.list.length; i++) { 42 | let itemData = gameEnd.rank.list[i]; 43 | itemData.rank = i + 1; 44 | //let string = item.rank + ":" + item.score + "score," + item.name; 45 | let slot = cc.instantiate(this.randItemPrefab); 46 | //slot.getComponent(cc.Label).string = string; 47 | slot.getComponent("RankItem").setItemData(itemData); 48 | this.rankContent.addChild(slot); 49 | // if (itemData.entityID === G.entityID) { 50 | // rank = itemData.rank; 51 | // this.rankMeItem.getComponent("RankItem").setItemData(itemData); 52 | // } 53 | } 54 | } else { 55 | let rank = 0; 56 | for (let i = 0; i < gameEnd.rank.list.length; i++) { 57 | let itemData = gameEnd.rank.list[i]; 58 | itemData.rank = i + 1; 59 | //let string = item.rank + ":" + item.score + "score," + item.name; 60 | let slot = cc.instantiate(this.randItemPrefab); 61 | //slot.getComponent(cc.Label).string = string; 62 | slot.getComponent("RankItem").setItemData(itemData); 63 | this.rankContent.addChild(slot); 64 | if (itemData.entityID === G.entityID) { 65 | rank = itemData.rank; 66 | // this.rankMeItem.getComponent("RankItem").setItemData(itemData); 67 | } 68 | } 69 | let string = "您当场排名第" + rank + ',再战一局?'; 70 | this.setStatusInfo(string); 71 | } 72 | }, 73 | clickRestartBtn(){ 74 | cc.director.loadScene("start",function(){ 75 | //var scene = cc.director.getScene(); 76 | let canvas = cc.director.getScene().getChildByName('Canvas'); 77 | let startLayer = canvas.getChildByName("startLayer"); 78 | let startLayerJS = startLayer.getComponent("StartLayer"); 79 | startLayerJS.clickJoinGame(); 80 | }); 81 | }, 82 | // clickStartBtn() { 83 | // NetCtrl.createNewSocket(() => { 84 | // NetCtrl.Send("cmsg.ReLogin",{token:G.userInfo.token}); 85 | // }); 86 | // }, 87 | // clickJoinGame() { 88 | // cc.log("click join"); 89 | // NetCtrl.createNewSocket(() => { 90 | // NetCtrl.Send("cmsg.ReqJoinGame",{nickname:G.userInfo.nickname}); 91 | // }); 92 | // }, 93 | clockCallback() { 94 | let count = parseInt(this.leftTime - (new Date().getTime() - this.failTime) / 1000); 95 | if (count <= 0) { 96 | this.unschedule(this.clockCallback); 97 | // this.setStatusInfo(''); 98 | this.clockLabel.string = ''; 99 | this.startBtn.interactable = true; 100 | } else { 101 | this.clockLabel.string = count; 102 | } 103 | }, 104 | setStatusInfo(string) { 105 | this.statusLabel.string = string; 106 | }, 107 | setLeftClock() { 108 | this.unschedule(this.clockCallback); 109 | this.clockLabel.string = this.leftTime; 110 | this.schedule(this.clockCallback, 1); 111 | }, 112 | }); 113 | -------------------------------------------------------------------------------- /assets/Script/EndCtrl.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "f596b82e-20a0-4009-842d-4ec7c1ce1813", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/Entity.js: -------------------------------------------------------------------------------- 1 | var Config = require('GlobalConfig'); 2 | cc.Class({ 3 | extends: cc.Component, 4 | 5 | properties: { 6 | // foo: { 7 | // default: null, // The default value will be used only when the component attaching 8 | // to a node for the first time 9 | // url: cc.Texture2D, // optional, default is typeof default 10 | // serializable: true, // optional, default is true 11 | // visible: true, // optional, default is true 12 | // displayName: 'Foo', // optional 13 | // readonly: false, // optional, default is false 14 | // }, 15 | // ... 16 | nameLabel: cc.Label, 17 | // scoreLabel: cc.Label, 18 | avatarSprite: cc.Sprite, 19 | defaultFrame: cc.SpriteFrame, 20 | greenFrame: cc.SpriteFrame, 21 | yellowFrame: cc.SpriteFrame, 22 | redFrame: cc.SpriteFrame, 23 | // deadClip: cc.AudioClip, 24 | }, 25 | 26 | // use this for initialization 27 | onLoad: function () { 28 | 29 | }, 30 | showAvatar(headImgUrl) { 31 | let self = this; 32 | if (headImgUrl && headImgUrl != ' ') { 33 | let imgurl = headImgUrl.substr(0, headImgUrl.length - 1) + "96"; 34 | cc.loader.load({ 35 | url: imgurl, type: 'jpg' 36 | }, function (err, texture) { 37 | if (err) { 38 | // self.showOriginAvatar(); 39 | } else { 40 | self.avatarSprite.spriteFrame = new cc.SpriteFrame(texture); 41 | } 42 | }); 43 | } else { 44 | //self.showOriginAvatar(); 45 | } 46 | }, 47 | applyInput(input) { 48 | let targetRotation = input.targetRotation; 49 | let lastRotation = this.rotation; 50 | let pressTime = input.pressTime; 51 | let newRotation = lastRotation; 52 | let rotationDelta = Math.abs(targetRotation - lastRotation); 53 | if (rotationDelta >= 180) { 54 | rotationDelta = Math.abs(360 - rotationDelta); 55 | } 56 | if (rotationDelta <= pressTime * G.config.rotationDelta) { 57 | newRotation = targetRotation; 58 | } else { 59 | let rotationChange = 0; 60 | if (this.rotation >= 0) { 61 | if (this.rotation - 180 < targetRotation && targetRotation < this.rotation) { 62 | rotationChange = -pressTime * G.config.rotationDelta; 63 | } else { 64 | rotationChange = pressTime * G.config.rotationDelta; 65 | } 66 | } else { 67 | if (this.rotation < targetRotation && targetRotation < this.rotation + 180) { 68 | rotationChange = pressTime * G.config.rotationDelta; 69 | } else { 70 | rotationChange = -pressTime * G.config.rotationDelta;; 71 | } 72 | } 73 | newRotation = lastRotation + rotationChange; 74 | } 75 | 76 | if (newRotation > 180) newRotation = newRotation - 360; 77 | if (newRotation < -180) newRotation = 360 + newRotation; 78 | 79 | let distance = input.pressTime * G.config.entitySpeed; 80 | let radian = lastRotation * Math.PI / 180; 81 | this.node.y += distance * Math.sin(radian); 82 | this.node.x += distance * Math.cos(radian); 83 | this.rotation = newRotation; 84 | // this.node.rotation = -this.rotation; 85 | this.node.angle = this.rotation; 86 | }, 87 | init(info) { 88 | // this.entityID = info.entityID; 89 | //this.rotation = -info.rotation; 90 | this.rotation = info.rotation; 91 | this.node.x = info.x; 92 | this.node.y = info.y; 93 | this.positionBuffer = new Array(); 94 | this.node.color = cc.Color.WHITE; 95 | this.nickname = info.nickname; 96 | this.nameLabel.string = info.nickname; 97 | this.score = 0; 98 | this.killCount = 0; 99 | if (info.protected) { 100 | this.getComponent(cc.Animation).play(); 101 | } 102 | this.entityID = info.id; 103 | this.dead = info.dead; 104 | this.applyDisplay(info); 105 | if (info.accountType === 2) { 106 | this.showAvatar(info.headImgUrl); 107 | } else { 108 | this.avatarSprite.spriteFrame = this.defaultFrame; 109 | } 110 | }, 111 | applyDisplay(data) { 112 | this.hp = data.hp; 113 | this.score = data.score; 114 | let color = cc.Color.WHITE; 115 | if (this.hp <= 2) { 116 | this.getComponent(cc.Sprite).spriteFrame = this.redFrame; 117 | } else if (this.hp <= 4) { 118 | this.getComponent(cc.Sprite).spriteFrame = this.yellowFrame; 119 | } else { 120 | this.getComponent(cc.Sprite).spriteFrame = this.greenFrame; 121 | } 122 | this.avatarSprite.node.color = color; 123 | //this.scoreLabel.string = this.score; 124 | }, 125 | startProtect() { 126 | this.scheduleOnce(() => { 127 | cc.log("protect cancel"); 128 | }, G.config.protectTime); 129 | }, 130 | playDeadAni() { 131 | var anim = this.avatarSprite.getComponent(cc.Animation); 132 | //var animName = self.node.name + 'ani'; 133 | anim.play(); 134 | anim.on('finished', this.onFinished, this); 135 | //播放音效 136 | //cc.audioEngine.playEffect(this.deadClip, false); 137 | }, 138 | onFinished() { 139 | if (this.entityID === G.entityID) { 140 | // cc.director.loadScene('end'); 141 | } else { 142 | this._managerJS.entityDied(this.node); 143 | } 144 | } 145 | 146 | }); 147 | -------------------------------------------------------------------------------- /assets/Script/Entity.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "790995aa-3bc7-4b26-8981-d9897be9601b", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/GameCtrl.js: -------------------------------------------------------------------------------- 1 | var NetCtrl = require('NetCtrl'); 2 | var Cmd = require('CmdLogon'); 3 | var Config = require('GlobalConfig'); 4 | var Util = require('Util'); 5 | 6 | cc.Class({ 7 | extends: cc.Component, 8 | 9 | properties: { 10 | entityPrefab: cc.Prefab, 11 | bulletPrefab: cc.Prefab, 12 | canvas: cc.Node, 13 | entityLayer: cc.Node, 14 | bulletLayer: cc.Node, 15 | actionLayer: cc.Node, 16 | showingLayer: cc.Node, 17 | camera: cc.Node, 18 | 19 | clientPrediction: false, 20 | serverReconciliation: false, 21 | interpolation: false, 22 | bulletClip: { 23 | type:cc.AudioClip, 24 | default:null, 25 | }, 26 | bombClip: { 27 | type:cc.AudioClip, 28 | default:null, 29 | }, 30 | }, 31 | // use this for initialization 32 | onLoad: function () { 33 | NetCtrl.dataEventHandler = this.node; 34 | this.node.on('netmsg',this.onNetMsg,this); 35 | 36 | this._actionLayerJS = this.actionLayer.getComponent('ActionLayer'); 37 | this._actionLayerJS._managerJS = this; 38 | this._showingLayerJS = this.showingLayer.getComponent('ShowingLayer'); 39 | 40 | //初始参数 41 | this.entityMap = new Map(); 42 | this.bulletMap = new Map(); 43 | 44 | //使用对象池 45 | this.entityPool = new cc.NodePool(); 46 | this.bulletPool = new cc.NodePool(); 47 | for (let i = 0; i < 10; i++) { 48 | let entity = cc.instantiate(this.entityPrefab); 49 | this.entityPool.put(entity); 50 | } 51 | 52 | for (let i = 0; i < 20; i++) { 53 | let bullet = cc.instantiate(this.bulletPrefab); 54 | this.bulletPool.put(bullet); 55 | } 56 | 57 | this.init(); 58 | }, 59 | sendShootMessage(worldX, worldY) { 60 | let now = new Date().getTime(); 61 | if (now - this.lastShootTime < 600) return; 62 | this.lastShootTime = now; 63 | NetCtrl.Send("ReqShoot"); 64 | //NetCtrl.sendCmd(Cmd.MDM_GF_GAME, Cmd.SUB_MB_SHOOT); 65 | }, 66 | sendJumpMessage() { 67 | NetCtrl.Send("ReqJump"); 68 | // NetCtrl.sendCmd(Cmd.MDM_GF_GAME, Cmd.SUB_MB_JUMP); 69 | }, 70 | createEntity(info) { 71 | let entity = null; 72 | if (this.entityPool.size() > 0) { 73 | entity = this.entityPool.get(); 74 | } else { 75 | entity = cc.instantiate(this.entityPrefab); 76 | } 77 | entity.parent = this.entityLayer; 78 | let entityJS = entity.getComponent('Entity'); 79 | entityJS._managerJS = this; 80 | entityJS.init(info); 81 | this.entityMap.set(info.id, entityJS); 82 | return entityJS; 83 | }, 84 | createBullet(info) { 85 | let bullet = null; 86 | if (this.bulletPool.size() > 0) { 87 | bullet = this.bulletPool.get(); 88 | } else { 89 | bullet = cc.instantiate(this.bulletPrefab); 90 | } 91 | bullet.parent = this.bulletLayer; 92 | let bulletJS = bullet.getComponent('Bullet'); 93 | bulletJS.init(info); 94 | this.bulletMap.set(info.bulletID, bulletJS); 95 | return bulletJS; 96 | }, 97 | init() { 98 | this.sceneReady = false; 99 | this.inputSequenceNumber = 0; 100 | this.pendingInputs = []; 101 | this.entityMap.clear(); 102 | this.bulletMap.clear(); 103 | this.entityLayer.removeAllChildren(); 104 | this.bulletLayer.removeAllChildren(); 105 | this.lastShootTime = 0; 106 | this.pressTime = 0; 107 | NetCtrl.Send("ReqGameScene") 108 | //NetCtrl.sendCmd(Cmd.MDM_GF_GAME, Cmd.SUB_MB_GAME_SCENE); 109 | }, 110 | entityDied(node) { 111 | this.entityPool.put(node); 112 | }, 113 | onNetMsg: function (msg) { 114 | //msg = msg.detail; 115 | var data = msg.data; 116 | //if (this.sceneReady === false && msg.subID !== Cmd.SUB_MB_GAME_SCENE) return; 117 | switch (msg.msgName) { 118 | case "RespGameScene": { 119 | if (data.err!="Invalid"){ 120 | cc.log(data.err); 121 | return 122 | } 123 | this.sceneReady = true; 124 | this._showingLayerJS.setLeftClock(data.gameLeftSec); 125 | for (let i = 0; i < data.entities.length; i++) { 126 | this.createEntity(data.entities[i]); 127 | } 128 | this.schedule(this.calculateRank, 2); 129 | } 130 | case "SNoticeWorldChange": { 131 | if (data.deleteEntities) { 132 | for (let i = 0; i < data.deleteEntities.length; i++) { 133 | let entityID = data.deleteEntities[i]; 134 | if (G.entityID === entityID) { 135 | } else { 136 | let itemJS = this.entityMap.get(entityID); 137 | itemJS.playDeadAni(); 138 | this.playBombEffect(entityID); 139 | this.entityMap.delete(entityID); 140 | } 141 | } 142 | } 143 | 144 | if (data.deleteBullets) { 145 | for (let i = 0; i < data.deleteBullets.length; i++) { 146 | let bulletID = data.deleteBullets[i]; 147 | if (this.bulletMap.has(bulletID)) { 148 | let itemJS = this.bulletMap.get(bulletID); 149 | this.bulletMap.delete(bulletID); 150 | this.bulletPool.put(itemJS.node); 151 | } 152 | } 153 | } 154 | 155 | if (data.changedEntities) { 156 | for (let i = 0; i < data.changedEntities.length; i++) { 157 | let item = data.changedEntities[i]; 158 | let entityID = item.id; 159 | let itemJS = this.entityMap.get(entityID); 160 | if (entityID === G.entityID && item.score !== itemJS.score) { 161 | this._showingLayerJS.showGetScore(item.score - itemJS.score); 162 | } 163 | itemJS.applyDisplay(item); 164 | } 165 | } 166 | 167 | break; 168 | } 169 | case "SNoticeNewEntity": { 170 | let entity = data.entity 171 | if (entity.id === G.entityID) return; 172 | if (this.entityMap.has(entity.id)) return; 173 | this.createEntity(entity); 174 | break; 175 | } 176 | //接受所有玩家的状态 177 | case "SNoticeWorldPos": { 178 | let now = new Date().getTime(); 179 | if (data.entities) { 180 | for (let i = 0; i < data.entities.length; i++) { 181 | let item = data.entities[i]; 182 | let entityID = item.id; 183 | let entityJS = this.entityMap.get(entityID); 184 | //entityJS.applyInfo(item); 185 | //如果是我 186 | if (entityID=== G.entityID) { 187 | entityJS.node.x = item.x; 188 | entityJS.node.y = item.y; 189 | entityJS.rotation = item.rotation; 190 | entityJS.node.angle = item.rotation; 191 | if (this.serverReconciliation) { 192 | let j = 0; 193 | while (j < this.pendingInputs.length) { 194 | let input = this.pendingInputs[j]; 195 | if (input.inputSeqID <= data.lastProcessedInputID) { 196 | this.pendingInputs.splice(j, 1); 197 | } else { 198 | entityJS.applyInput(input); 199 | j++; 200 | } 201 | } 202 | } else { 203 | this.pendingInputs = []; 204 | } 205 | } else { 206 | if (this.interpolation) { 207 | let timestamp = new Date().getTime(); 208 | entityJS.positionBuffer.push([timestamp, item.x, item.y, item.rotation]); 209 | } else { 210 | entityJS.node.x = item.x; 211 | entityJS.node.y = item.y; 212 | entityJS.node.angle = item.rotation; 213 | } 214 | } 215 | 216 | } 217 | } 218 | break; 219 | } 220 | case "SNoticeShoot": { 221 | this.createBullet(data); 222 | this.playBulletEffect(data.creatorEntityID); 223 | break; 224 | } 225 | case "RespPing":{ 226 | break; 227 | } 228 | case "SNoticeGameOver": { 229 | this.unschedule(this.calculateRank); 230 | this._actionLayerJS.hide(); 231 | //NetCtrl.close(); 232 | this.sceneReady = false; 233 | //play anim and turn to "end" scene 234 | G.gameEnd = data; 235 | if (data.overReason === Cmd.OVER_REASON_KILLED) { 236 | this.entityMap.get(G.entityID).playDeadAni(); 237 | this.playBombEffect(G.entityID); 238 | let objArr = new Array(); 239 | this.entityMap.forEach(function (entityJS, key, mapObj) { 240 | if (entityJS.dead === false) { 241 | let obj = {}; 242 | obj.entityID = key; 243 | obj.score = entityJS.score; 244 | obj.nickname = entityJS.nickname; 245 | obj.killCount = entityJS.killCount; 246 | obj.headImgUrl = entityJS.headImgUrl; 247 | obj.accountType = entityJS.accountType; 248 | objArr.push(obj); 249 | } 250 | }); 251 | objArr.sort(function (a, b) { 252 | if (a.score < b.score) { 253 | return 1; 254 | } else if (a.score > b.score) { 255 | return -1; 256 | } else { 257 | return a.entityID > b.entityID; 258 | } 259 | }); 260 | // let rank = {list:objArr}; 261 | G.gameEnd.rank={list:objArr}; 262 | } else { 263 | // for (let i = 0; i < data.rankInfo.length; i++) { 264 | // let item = data.rankInfo[i]; 265 | // item.name = this.entityMap.get(item.entityID).name; 266 | // } 267 | } 268 | this.playGameEnd(); 269 | break; 270 | } 271 | } 272 | return; 273 | }, 274 | playGameEnd() { 275 | this.schedule(this.scheduleCamera, 0.02); 276 | }, 277 | scheduleCamera() { 278 | let targetPos = {}; 279 | targetPos.x = 1280; 280 | targetPos.y = 720; 281 | let position = this.camera.parent.convertToNodeSpaceAR(targetPos); 282 | this.camera.x = (position.x + this.camera.x) / 2; 283 | this.camera.y = (position.y + this.camera.y) / 2; 284 | let camera = this.camera.getComponent(cc.Camera); 285 | // cc.log(camera.zoomRatio); 286 | camera.zoomRatio -= 0.02; 287 | if (camera.zoomRatio <= 0.5) { 288 | this.unschedule(this.scheduleCamera); 289 | this.scheduleOnce(function () { 290 | cc.director.loadScene('end'); 291 | }, 1.5); 292 | } 293 | }, 294 | playBulletEffect(creatorID) { 295 | let entityA = this.entityMap.get(creatorID); 296 | if (!entityA){ 297 | cc.log("playBulletEffect entityID not exist",creatorID) 298 | return 299 | } 300 | let nodeA = entityA.node; 301 | let nodeB = this.entityMap.get(G.entityID).node; 302 | let distance = nodeA.position.sub(nodeB.position).mag() 303 | //let distance = cc.pDistance(nodeA.position, nodeB.position); 304 | if (distance <= 500) { 305 | let volume = 1.0; 306 | if (distance > 100) { 307 | volume = 100 / distance; 308 | } 309 | cc.audioEngine.play(this.bulletClip, false, volume); 310 | } 311 | }, 312 | playBombEffect(entityID) { 313 | let nodeA = this.entityMap.get(entityID).node; 314 | let nodeB = this.entityMap.get(G.entityID).node; 315 | let distance = nodeA.position.sub(nodeB.position).mag() 316 | //let distance = cc.pDistance(nodeA.position, nodeB.position); 317 | if (distance <= 500) { 318 | let volume = 1.0; 319 | if (distance > 100) { 320 | volume = 100 / distance; 321 | } 322 | cc.audioEngine.play(this.bombClip, false, volume); 323 | } 324 | }, 325 | onDestroy: function () { 326 | this.node.off('netmsg', this.onNetMsg, this); 327 | }, 328 | update(dt) { 329 | if (this.sceneReady === false) return; 330 | this.processInputs(dt); 331 | this.checkBulletValid(); 332 | if (this.interpolation) { 333 | this.interpolateEntities(); 334 | } 335 | }, 336 | processInputs(dt) { 337 | let targetRotation = this._actionLayerJS.getTargetRotation(); 338 | if (targetRotation == null) { 339 | this.pressTime = 0; 340 | return; 341 | } 342 | this.pressTime = dt; 343 | // if (this.pressTime < 0.1) return; 344 | let input = { pressTime: this.pressTime }; 345 | input.targetRotation = targetRotation; 346 | input.inputSeqID = this.inputSequenceNumber++; 347 | //input.entityID = G.entityID; 348 | NetCtrl.Send("ReqMove",input); 349 | if (this.clientPrediction) { 350 | let entityJS = this.entityMap.get(G.entityID); 351 | entityJS.applyInput(input); 352 | } 353 | 354 | this.pendingInputs.push(input); 355 | }, 356 | checkBulletValid() { 357 | let now = new Date().getTime(); 358 | let deleteList = new Array(); 359 | this.bulletMap.forEach(function (item, key, mapObj) { 360 | if (now - item.createTime >= G.config.bulletLiveTime) { 361 | deleteList.push(key); 362 | } 363 | }); 364 | 365 | for (let i = 0; i < deleteList.length; i++) { 366 | let item = this.bulletMap.get(deleteList[i]); 367 | this.bulletMap.delete(deleteList[i]); 368 | this.bulletPool.put(item.node); 369 | } 370 | }, 371 | interpolateEntities() { 372 | let now = new Date().getTime(); 373 | let render_timeStamp = now - G.config.noticePosDuration; 374 | this.entityMap.forEach(function (entityJS, key, mapObj) { 375 | if (key !== G.entityID) { 376 | let buffer = entityJS.positionBuffer; 377 | while (buffer.length >= 2 && buffer[1][0] <= render_timeStamp) { 378 | buffer.shift(); 379 | } 380 | if (buffer.length >= 2 && buffer[0][0] <= render_timeStamp && buffer[1][0] >= render_timeStamp) { 381 | let x0 = buffer[0][1]; 382 | let x1 = buffer[1][1]; 383 | let y0 = buffer[0][2]; 384 | let y1 = buffer[1][2]; 385 | let t0 = buffer[0][0]; 386 | let t1 = buffer[1][0]; 387 | let r0 = buffer[0][3]; 388 | let r1 = buffer[1][3]; 389 | let distance = Math.sqrt(Math.pow(x1 - x0, 2) + Math.pow(y1 - y0, 2)); 390 | if (distance > G.entitySpeed - 5) { 391 | entityJS.rotation = r1; 392 | entityJS.node.x = x1; 393 | entityJS.node.y = y1; 394 | entityJS.rotation = -entityJS.rotation; 395 | } else { 396 | entityJS.node.x = x0 + (x1 - x0) * (render_timeStamp - t0) / (t1 - t0); 397 | entityJS.node.y = y0 + (y1 - y0) * (render_timeStamp - t0) / (t1 - t0); 398 | entityJS.rotation = r0 + (r1 - r0) * (render_timeStamp - t0) / (t1 - t0); 399 | entityJS.node.angle = entityJS.rotation; 400 | } 401 | } 402 | } 403 | }); 404 | }, 405 | lateUpdate: function (dt) { 406 | if (this.sceneReady === false) return; 407 | let meNode = this.entityMap.get(G.entityID).node; 408 | let targetPos = this.entityMap.get(G.entityID).node.convertToWorldSpaceAR(cc.Vec2.ZERO); 409 | if (meNode.x < 640) { 410 | targetPos.x = 640; 411 | } else if (meNode.x > 2560 - 640) { 412 | targetPos.x = 2560 - 640; 413 | } 414 | if (meNode.y < 360) { 415 | targetPos.y = 360; 416 | } else if (meNode.y > 1440 - 360) { 417 | targetPos.y = 1440 - 360; 418 | } 419 | this.camera.position = this.camera.parent.convertToNodeSpaceAR(targetPos); 420 | }, 421 | calculateRank() { 422 | let objArr = new Array(); 423 | this.entityMap.forEach(function (entityJS, key, mapObj) { 424 | //if (entityJS.dead === false) { 425 | let obj = {}; 426 | obj.entityID = key; 427 | obj.score = entityJS.score; 428 | objArr.push(obj); 429 | // } 430 | }); 431 | objArr.sort(function (a, b) { 432 | if (a.score < b.score) { 433 | return 1; 434 | } else if (a.score > b.score) { 435 | return -1; 436 | } else { 437 | return a.entityID > b.entityID; 438 | } 439 | }); 440 | this._showingLayerJS.setRank(0, ""); 441 | this._showingLayerJS.setRank(1, ""); 442 | this._showingLayerJS.setRank(2, ""); 443 | for (let i = 0; i < objArr.length; i++) { 444 | if (i < 3) { 445 | let index = i + 1; 446 | let entityJS = this.entityMap.get(objArr[i].entityID); 447 | let string = index + "," + entityJS.score + "分:" + entityJS.nickname; 448 | this._showingLayerJS.setRank(i, string); 449 | } 450 | } 451 | 452 | let meRank = 0; 453 | // let string = ""; 454 | // if (G.dead) { 455 | // string = "已阵亡无排名"; 456 | // } else { 457 | for (let i = 0; i < objArr.length; i++) { 458 | if (objArr[i].entityID === G.entityID) { 459 | meRank = i + 1; 460 | break; 461 | } 462 | } 463 | let string = "我是第" + meRank + "名" + objArr[meRank - 1].score + "分"; 464 | // } 465 | this._showingLayerJS.setMeRank(string); 466 | }, 467 | }); -------------------------------------------------------------------------------- /assets/Script/GameCtrl.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "1a840d6e-1188-4339-9ffa-8ccb6dc96f1c", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/GlobalConfig.js: -------------------------------------------------------------------------------- 1 | var AT = cc.Enum({ 2 | OK: 0, 3 | OK_CANCEL: 1, 4 | }); 5 | window.G = { 6 | AT: AT, 7 | userInfo: {}, 8 | entityID: -1, 9 | rotationDelta: 20, 10 | gameStartTime: -1, 11 | accountType: -1, 12 | code: null, 13 | openID: null, 14 | alert: function (msg, type, okCallback, cancelCallback) { 15 | this.globalNode.alert(msg, type, okCallback, cancelCallback); 16 | }, 17 | print: function (msg) { 18 | this.globalNode.print(msg); 19 | }, 20 | } 21 | 22 | module.exports = { 23 | debugMode: false, 24 | logonHost: "ws://127.0.0.1", 25 | // logonHost: "ws://192.168.199.217", 26 | // logonHost: "ws://af.09900990.xyz", 27 | 28 | logonPort: 5051, 29 | //websocket协议 30 | wsProtocol: "avatar-fight", 31 | speed: 50, 32 | } 33 | -------------------------------------------------------------------------------- /assets/Script/GlobalConfig.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "19f37987-80f1-4737-8dc2-b644135fef49", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/GlobalNode.js: -------------------------------------------------------------------------------- 1 | //var Global = require('Global'); 2 | cc.Class({ 3 | extends: cc.Component, 4 | 5 | properties: { 6 | alertPrefab: { 7 | default: null, 8 | type: cc.Prefab 9 | }, 10 | nodePrint: cc.Node, 11 | }, 12 | 13 | // use this for initialization 14 | onLoad: function () { 15 | cc.game.addPersistRootNode(this.node); 16 | G.globalNode = this; 17 | }, 18 | 19 | alert: function (msg, type, okCallback, cancelCallback) { 20 | let alert = cc.instantiate(this.alertPrefab); 21 | let alertJS = alert.getComponent('Alert'); 22 | cc.director.getScene().addChild(alert, 1000); 23 | alertJS.setString(msg); 24 | alertJS.setType(type); 25 | alertJS.setCallBack(okCallback, cancelCallback); 26 | }, 27 | print: function (msg) { 28 | this.nodePrint.opacity = 255; 29 | this.nodePrint.setPosition(0, 0); 30 | this.nodePrint.getComponent(cc.Label).string = msg; 31 | let spawn = cc.spawn(cc.moveBy(3, 0, 150), cc.fadeOut(3.0)); 32 | this.nodePrint.runAction(spawn); 33 | }, 34 | }); 35 | -------------------------------------------------------------------------------- /assets/Script/GlobalNode.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "be354817-7cc1-42bf-8dc9-7b8e0416b15d", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/JoyStick.js: -------------------------------------------------------------------------------- 1 | cc.Class({ 2 | extends: cc.Component, 3 | 4 | properties: { 5 | joyBG:cc.Node, 6 | joy: { 7 | default: null, 8 | type: cc.Node, 9 | displayName: '摇杆节点', 10 | }, 11 | 12 | _angle: { 13 | default: null, 14 | displayName: '当前触摸的角度', 15 | 16 | }, 17 | 18 | _radian: { 19 | default: null, 20 | displayName: '弧度', 21 | }, 22 | 23 | 24 | _speed: 0, //实际速度 25 | _speed1: 1, //一段速度 26 | _speed2: 2, //二段速度 27 | _opacity: 0, //透明度 28 | }, 29 | 30 | 31 | onLoad: function () { 32 | //对圆圈的触摸监听 33 | this._initTouchEvent(); 34 | }, 35 | 36 | 37 | //对圆圈的触摸监听 38 | _initTouchEvent: function () { 39 | var self = this; 40 | 41 | self.joyBG.on(cc.Node.EventType.TOUCH_START, this._touchStartEvent, self); 42 | 43 | self.joyBG.on(cc.Node.EventType.TOUCH_MOVE, this._touchMoveEvent, self); 44 | 45 | // 触摸在圆圈内离开或在圆圈外离开后,摇杆归位,player速度为0 46 | self.joyBG.on(cc.Node.EventType.TOUCH_END, this._touchEndEvent, self); 47 | self.joyBG.on(cc.Node.EventType.TOUCH_CANCEL, this._touchEndEvent, self); 48 | }, 49 | 50 | //计算两点间的距离并返回 51 | _getDistance: function (pos1, pos2) { 52 | return Math.sqrt(Math.pow(pos1.x - pos2.x, 2) + 53 | Math.pow(pos1.y - pos2.y, 2)); 54 | }, 55 | 56 | /*角度/弧度转换 57 | 角度 = 弧度 * 180 / Math.PI 58 | 弧度 = 角度 * Math.PI / 180*/ 59 | //计算弧度并返回 60 | _getRadian: function (point) { 61 | this._radian = Math.PI / 180 * this._getAngle(point); 62 | return this._radian; 63 | }, 64 | 65 | //计算角度并返回 66 | _getAngle: function (point) { 67 | 68 | var pos = this.joyBG.getPosition(); 69 | this._angle = Math.atan2(point.y - pos.y, point.x - pos.x) * (180 / Math.PI); 70 | return this._angle; 71 | }, 72 | getTargetAngle() { 73 | if (this._speed === 0) { 74 | return null; 75 | } else { 76 | return this._angle; 77 | } 78 | }, 79 | //设置实际速度 80 | _setSpeed: function (point) { 81 | //触摸点和遥控杆中心的距离 82 | var distance = this._getDistance(point, this.joyBG.getPosition()); 83 | 84 | //如果半径 85 | if (distance < this._radius) { 86 | this._speed = this._speed1; 87 | } 88 | else { 89 | this._speed = this._speed2; 90 | } 91 | }, 92 | 93 | _touchStartEvent: function (event) { 94 | // 获取触摸位置的世界坐标转换成圆圈的相对坐标(以圆圈的锚点为基准) 95 | var touchPos = this.joyBG.convertToNodeSpaceAR(event.getLocation()); 96 | //触摸点与圆圈中心的距离 97 | var distance = this._getDistance(touchPos, cc.v2(0, 0)); 98 | //圆圈半径 99 | var radius = this.joyBG.width / 2; 100 | // 记录摇杆位置,给touch move使用 101 | this._stickPos = touchPos; 102 | var posX = this.joyBG.getPosition().x + touchPos.x; 103 | var posY = this.joyBG.getPosition().y + touchPos.y; 104 | //手指在圆圈内触摸,控杆跟随触摸点 105 | if (radius > distance) { 106 | this.joy.setPosition(cc.v2(posX, posY)); 107 | return true; 108 | } 109 | return false; 110 | }, 111 | 112 | _touchMoveEvent: function (event) { 113 | var touchPos = this.joyBG.convertToNodeSpaceAR(event.getLocation()); 114 | var distance = this._getDistance(touchPos, cc.v2(0, 0)); 115 | var radius = this.joyBG.width / 2; 116 | // 由于摇杆的postion是以父节点为锚点,所以定位要加上ring和dot当前的位置(stickX,stickY) 117 | var posX = this.joyBG.getPosition().x + touchPos.x; 118 | var posY = this.joyBG.getPosition().y + touchPos.y; 119 | if (radius > distance) { 120 | this.joy.setPosition(cc.v2(posX, posY)); 121 | } 122 | else { 123 | //控杆永远保持在圈内,并在圈内跟随触摸更新角度 124 | var x = this.joyBG.getPosition().x + Math.cos(this._getRadian(cc.v2(posX, posY))) * radius; 125 | var y = this.joyBG.getPosition().y + Math.sin(this._getRadian(cc.v2(posX, posY))) * radius; 126 | this.joy.setPosition(cc.v2(x, y)); 127 | } 128 | //更新角度 129 | this._getAngle(cc.v2(posX, posY)); 130 | //设置实际速度 131 | this._setSpeed(cc.v2(posX, posY)); 132 | 133 | }, 134 | 135 | _touchEndEvent: function () { 136 | this.joy.setPosition(this.joyBG.getPosition()); 137 | this._speed = 0; 138 | }, 139 | }); 140 | -------------------------------------------------------------------------------- /assets/Script/JoyStick.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "db0f2162-060b-4ae2-b4fa-ade0f6fb8beb", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/MsgMgr.js: -------------------------------------------------------------------------------- 1 | let Util = require("Util"); 2 | let protores=require("msg"); 3 | 4 | let MsgMgr= { 5 | init:false, 6 | packageName:"cmsg", 7 | msgFullName2id:new Map(), 8 | msgid2NameObj:new Map(), 9 | Marshal(msgName,data){ 10 | var msgType = protores[this.packageName][msgName]; 11 | var msg = msgType.create(data); 12 | var bytes = msgType.encode(msg).finish(); 13 | return bytes 14 | }, 15 | MsgID(msgName){ 16 | return this.msgFullName2id.get(this.fullName(msgName)) 17 | }, 18 | 19 | fullName(msgName){ 20 | return this.packageName+"."+msgName 21 | }, 22 | 23 | Unmarshal(msgID, bytes) { 24 | let nameObj = this.msgid2NameObj.get(msgID) 25 | var msgType = protores[nameObj.packageName][nameObj.msgName]; 26 | var msg = msgType.decode(bytes); 27 | var data = msgType.toObject(msg, { 28 | longs: Number, //long默认转换为Number类型 29 | enums: String, 30 | bytes: String, 31 | defaults: true, 32 | // see ConversionOptions 33 | }); 34 | var detail = { 35 | msgName:nameObj.msgName, 36 | data:data, 37 | } 38 | return detail; 39 | }, 40 | RegisterProtoMsg(){ 41 | if (this.init){ 42 | return 43 | } 44 | this.init = true 45 | for(var key in protores[this.packageName]){ 46 | 47 | let msgName = key; 48 | let fullName = this.fullName(msgName); 49 | let msgid = Util.CRC32(fullName); 50 | this.msgFullName2id.set(fullName,msgid) 51 | this.msgid2NameObj.set(msgid,{packageName:this.packageName,msgName:msgName}); 52 | // cc.log(key,msgid);//json对象中属性的名字:对象中属性的值 53 | } 54 | } 55 | }; 56 | 57 | module.exports = MsgMgr; -------------------------------------------------------------------------------- /assets/Script/MsgMgr.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "cb47dc66-ce2b-4009-993e-c621469d4fc8", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/NetCtrl.js: -------------------------------------------------------------------------------- 1 | //定义全局的变量 2 | var Config = require('GlobalConfig'); 3 | var Util = require("Util"); 4 | var MsgMgr = require("MsgMgr"); 5 | var NetControl = { 6 | _socket: null, //当前的webSocket的对象 7 | connect: function (callback, num) { 8 | if (this._socket && cc.sys.isObjectValid(this._socket)) { 9 | if (this._socket.readyState > WebSocket.OPEN) { 10 | this._socket.close(); 11 | this.createNewSocket(callback, num); 12 | } else { 13 | if (this.isOpen() === true) { 14 | if (callback) callback(num); 15 | } 16 | } 17 | } else { 18 | this.createNewSocket(callback); 19 | } 20 | }, 21 | close: function () { 22 | G.isLogined = false 23 | this._socket.onclose = undefined; 24 | this._socket.onerror = undefined; 25 | if (this._socket && cc.sys.isObjectValid(this._socket)) { 26 | this._socket.close(); 27 | } 28 | }, 29 | dataEventHandler: null, 30 | fire(event, data) { 31 | if (this.dataEventHandler) { 32 | this.dataEventHandler.emit(event, data); 33 | } else { 34 | G.debug("dataEventHandle not existed"); 35 | } 36 | }, 37 | createNewSocket: function (callback, num) { 38 | //清空以前socket的绑定 39 | if (this._socket) { 40 | this._socket.onopen = undefined; 41 | this._socket.onmessage = undefined; 42 | this._socket.onclose = undefined; 43 | this._socket.onerror = undefined; 44 | } 45 | this._socket = new WebSocket(Config.logonHost + ":" + Config.logonPort, Config.wsProtocol); 46 | this._socket.onopen = () => { 47 | if (callback) { 48 | callback(num); 49 | } 50 | }; 51 | this._socket.onclose = (event) => { 52 | this._onClose(event) 53 | }; 54 | this._socket.onmessage = (event) => { 55 | this._onMessage(event); 56 | }; 57 | this._socket.onerror = (event) => { 58 | cc.log(event); 59 | } 60 | }, 61 | _onClose: function (event) { 62 | cc.log(event); 63 | G.isLogined = false 64 | G.alert("网络连接失败,重新连接?", G.AT.OK,function(){ 65 | cc.director.loadScene("start"); 66 | }); 67 | }, 68 | _onMessage: function (obj) { 69 | let reader = new FileReader(); 70 | let self = this; 71 | reader.onload = function(result) { 72 | let arrayBuffer = event.target.result; 73 | var decode = Util.Decode(arrayBuffer); 74 | let protoData = new Uint8Array(decode.protoData); 75 | var detail = MsgMgr.Unmarshal(decode.msgID,protoData); 76 | if (detail.msgName ==="SNoticeKickOut"){ 77 | self.close(); 78 | G.alert("重复登录被T出,重新登录?", G.AT.OK,function(){ 79 | cc.director.loadScene("start"); 80 | }); 81 | }else{ 82 | self.fire('netmsg', detail); 83 | } 84 | 85 | } 86 | reader.readAsArrayBuffer(obj.data); 87 | 88 | //var msg = JSON.parse(obj.data); 89 | // var data = msg.data; 90 | // this.fire('netmsg', msg); 91 | }, 92 | Send: function (msgName,dataObj) { 93 | if (this.isOpen()) { 94 | let protoData = MsgMgr.Marshal(msgName,dataObj); 95 | let msgID = MsgMgr.MsgID(msgName); 96 | let data = Util.Encode(msgID,protoData); 97 | let fullName = MsgMgr.fullName(msgName); 98 | //cc.log("send",fullName,msgID,data); 99 | this._socket.send(data); 100 | } 101 | }, 102 | 103 | isOpen() { 104 | if (this._socket && cc.sys.isObjectValid(this._socket)) { 105 | return this._socket.readyState === WebSocket.OPEN; 106 | } else { 107 | return false; 108 | } 109 | }, 110 | 111 | isConnecting() { 112 | if (this._socket && cc.sys.isObjectValid(this._socket)) { 113 | return this._socket.readyState === WebSocket.CONNECTING; 114 | } else { 115 | return false; 116 | } 117 | }, 118 | //先检测是否断线,如果断钱了重连,再发送消息 119 | safeSend(msgName,dataObj) { 120 | this.connect(() => { 121 | this.Send(msgName,dataObj); 122 | }); 123 | } 124 | }; 125 | module.exports = NetControl; -------------------------------------------------------------------------------- /assets/Script/NetCtrl.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "4e4c2d35-f38f-4c62-8a7c-2c9e1c219f20", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/RankItem.js: -------------------------------------------------------------------------------- 1 | // Learn cc.Class: 2 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/class.html 3 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/class/index.html 4 | // Learn Attribute: 5 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/reference/attributes.html 6 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/reference/attributes/index.html 7 | // Learn life-cycle callbacks: 8 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/life-cycle-callbacks.html 9 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/life-cycle-callbacks/index.html 10 | 11 | cc.Class({ 12 | extends: cc.Component, 13 | 14 | properties: { 15 | nameLabel: cc.Label, 16 | avatarSprite: cc.Sprite, 17 | scoreLabel: cc.Label, 18 | }, 19 | 20 | // LIFE-CYCLE CALLBACKS: 21 | 22 | // onLoad () {}, 23 | 24 | start() { 25 | 26 | }, 27 | setItemData(data) { 28 | this.nameLabel.string = data.rank + " " + data.nickname; 29 | this.scoreLabel.string = data.killCount + " " + data.score; 30 | this.showAvatar(data.headImgUrl); 31 | }, 32 | 33 | showAvatar(headImgUrl) { 34 | let self = this; 35 | if (headImgUrl && headImgUrl != ' ') { 36 | let imgurl = headImgUrl.substr(0, headImgUrl.length - 1) + "96"; 37 | cc.loader.load({ 38 | url: imgurl, type: 'jpg' 39 | }, function (err, texture) { 40 | if (err) { 41 | // self.showOriginAvatar(); 42 | } else { 43 | self.avatarSprite.spriteFrame = new cc.SpriteFrame(texture); 44 | } 45 | }); 46 | } else { 47 | //self.showOriginAvatar(); 48 | } 49 | }, 50 | 51 | 52 | // update (dt) {}, 53 | }); 54 | -------------------------------------------------------------------------------- /assets/Script/RankItem.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "bf0abb74-03e4-4d91-8346-fc456285a4bb", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/RankLabel.js: -------------------------------------------------------------------------------- 1 | // Learn cc.Class: 2 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/class.html 3 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/class/index.html 4 | // Learn Attribute: 5 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/reference/attributes.html 6 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/reference/attributes/index.html 7 | // Learn life-cycle callbacks: 8 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/life-cycle-callbacks.html 9 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/life-cycle-callbacks/index.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 | start () { 37 | 38 | }, 39 | 40 | // update (dt) {}, 41 | }); 42 | -------------------------------------------------------------------------------- /assets/Script/RankLabel.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "edd87ef0-d070-45ab-b58d-4b508163adc1", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/RankLayer.js: -------------------------------------------------------------------------------- 1 | // Learn cc.Class: 2 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/class.html 3 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/class/index.html 4 | // Learn Attribute: 5 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/reference/attributes.html 6 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/reference/attributes/index.html 7 | // Learn life-cycle callbacks: 8 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/life-cycle-callbacks.html 9 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/life-cycle-callbacks/index.html 10 | 11 | cc.Class({ 12 | extends: cc.Component, 13 | 14 | properties: { 15 | rankLabel: [cc.Label], 16 | meRank: cc.Label, 17 | // foo: { 18 | // // ATTRIBUTES: 19 | // default: null, // The default value will be used only when the component attaching 20 | // // to a node for the first time 21 | // type: cc.SpriteFrame, // optional, default is typeof default 22 | // serializable: true, // optional, default is true 23 | // }, 24 | // bar: { 25 | // get () { 26 | // return this._bar; 27 | // }, 28 | // set (value) { 29 | // this._bar = value; 30 | // } 31 | // }, 32 | }, 33 | setRank(index, string) { 34 | this.rankLabel[index].string = string; 35 | }, 36 | setMeRank(string) { 37 | this.meRank.string = string; 38 | } 39 | }); 40 | -------------------------------------------------------------------------------- /assets/Script/RankLayer.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "3b5908df-7b7b-4e02-a686-6ed1d9510ac1", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/ShowingLayer.js: -------------------------------------------------------------------------------- 1 | // Learn cc.Class: 2 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/class.html 3 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/class/index.html 4 | // Learn Attribute: 5 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/reference/attributes.html 6 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/reference/attributes/index.html 7 | // Learn life-cycle callbacks: 8 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/life-cycle-callbacks.html 9 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/life-cycle-callbacks/index.html 10 | 11 | cc.Class({ 12 | extends: cc.Component, 13 | 14 | properties: { 15 | clockLabel: cc.Label, 16 | rankLayer: cc.Node, 17 | killCountNode: cc.Label, 18 | centerClockLabel: cc.Label, 19 | // foo: { 20 | // // ATTRIBUTES: 21 | // default: null, // The default value will be used only when the component attaching 22 | // // to a node for the first time 23 | // type: cc.SpriteFrame, // optional, default is typeof default 24 | // serializable: true, // optional, default is true 25 | // }, 26 | // bar: { 27 | // get () { 28 | // return this._bar; 29 | // }, 30 | // set (value) { 31 | // this._bar = value; 32 | // } 33 | // }, 34 | }, 35 | 36 | // LIFE-CYCLE CALLBACKS: 37 | 38 | onLoad() { 39 | this._rankLayerJS = this.rankLayer.getComponent('RankLayer'); 40 | }, 41 | 42 | setRank(index, string) { 43 | this._rankLayerJS.setRank(index, string); 44 | }, 45 | setMeRank(string) { 46 | this._rankLayerJS.setMeRank(string); 47 | }, 48 | start() { 49 | 50 | }, 51 | showGetScore(count) { 52 | this.killCountNode.getComponent(cc.Label).string = "+"+count; 53 | let anim = this.killCountNode.getComponent(cc.Animation); 54 | anim.play(); 55 | }, 56 | setLeftClock(leftTime) { 57 | this.unschedule(this.callback); 58 | this.count = leftTime; 59 | this.clockLabel.string = "倒计时:" + this.count; 60 | this.clockLabel.node.active = true; 61 | this.callback = function () { 62 | this.count--; 63 | if (this.count <= 5) { 64 | this.centerClockLabel.node.active = true; 65 | this.centerClockLabel.string = this.count; 66 | } 67 | if (this.count === 0) { 68 | this.unschedule(this.callback); 69 | this.centerClockLabel.node.active = false; 70 | this.clockLabel.node.active = false; 71 | } 72 | this.clockLabel.string = "倒计时:" + this.count; 73 | } 74 | this.schedule(this.callback, 1); 75 | }, 76 | 77 | 78 | // update (dt) {}, 79 | }); 80 | -------------------------------------------------------------------------------- /assets/Script/ShowingLayer.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "452071a4-ae24-45d3-8390-bc90f060c18e", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/StartLayer.js: -------------------------------------------------------------------------------- 1 | // Learn cc.Class: 2 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/class.html 3 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/class/index.html 4 | // Learn Attribute: 5 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/reference/attributes.html 6 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/reference/attributes/index.html 7 | // Learn life-cycle callbacks: 8 | // - [Chinese] http://www.cocos.com/docs/creator/scripting/life-cycle-callbacks.html 9 | // - [English] http://www.cocos2d-x.org/docs/editors_and_tools/creator-chapters/scripting/life-cycle-callbacks/index.html 10 | var NetCtrl = require('NetCtrl'); 11 | var Cmd = require('CmdLogon'); 12 | var Util = require('Util'); 13 | 14 | let MsgMgr = require("MsgMgr"); 15 | cc.Class({ 16 | extends: cc.Component, 17 | 18 | properties: { 19 | statusInfoLabel: cc.Label, 20 | startBtn: cc.Button, 21 | nameEditLayer: cc.Node, 22 | nameEditBox: cc.EditBox, 23 | clockLabel: cc.Label, 24 | }, 25 | 26 | // LIFE-CYCLE CALLBACKS: 27 | onLoad() { 28 | // G.alert("网络连接失败,请检查网络", G.AT.OK); 29 | // if (cc.sys.platform === cc.sys.WECHAT_GAME) { 30 | // wx.login({ 31 | // success: function (info) { 32 | // wx.getUserInfo({ 33 | // success: function (res) { 34 | // let userInfo = res.userInfo; 35 | // cc.log(userInfo.nickName); 36 | // NetCtrl.createNewSocket(() => { 37 | // var msg = {}; 38 | // msg.code = info.code; 39 | // msg.name = userInfo.nickName; 40 | // msg.avatarUrl = userInfo.avatarUrl; 41 | // NetCtrl.send(Cmd.MDM_MB_LOGON, Cmd.SUB_MB_LOGON_WX_TEMP, msg); 42 | // }); 43 | // } 44 | // }) 45 | // } 46 | // }); 47 | // } else { 48 | // let code = Util.getQueryString('code'); 49 | // if (code) { 50 | // let msg = {}; 51 | // msg.code = code; 52 | // NetCtrl.createNewSocket(() => { 53 | // NetCtrl.send(Cmd.MDM_MB_LOGON, Cmd.SUB_MB_WX_LOGON_FIRST, msg); 54 | // }); 55 | // } else { 56 | // let localData = JSON.parse(cc.sys.localStorage.getItem('visitorData')); 57 | // if (localData !== null && localData.name) { 58 | // this.nameEditBox.string = localData.name; 59 | // } 60 | // NetCtrl.createNewSocket(() => { 61 | // this.sendLogonVisitorMsg(); 62 | // }); 63 | // } 64 | // } 65 | 66 | MsgMgr.RegisterProtoMsg(); 67 | 68 | let nickname = cc.sys.localStorage.getItem('nickname'); 69 | if (nickname){ 70 | this.nameEditBox.string = nickname; 71 | } 72 | 73 | 74 | NetCtrl.dataEventHandler = this.node; 75 | this.node.on('netmsg',this.onNetMsg,this); 76 | 77 | //如果没有登录,自动登录 78 | if (!G.isLogined){ 79 | this.statusInfoLabel.string = "网络连接中..."; 80 | this.startBtn.interactable = false; 81 | this.login() 82 | } 83 | }, 84 | // onJoinFail(msg) { 85 | // // msg = msg.detail; 86 | // let data = msg.data; 87 | // this.startBtn.interactable = false; 88 | // this.failTime = new Date().getTime(); 89 | // this.leftTime = data.leftTime; 90 | // this.setLeftClock(data.leftTime); 91 | // this.statusInfoLabel.string = "上轮您已结束,请等待下轮开始!"; 92 | // }, 93 | // onLogonSuccess(data) { 94 | // // msg = msg.detail; 95 | // //let data = msg.data; 96 | // if (data.dead) { 97 | // this.startBtn.interactable = false; 98 | // this.statusInfoLabel.string = "上轮您已结束,请等待下轮开始!"; 99 | // this.failTime = new Date().getTime(); 100 | // this.leftTime = data.leftTime; 101 | // this.setLeftClock(data.leftTime); 102 | // } else { 103 | // this.startBtn.interactable = true; 104 | // this.statusInfoLabel.string = ""; 105 | // } 106 | // }, 107 | login(){ 108 | NetCtrl.createNewSocket(() => { 109 | this.sendLogonVisitorMsg(); 110 | }); 111 | }, 112 | onNetMsg(detail){ 113 | //cc.log("startLayer netmsg",detail); 114 | let data = detail.data 115 | switch (detail.msgName){ 116 | case "RespLogin": 117 | this.onRespLogin(data); 118 | break; 119 | case "RespJoinGame": 120 | this.onRespJoinGame(data); 121 | break; 122 | case "RespEnterGame": 123 | this.onRespEnterGame(data); 124 | break; 125 | } 126 | }, 127 | onRespLogin(data){ 128 | if (data.err!="Invalid"){ 129 | this.statusInfoLabel.string = data.err 130 | return 131 | } 132 | 133 | cc.sys.localStorage.setItem('token', data.token); 134 | G.userID = data.userID; 135 | G.isLogined = true; 136 | 137 | if (data.inGame){ 138 | this.SendReqEnterGameMsg(); 139 | }else{ 140 | this.startBtn.interactable = true; 141 | this.statusInfoLabel.string = "Are you ready?"; 142 | } 143 | 144 | }, 145 | onRespEnterGame(data){ 146 | if (data.err!="Invalid"){ 147 | this.statusInfoLabel.string = data.err 148 | return 149 | } 150 | 151 | if (data.dead) { 152 | this.startBtn.interactable = false; 153 | this.statusInfoLabel.string = "上轮您已结束,请等待下轮开始!"; 154 | this.failTime = new Date().getTime(); 155 | this.leftTime = data.gameLeftSec+1; 156 | this.setLeftClock(); 157 | } else { 158 | G.config = data.config; 159 | G.entityID = data.entityID; 160 | cc.director.loadScene('game'); 161 | } 162 | }, 163 | onRespJoinGame(data){ 164 | if (data.err!="Invalid"){ 165 | this.statusInfoLabel.string = data.err 166 | return 167 | } 168 | G.nickname = data.nickname; 169 | this.SendReqEnterGameMsg(); 170 | }, 171 | 172 | SendReqEnterGameMsg(){ 173 | NetCtrl.Send("ReqEnterGame"); 174 | }, 175 | clickJoinGame() { 176 | // if (!G.isLogined){ 177 | // this.startBtn.interactable = false; 178 | // this.statusInfoLabel.string = "connect..."; 179 | // this.login() 180 | // }else{ 181 | let nickname = this.nameEditBox.string 182 | cc.sys.localStorage.setItem('nickname', nickname); 183 | NetCtrl.Send("ReqJoinGame",{nickname:nickname}); 184 | // } 185 | }, 186 | clockCallback() { 187 | let count = parseInt(this.leftTime - (new Date().getTime() - this.failTime) / 1000); 188 | if (count <= 0) { 189 | this.unschedule(this.clockCallback); 190 | //this.setStatusInfo(""); 191 | this.clockLabel.string = ''; 192 | this.startBtn.interactable = true; 193 | } else { 194 | this.clockLabel.string = count; 195 | } 196 | }, 197 | setStatusInfo(string) { 198 | this.statusInfoLabel.string = string; 199 | }, 200 | setLeftClock() { 201 | this.unschedule(this.clockCallback); 202 | this.clockLabel.string = this.leftTime; 203 | this.schedule(this.clockCallback, 1); 204 | }, 205 | sendLogonVisitorMsg() { 206 | let token = cc.sys.localStorage.getItem('token'); 207 | NetCtrl.Send("ReqLogin",{token:token}); 208 | }, 209 | onDestroy() { 210 | this.node.off('netmsg', this.onNetMsg, this); 211 | }, 212 | showOffline(){ 213 | this.startBtn.interactable = true 214 | this.statusInfoLabel.string = "disconnect,reconnect?"; 215 | }, 216 | }); 217 | -------------------------------------------------------------------------------- /assets/Script/StartLayer.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "6898be1b-4250-4ba9-b38e-85a73dbfba6e", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/Util.js: -------------------------------------------------------------------------------- 1 | var CRC32 = require("crc32"); 2 | 3 | var Util = { 4 | getAngle(px1, py1, px2, py2) { 5 | //两点的x、y值 6 | let x = px2 - px1; 7 | let y = py2 - py1; 8 | let hypotenuse = Math.sqrt(Math.pow(x, 2) + Math.pow(y, 2)); 9 | //斜边长度 10 | let cos = x / hypotenuse; 11 | let radian = Math.acos(cos); 12 | //求出弧度 13 | let angle = 180 / (Math.PI / radian); 14 | //用弧度算出角度 15 | if (y < 0) { 16 | angle = -angle; 17 | } else if ((y == 0) && (x < 0)) { 18 | angle = 180; 19 | } 20 | return angle; 21 | }, 22 | getQueryString(name) { 23 | if (cc.sys.isNative) return null; 24 | var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i"); 25 | var r = window.location.search.substr(1).match(reg); 26 | if (r != null) return unescape(r[2]); return null; 27 | }, 28 | getDistance(x1, y1, x2, y2) { 29 | let x = x2 - x1; 30 | let y = y2 - y1; 31 | let distance = Math.sqrt(Math.pow(x, 2) + Math.pow(y, 2)); 32 | return distance; 33 | }, 34 | Encode(msgid,protoData){ 35 | let head = this.UInt32toBinary(msgid,false); 36 | 37 | let retData = new Uint8Array(protoData.length+4); 38 | retData.set(head,0); 39 | retData.set(protoData,4); 40 | return retData; 41 | }, 42 | 43 | Decode(data){ 44 | //let uint8Data = new Uint8Array(data); 45 | let uint8Data = data 46 | let msgID = this.BinaryToUint32(uint8Data.slice(0,4),false); 47 | let protoData = uint8Data.slice(4); 48 | 49 | return {msgID:msgID,protoData:protoData}; 50 | }, 51 | 52 | BinaryToUint32(binary,littleEndian){ 53 | let dv = new DataView(binary) 54 | return dv.getUint32(binary,littleEndian) 55 | }, 56 | 57 | UInt32toBinary(num,littleEndian){ 58 | let retArr = new ArrayBuffer(4); 59 | let dv = new DataView(retArr); 60 | dv.setUint32(0,num,littleEndian); 61 | return new Uint8Array(retArr) 62 | }, 63 | 64 | CRC32(str){ 65 | return CRC32.str(str); 66 | }, 67 | 68 | }; 69 | 70 | module.exports = Util; 71 | -------------------------------------------------------------------------------- /assets/Script/Util.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "abddb514-a056-4424-88d4-7995a01d74c4", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/crc32.js: -------------------------------------------------------------------------------- 1 | /* crc32.js (C) 2014-present SheetJS -- http://sheetjs.com */ 2 | /* vim: set ts=2: */ 3 | /*exported CRC32 */ 4 | var CRC32; 5 | (function (factory) { 6 | /*jshint ignore:start */ 7 | /*eslint-disable */ 8 | if(typeof DO_NOT_EXPORT_CRC === 'undefined') { 9 | if('object' === typeof exports) { 10 | factory(exports); 11 | } else if ('function' === typeof define && define.amd) { 12 | define(function () { 13 | var module = {}; 14 | factory(module); 15 | return module; 16 | }); 17 | } else { 18 | factory(CRC32 = {}); 19 | } 20 | } else { 21 | factory(CRC32 = {}); 22 | } 23 | /*eslint-enable */ 24 | /*jshint ignore:end */ 25 | }(function(CRC32) { 26 | CRC32.version = '1.2.0'; 27 | /* see perf/crc32table.js */ 28 | /*global Int32Array */ 29 | function signed_crc_table() { 30 | var c = 0, table = new Array(256); 31 | 32 | for(var n =0; n != 256; ++n){ 33 | c = n; 34 | c = ((c&1) ? (-306674912 ^ (c >>> 1)) : (c >>> 1)); 35 | c = ((c&1) ? (-306674912 ^ (c >>> 1)) : (c >>> 1)); 36 | c = ((c&1) ? (-306674912 ^ (c >>> 1)) : (c >>> 1)); 37 | c = ((c&1) ? (-306674912 ^ (c >>> 1)) : (c >>> 1)); 38 | c = ((c&1) ? (-306674912 ^ (c >>> 1)) : (c >>> 1)); 39 | c = ((c&1) ? (-306674912 ^ (c >>> 1)) : (c >>> 1)); 40 | c = ((c&1) ? (-306674912 ^ (c >>> 1)) : (c >>> 1)); 41 | c = ((c&1) ? (-306674912 ^ (c >>> 1)) : (c >>> 1)); 42 | table[n] = c; 43 | } 44 | 45 | return typeof Int32Array !== 'undefined' ? new Int32Array(table) : table; 46 | } 47 | 48 | var T = signed_crc_table(); 49 | function crc32_bstr(bstr, seed) { 50 | var C = seed ^ -1, L = bstr.length - 1; 51 | for(var i = 0; i < L;) { 52 | C = (C>>>8) ^ T[(C^bstr.charCodeAt(i++))&0xFF]; 53 | C = (C>>>8) ^ T[(C^bstr.charCodeAt(i++))&0xFF]; 54 | } 55 | if(i === L) C = (C>>>8) ^ T[(C ^ bstr.charCodeAt(i))&0xFF]; 56 | return C ^ -1; 57 | } 58 | 59 | function crc32_buf(buf, seed) { 60 | if(buf.length > 10000) return crc32_buf_8(buf, seed); 61 | var C = seed ^ -1, L = buf.length - 3; 62 | for(var i = 0; i < L;) { 63 | C = (C>>>8) ^ T[(C^buf[i++])&0xFF]; 64 | C = (C>>>8) ^ T[(C^buf[i++])&0xFF]; 65 | C = (C>>>8) ^ T[(C^buf[i++])&0xFF]; 66 | C = (C>>>8) ^ T[(C^buf[i++])&0xFF]; 67 | } 68 | while(i < L+3) C = (C>>>8) ^ T[(C^buf[i++])&0xFF]; 69 | return C ^ -1; 70 | } 71 | 72 | function crc32_buf_8(buf, seed) { 73 | var C = seed ^ -1, L = buf.length - 7; 74 | for(var i = 0; i < L;) { 75 | C = (C>>>8) ^ T[(C^buf[i++])&0xFF]; 76 | C = (C>>>8) ^ T[(C^buf[i++])&0xFF]; 77 | C = (C>>>8) ^ T[(C^buf[i++])&0xFF]; 78 | C = (C>>>8) ^ T[(C^buf[i++])&0xFF]; 79 | C = (C>>>8) ^ T[(C^buf[i++])&0xFF]; 80 | C = (C>>>8) ^ T[(C^buf[i++])&0xFF]; 81 | C = (C>>>8) ^ T[(C^buf[i++])&0xFF]; 82 | C = (C>>>8) ^ T[(C^buf[i++])&0xFF]; 83 | } 84 | while(i < L+7) C = (C>>>8) ^ T[(C^buf[i++])&0xFF]; 85 | return C ^ -1; 86 | } 87 | 88 | function crc32_str(str, seed) { 89 | var C = seed ^ -1; 90 | for(var i = 0, L=str.length, c, d; i < L;) { 91 | c = str.charCodeAt(i++); 92 | if(c < 0x80) { 93 | C = (C>>>8) ^ T[(C ^ c)&0xFF]; 94 | } else if(c < 0x800) { 95 | C = (C>>>8) ^ T[(C ^ (192|((c>>6)&31)))&0xFF]; 96 | C = (C>>>8) ^ T[(C ^ (128|(c&63)))&0xFF]; 97 | } else if(c >= 0xD800 && c < 0xE000) { 98 | c = (c&1023)+64; d = str.charCodeAt(i++)&1023; 99 | C = (C>>>8) ^ T[(C ^ (240|((c>>8)&7)))&0xFF]; 100 | C = (C>>>8) ^ T[(C ^ (128|((c>>2)&63)))&0xFF]; 101 | C = (C>>>8) ^ T[(C ^ (128|((d>>6)&15)|((c&3)<<4)))&0xFF]; 102 | C = (C>>>8) ^ T[(C ^ (128|(d&63)))&0xFF]; 103 | } else { 104 | C = (C>>>8) ^ T[(C ^ (224|((c>>12)&15)))&0xFF]; 105 | C = (C>>>8) ^ T[(C ^ (128|((c>>6)&63)))&0xFF]; 106 | C = (C>>>8) ^ T[(C ^ (128|(c&63)))&0xFF]; 107 | } 108 | } 109 | //return C ^ -1; 110 | return (C ^ (-1)) >>> 0; 111 | } 112 | CRC32.table = T; 113 | // $FlowIgnore 114 | CRC32.bstr = crc32_bstr; 115 | // $FlowIgnore 116 | CRC32.buf = crc32_buf; 117 | // $FlowIgnore 118 | CRC32.str = crc32_str; 119 | })); 120 | -------------------------------------------------------------------------------- /assets/Script/crc32.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "eaf8c9bd-14e7-4d61-a8d8-9faf6530e769", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/msg.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "21e5f403-7e1a-45fb-b14b-3098b1c6147a", 4 | "isPlugin": false, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": false, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Script/protobuf.js.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.5", 3 | "uuid": "aea3964a-ed6f-43ab-81b1-e18ba1a9d1ee", 4 | "isPlugin": true, 5 | "loadPluginInWeb": true, 6 | "loadPluginInNative": true, 7 | "loadPluginInEditor": true, 8 | "subMetas": {} 9 | } -------------------------------------------------------------------------------- /assets/Texture.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.1", 3 | "uuid": "a9094e4a-f9aa-48d0-882c-00aaf28d87cb", 4 | "isGroup": false, 5 | "subMetas": {} 6 | } -------------------------------------------------------------------------------- /assets/Texture/alert.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.0.1", 3 | "uuid": "36ffec86-3e24-4ba7-a64a-a26307f80332", 4 | "subMetas": {} 5 | } -------------------------------------------------------------------------------- /assets/Texture/alert/Alert.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/alert/Alert.png -------------------------------------------------------------------------------- /assets/Texture/alert/Alert.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "ddd16f04-3b1b-440e-914d-f5eb2793ada6", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "Alert": { 11 | "ver": "1.0.4", 12 | "uuid": "e8360739-1864-4dcf-ada3-a72bb16bb9e3", 13 | "rawTextureUuid": "ddd16f04-3b1b-440e-914d-f5eb2793ada6", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 846, 22 | "height": 203, 23 | "rawWidth": 846, 24 | "rawHeight": 203, 25 | "borderTop": 37, 26 | "borderBottom": 45, 27 | "borderLeft": 304, 28 | "borderRight": 308, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/alert/cancel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/alert/cancel.png -------------------------------------------------------------------------------- /assets/Texture/alert/cancel.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "f5054ea0-01ab-49de-92ab-09004570112d", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "cancel": { 11 | "ver": "1.0.4", 12 | "uuid": "64f37cd2-c72f-415b-af3e-05b9856215ee", 13 | "rawTextureUuid": "f5054ea0-01ab-49de-92ab-09004570112d", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 203, 22 | "height": 77, 23 | "rawWidth": 203, 24 | "rawHeight": 77, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/alert/ok.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/alert/ok.png -------------------------------------------------------------------------------- /assets/Texture/alert/ok.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "883cbb0d-ebda-4e16-8038-3e404e43afc1", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "ok": { 11 | "ver": "1.0.4", 12 | "uuid": "5043a52e-566a-4cf6-8d8b-4f9d5dd65633", 13 | "rawTextureUuid": "883cbb0d-ebda-4e16-8038-3e404e43afc1", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 203, 22 | "height": 77, 23 | "rawWidth": 203, 24 | "rawHeight": 77, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/avatar.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/avatar.jpg -------------------------------------------------------------------------------- /assets/Texture/avatar.jpg.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "8783c8ff-a345-467c-a562-278f88bf636a", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "avatar": { 11 | "ver": "1.0.4", 12 | "uuid": "f6450315-893a-4502-b54b-b088068c9072", 13 | "rawTextureUuid": "8783c8ff-a345-467c-a562-278f88bf636a", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 300, 22 | "height": 300, 23 | "rawWidth": 300, 24 | "rawHeight": 300, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/bg.png -------------------------------------------------------------------------------- /assets/Texture/bg.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "940dfc55-00e4-4c9d-a3ea-0e878972c6a0", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "bg": { 11 | "ver": "1.0.4", 12 | "uuid": "7bc6f09a-eaa8-4ad3-8d20-67b984263d21", 13 | "rawTextureUuid": "940dfc55-00e4-4c9d-a3ea-0e878972c6a0", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 1200, 22 | "height": 800, 23 | "rawWidth": 1200, 24 | "rawHeight": 800, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/bullet.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/bullet.png -------------------------------------------------------------------------------- /assets/Texture/bullet.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "85ea4fae-8d52-4d4e-97f1-fb9011020a75", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "bullet": { 11 | "ver": "1.0.4", 12 | "uuid": "2dd208a7-97fc-445d-baf3-eb6a0cdfdfda", 13 | "rawTextureUuid": "85ea4fae-8d52-4d4e-97f1-fb9011020a75", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 31, 22 | "height": 11, 23 | "rawWidth": 31, 24 | "rawHeight": 11, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/cao.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/cao.jpg -------------------------------------------------------------------------------- /assets/Texture/cao.jpg.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "39aa6be4-b2e6-4367-9902-a6a7eeb27e6b", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "cao": { 11 | "ver": "1.0.4", 12 | "uuid": "aba46ab4-fc49-40f9-95af-27b3d8094767", 13 | "rawTextureUuid": "39aa6be4-b2e6-4367-9902-a6a7eeb27e6b", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 256, 22 | "height": 256, 23 | "rawWidth": 256, 24 | "rawHeight": 256, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/cao.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/cao.png -------------------------------------------------------------------------------- /assets/Texture/cao.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "a94cd62f-b127-4a5c-a28b-4e30798561eb", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "cao": { 11 | "ver": "1.0.4", 12 | "uuid": "376615b2-8889-434e-a7b1-6f7e5575a255", 13 | "rawTextureUuid": "a94cd62f-b127-4a5c-a28b-4e30798561eb", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 48, 22 | "height": 48, 23 | "rawWidth": 48, 24 | "rawHeight": 48, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/default_sprite_splash.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/default_sprite_splash.png -------------------------------------------------------------------------------- /assets/Texture/default_sprite_splash.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "d33e0623-5379-4a30-9f2a-04c97a8ce4e0", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "default_sprite_splash": { 11 | "ver": "1.0.4", 12 | "uuid": "cd3e63ba-c3af-4612-80a9-2ff72d1a225c", 13 | "rawTextureUuid": "d33e0623-5379-4a30-9f2a-04c97a8ce4e0", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 2, 22 | "height": 2, 23 | "rawWidth": 2, 24 | "rawHeight": 2, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/fei.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/fei.png -------------------------------------------------------------------------------- /assets/Texture/fei.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "9908852c-10d3-469e-8805-981fbd4268ca", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "fei": { 11 | "ver": "1.0.4", 12 | "uuid": "c7beb932-594e-4905-8d5a-1503a6813e81", 13 | "rawTextureUuid": "9908852c-10d3-469e-8805-981fbd4268ca", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 154, 22 | "height": 154, 23 | "rawWidth": 154, 24 | "rawHeight": 154, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/gameRankBG.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/gameRankBG.png -------------------------------------------------------------------------------- /assets/Texture/gameRankBG.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "08654dbb-56bf-40ec-a41d-3fa29be03dd1", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "gameRankBG": { 11 | "ver": "1.0.4", 12 | "uuid": "466220a8-a28a-409d-bc69-c4bd74f17eb5", 13 | "rawTextureUuid": "08654dbb-56bf-40ec-a41d-3fa29be03dd1", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 253, 22 | "height": 299, 23 | "rawWidth": 253, 24 | "rawHeight": 299, 25 | "borderTop": 61, 26 | "borderBottom": 57, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/green.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/green.png -------------------------------------------------------------------------------- /assets/Texture/green.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "70cace1c-9e2a-4d9a-8e3d-2a0e18b8ad87", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "green": { 11 | "ver": "1.0.4", 12 | "uuid": "8840bdd6-c341-4ad1-9113-5feb8f64b572", 13 | "rawTextureUuid": "70cace1c-9e2a-4d9a-8e3d-2a0e18b8ad87", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 35, 18 | "offsetY": 0.5, 19 | "trimX": 70, 20 | "trimY": 71, 21 | "width": 380, 22 | "height": 307, 23 | "rawWidth": 450, 24 | "rawHeight": 450, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/joystick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/joystick.png -------------------------------------------------------------------------------- /assets/Texture/joystick.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "cad2c2ad-dc44-4126-ba2e-42110013aa39", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "joystick": { 11 | "ver": "1.0.4", 12 | "uuid": "af6ae265-4678-499a-8402-5131951e2796", 13 | "rawTextureUuid": "cad2c2ad-dc44-4126-ba2e-42110013aa39", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 43, 22 | "height": 43, 23 | "rawWidth": 43, 24 | "rawHeight": 43, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/joystickBG.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/joystickBG.png -------------------------------------------------------------------------------- /assets/Texture/joystickBG.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "94142f02-7b5a-40ea-aa05-6aa85d5121f7", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "joystickBG": { 11 | "ver": "1.0.4", 12 | "uuid": "e84dd40f-7d8b-4a38-8190-0df024247c5c", 13 | "rawTextureUuid": "94142f02-7b5a-40ea-aa05-6aa85d5121f7", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 133, 22 | "height": 133, 23 | "rawWidth": 133, 24 | "rawHeight": 133, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/rankBG.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/rankBG.png -------------------------------------------------------------------------------- /assets/Texture/rankBG.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "9387aa6c-b955-460d-949a-464e06a5eb3a", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "rankBG": { 11 | "ver": "1.0.4", 12 | "uuid": "5e0c3ee3-69e9-4912-af4a-ad01c98a3fed", 13 | "rawTextureUuid": "9387aa6c-b955-460d-949a-464e06a5eb3a", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 900, 22 | "height": 63, 23 | "rawWidth": 900, 24 | "rawHeight": 63, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/rankTitle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/rankTitle.png -------------------------------------------------------------------------------- /assets/Texture/rankTitle.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "fca5d42d-20ff-45f2-9534-0ad80cf718f9", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "rankTitle": { 11 | "ver": "1.0.4", 12 | "uuid": "987f46b6-3658-4d80-a629-37fcaa797e0d", 13 | "rawTextureUuid": "fca5d42d-20ff-45f2-9534-0ad80cf718f9", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 0, 18 | "offsetY": 0, 19 | "trimX": 0, 20 | "trimY": 0, 21 | "width": 900, 22 | "height": 39, 23 | "rawWidth": 900, 24 | "rawHeight": 39, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/red.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/red.png -------------------------------------------------------------------------------- /assets/Texture/red.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "8f5e157a-21bb-4a9a-86c7-a4a5ffd38c7a", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "red": { 11 | "ver": "1.0.4", 12 | "uuid": "88bfbfec-b8f6-40ed-a739-753fc39356da", 13 | "rawTextureUuid": "8f5e157a-21bb-4a9a-86c7-a4a5ffd38c7a", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 35, 18 | "offsetY": 0.5, 19 | "trimX": 70, 20 | "trimY": 71, 21 | "width": 380, 22 | "height": 307, 23 | "rawWidth": 450, 24 | "rawHeight": 450, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/shoot.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | frames 6 | 7 | bomb.png 8 | 9 | frame 10 | {{495,2},{63,53}} 11 | offset 12 | {0,0} 13 | rotated 14 | 15 | sourceColorRect 16 | {{0,2},{63,53}} 17 | sourceSize 18 | {63,57} 19 | 20 | bullet1.png 21 | 22 | frame 23 | {{25,2},{9,21}} 24 | offset 25 | {0,0} 26 | rotated 27 | 28 | sourceColorRect 29 | {{0,0},{9,21}} 30 | sourceSize 31 | {9,21} 32 | 33 | bullet2.png 34 | 35 | frame 36 | {{2,2},{9,21}} 37 | offset 38 | {0,0} 39 | rotated 40 | 41 | sourceColorRect 42 | {{0,0},{9,21}} 43 | sourceSize 44 | {9,21} 45 | 46 | enemy1.png 47 | 48 | frame 49 | {{187,2},{51,39}} 50 | offset 51 | {0,-1} 52 | rotated 53 | 54 | sourceColorRect 55 | {{3,3},{51,39}} 56 | sourceSize 57 | {57,43} 58 | 59 | enemy1_down1.png 60 | 61 | frame 62 | {{134,2},{51,39}} 63 | offset 64 | {0,-2} 65 | rotated 66 | 67 | sourceColorRect 68 | {{3,8},{51,39}} 69 | sourceSize 70 | {57,51} 71 | 72 | enemy1_down2.png 73 | 74 | frame 75 | {{383,2},{51,47}} 76 | offset 77 | {0,-2} 78 | rotated 79 | 80 | sourceColorRect 81 | {{3,4},{51,47}} 82 | sourceSize 83 | {57,51} 84 | 85 | enemy1_down3.png 86 | 87 | frame 88 | {{436,2},{57,51}} 89 | offset 90 | {0,0} 91 | rotated 92 | 93 | sourceColorRect 94 | {{0,0},{57,51}} 95 | sourceSize 96 | {57,51} 97 | 98 | enemy1_down4.png 99 | 100 | frame 101 | {{240,2},{47,39}} 102 | offset 103 | {0,-3} 104 | rotated 105 | 106 | sourceColorRect 107 | {{5,9},{47,39}} 108 | sourceSize 109 | {57,51} 110 | 111 | enemy2.png 112 | 113 | frame 114 | {{835,2},{69,89}} 115 | offset 116 | {0,3} 117 | rotated 118 | 119 | sourceColorRect 120 | {{0,2},{69,89}} 121 | sourceSize 122 | {69,99} 123 | 124 | enemy2_down1.png 125 | 126 | frame 127 | {{2,42},{69,93}} 128 | offset 129 | {0,0} 130 | rotated 131 | 132 | sourceColorRect 133 | {{0,1},{69,93}} 134 | sourceSize 135 | {69,95} 136 | 137 | enemy2_down2.png 138 | 139 | frame 140 | {{926,2},{69,93}} 141 | offset 142 | {0,0} 143 | rotated 144 | 145 | sourceColorRect 146 | {{0,1},{69,93}} 147 | sourceSize 148 | {69,95} 149 | 150 | enemy2_down3.png 151 | 152 | frame 153 | {{273,46},{69,95}} 154 | offset 155 | {0,0} 156 | rotated 157 | 158 | sourceColorRect 159 | {{0,0},{69,95}} 160 | sourceSize 161 | {69,95} 162 | 163 | enemy2_down4.png 164 | 165 | frame 166 | {{194,43},{69,77}} 167 | offset 168 | {0,-4} 169 | rotated 170 | 171 | sourceColorRect 172 | {{0,13},{69,77}} 173 | sourceSize 174 | {69,95} 175 | 176 | enemy2_hit.png 177 | 178 | frame 179 | {{97,43},{69,95}} 180 | offset 181 | {0,0} 182 | rotated 183 | 184 | sourceColorRect 185 | {{0,2},{69,95}} 186 | sourceSize 187 | {69,99} 188 | 189 | enemy3_down1.png 190 | 191 | frame 192 | {{2,324},{165,255}} 193 | offset 194 | {0,1} 195 | rotated 196 | 197 | sourceColorRect 198 | {{0,2},{165,255}} 199 | sourceSize 200 | {165,261} 201 | 202 | enemy3_down2.png 203 | 204 | frame 205 | {{464,164},{165,255}} 206 | offset 207 | {0,2} 208 | rotated 209 | 210 | sourceColorRect 211 | {{0,1},{165,255}} 212 | sourceSize 213 | {165,261} 214 | 215 | enemy3_down3.png 216 | 217 | frame 218 | {{259,331},{165,256}} 219 | offset 220 | {0,2} 221 | rotated 222 | 223 | sourceColorRect 224 | {{0,0},{165,256}} 225 | sourceSize 226 | {165,260} 227 | 228 | enemy3_down4.png 229 | 230 | frame 231 | {{207,157},{165,255}} 232 | offset 233 | {0,2} 234 | rotated 235 | 236 | sourceColorRect 237 | {{0,1},{165,255}} 238 | sourceSize 239 | {165,261} 240 | 241 | enemy3_down5.png 242 | 243 | frame 244 | {{2,498},{166,256}} 245 | offset 246 | {0,2} 247 | rotated 248 | 249 | sourceColorRect 250 | {{0,0},{166,256}} 251 | sourceSize 252 | {166,260} 253 | 254 | enemy3_down6.png 255 | 256 | frame 257 | {{2,114},{144,203}} 258 | offset 259 | {-8,18} 260 | rotated 261 | 262 | sourceColorRect 263 | {{3,11},{144,203}} 264 | sourceSize 265 | {166,261} 266 | 267 | enemy3_hit.png 268 | 269 | frame 270 | {{721,175},{165,256}} 271 | offset 272 | {0,0} 273 | rotated 274 | 275 | sourceColorRect 276 | {{2,1},{165,256}} 277 | sourceSize 278 | {169,258} 279 | 280 | enemy3_n1.png 281 | 282 | frame 283 | {{517,342},{165,246}} 284 | offset 285 | {0,4} 286 | rotated 287 | 288 | sourceColorRect 289 | {{2,2},{165,246}} 290 | sourceSize 291 | {169,258} 292 | 293 | enemy3_n2.png 294 | 295 | frame 296 | {{765,342},{165,250}} 297 | offset 298 | {0,3} 299 | rotated 300 | 301 | sourceColorRect 302 | {{2,1},{165,250}} 303 | sourceSize 304 | {169,258} 305 | 306 | game_pause_nor.png 307 | 308 | frame 309 | {{336,2},{42,45}} 310 | offset 311 | {-1,0} 312 | rotated 313 | 314 | sourceColorRect 315 | {{8,0},{42,45}} 316 | sourceSize 317 | {60,45} 318 | 319 | game_pause_pressed.png 320 | 321 | frame 322 | {{289,2},{42,45}} 323 | offset 324 | {-1,0} 325 | rotated 326 | 327 | sourceColorRect 328 | {{8,0},{42,45}} 329 | sourceSize 330 | {60,45} 331 | 332 | game_resume_nor.png 333 | 334 | frame 335 | {{91,2},{38,41}} 336 | offset 337 | {3,0} 338 | rotated 339 | 340 | sourceColorRect 341 | {{14,2},{38,41}} 342 | sourceSize 343 | {60,45} 344 | 345 | game_resume_pressed.png 346 | 347 | frame 348 | {{48,2},{38,41}} 349 | offset 350 | {3,0} 351 | rotated 352 | 353 | sourceColorRect 354 | {{14,2},{38,41}} 355 | sourceSize 356 | {60,45} 357 | 358 | hero1.png 359 | 360 | frame 361 | {{872,73},{100,124}} 362 | offset 363 | {0,0} 364 | rotated 365 | 366 | sourceColorRect 367 | {{1,1},{100,124}} 368 | sourceSize 369 | {102,126} 370 | 371 | hero2.png 372 | 373 | frame 374 | {{370,55},{100,122}} 375 | offset 376 | {0,1} 377 | rotated 378 | 379 | sourceColorRect 380 | {{1,1},{100,122}} 381 | sourceSize 382 | {102,126} 383 | 384 | hero_blowup_n1.png 385 | 386 | frame 387 | {{746,73},{98,124}} 388 | offset 389 | {0,-1} 390 | rotated 391 | 392 | sourceColorRect 393 | {{2,2},{98,124}} 394 | sourceSize 395 | {102,126} 396 | 397 | hero_blowup_n2.png 398 | 399 | frame 400 | {{620,64},{98,124}} 401 | offset 402 | {0,-1} 403 | rotated 404 | 405 | sourceColorRect 406 | {{2,2},{98,124}} 407 | sourceSize 408 | {102,126} 409 | 410 | hero_blowup_n3.png 411 | 412 | frame 413 | {{494,62},{98,124}} 414 | offset 415 | {0,-1} 416 | rotated 417 | 418 | sourceColorRect 419 | {{2,2},{98,124}} 420 | sourceSize 421 | {102,126} 422 | 423 | hero_blowup_n4.png 424 | 425 | frame 426 | {{755,2},{66,78}} 427 | offset 428 | {0,5} 429 | rotated 430 | 431 | sourceColorRect 432 | {{18,19},{66,78}} 433 | sourceSize 434 | {102,126} 435 | 436 | ufo1.png 437 | 438 | frame 439 | {{560,2},{58,88}} 440 | offset 441 | {0,0} 442 | rotated 443 | 444 | sourceColorRect 445 | {{0,0},{58,88}} 446 | sourceSize 447 | {58,88} 448 | 449 | ufo2.png 450 | 451 | frame 452 | {{650,2},{60,103}} 453 | offset 454 | {0,0} 455 | rotated 456 | 457 | sourceColorRect 458 | {{0,2},{60,103}} 459 | sourceSize 460 | {60,107} 461 | 462 | 463 | metadata 464 | 465 | format 466 | 2 467 | realTextureFileName 468 | shoot.png 469 | size 470 | {1024,1024} 471 | smartupdate 472 | $TexturePacker:SmartUpdate:87d444c59521eb5a7a705a003be80f6f$ 473 | textureFileName 474 | shoot.png 475 | 476 | 477 | 478 | -------------------------------------------------------------------------------- /assets/Texture/shoot.plist.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "1.2.4", 3 | "uuid": "6debd48d-25da-4b67-9740-c28bb5a03c8b", 4 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 5 | "size": { 6 | "width": 1024, 7 | "height": 1024 8 | }, 9 | "type": "Texture Packer", 10 | "subMetas": { 11 | "bomb.png": { 12 | "ver": "1.0.4", 13 | "uuid": "2d60e81d-cd4f-4091-a26e-28f7533528f7", 14 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 15 | "trimType": "auto", 16 | "trimThreshold": 1, 17 | "rotated": false, 18 | "offsetX": 0, 19 | "offsetY": 0, 20 | "trimX": 495, 21 | "trimY": 2, 22 | "width": 63, 23 | "height": 53, 24 | "rawWidth": 63, 25 | "rawHeight": 57, 26 | "borderTop": 0, 27 | "borderBottom": 0, 28 | "borderLeft": 0, 29 | "borderRight": 0, 30 | "spriteType": "normal", 31 | "subMetas": {} 32 | }, 33 | "bullet1.png": { 34 | "ver": "1.0.4", 35 | "uuid": "c3864dfe-5e43-4eca-a7d7-0576da0c32ef", 36 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 37 | "trimType": "auto", 38 | "trimThreshold": 1, 39 | "rotated": true, 40 | "offsetX": 0, 41 | "offsetY": 0, 42 | "trimX": 25, 43 | "trimY": 2, 44 | "width": 9, 45 | "height": 21, 46 | "rawWidth": 9, 47 | "rawHeight": 21, 48 | "borderTop": 0, 49 | "borderBottom": 0, 50 | "borderLeft": 0, 51 | "borderRight": 0, 52 | "spriteType": "normal", 53 | "subMetas": {} 54 | }, 55 | "bullet2.png": { 56 | "ver": "1.0.4", 57 | "uuid": "26bf772e-d40b-436d-9616-82909586d710", 58 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 59 | "trimType": "auto", 60 | "trimThreshold": 1, 61 | "rotated": true, 62 | "offsetX": 0, 63 | "offsetY": 0, 64 | "trimX": 2, 65 | "trimY": 2, 66 | "width": 9, 67 | "height": 21, 68 | "rawWidth": 9, 69 | "rawHeight": 21, 70 | "borderTop": 0, 71 | "borderBottom": 0, 72 | "borderLeft": 0, 73 | "borderRight": 0, 74 | "spriteType": "normal", 75 | "subMetas": {} 76 | }, 77 | "enemy1.png": { 78 | "ver": "1.0.4", 79 | "uuid": "37c72943-2aa7-4d36-aabc-77077b468399", 80 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 81 | "trimType": "auto", 82 | "trimThreshold": 1, 83 | "rotated": false, 84 | "offsetX": 0, 85 | "offsetY": -1, 86 | "trimX": 187, 87 | "trimY": 2, 88 | "width": 51, 89 | "height": 39, 90 | "rawWidth": 57, 91 | "rawHeight": 43, 92 | "borderTop": 0, 93 | "borderBottom": 0, 94 | "borderLeft": 0, 95 | "borderRight": 0, 96 | "spriteType": "normal", 97 | "subMetas": {} 98 | }, 99 | "enemy1_down1.png": { 100 | "ver": "1.0.4", 101 | "uuid": "e20d4d27-d0e3-4ce1-8603-704b819e5e30", 102 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 103 | "trimType": "auto", 104 | "trimThreshold": 1, 105 | "rotated": false, 106 | "offsetX": 0, 107 | "offsetY": -2, 108 | "trimX": 134, 109 | "trimY": 2, 110 | "width": 51, 111 | "height": 39, 112 | "rawWidth": 57, 113 | "rawHeight": 51, 114 | "borderTop": 0, 115 | "borderBottom": 0, 116 | "borderLeft": 0, 117 | "borderRight": 0, 118 | "spriteType": "normal", 119 | "subMetas": {} 120 | }, 121 | "enemy1_down2.png": { 122 | "ver": "1.0.4", 123 | "uuid": "a1ab63f8-239f-451d-95a9-8e31c6ebf72f", 124 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 125 | "trimType": "auto", 126 | "trimThreshold": 1, 127 | "rotated": false, 128 | "offsetX": 0, 129 | "offsetY": -2, 130 | "trimX": 383, 131 | "trimY": 2, 132 | "width": 51, 133 | "height": 47, 134 | "rawWidth": 57, 135 | "rawHeight": 51, 136 | "borderTop": 0, 137 | "borderBottom": 0, 138 | "borderLeft": 0, 139 | "borderRight": 0, 140 | "spriteType": "normal", 141 | "subMetas": {} 142 | }, 143 | "enemy1_down3.png": { 144 | "ver": "1.0.4", 145 | "uuid": "1b7f9dfb-2392-4399-8df2-6825b9b4ca71", 146 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 147 | "trimType": "auto", 148 | "trimThreshold": 1, 149 | "rotated": false, 150 | "offsetX": 0, 151 | "offsetY": 0, 152 | "trimX": 436, 153 | "trimY": 2, 154 | "width": 57, 155 | "height": 51, 156 | "rawWidth": 57, 157 | "rawHeight": 51, 158 | "borderTop": 0, 159 | "borderBottom": 0, 160 | "borderLeft": 0, 161 | "borderRight": 0, 162 | "spriteType": "normal", 163 | "subMetas": {} 164 | }, 165 | "enemy1_down4.png": { 166 | "ver": "1.0.4", 167 | "uuid": "2f848275-b75c-4044-822c-c4e51a1f2507", 168 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 169 | "trimType": "auto", 170 | "trimThreshold": 1, 171 | "rotated": false, 172 | "offsetX": 0, 173 | "offsetY": -3, 174 | "trimX": 240, 175 | "trimY": 2, 176 | "width": 47, 177 | "height": 39, 178 | "rawWidth": 57, 179 | "rawHeight": 51, 180 | "borderTop": 0, 181 | "borderBottom": 0, 182 | "borderLeft": 0, 183 | "borderRight": 0, 184 | "spriteType": "normal", 185 | "subMetas": {} 186 | }, 187 | "enemy2.png": { 188 | "ver": "1.0.4", 189 | "uuid": "99988337-adc3-4d69-b856-39523782e41f", 190 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 191 | "trimType": "auto", 192 | "trimThreshold": 1, 193 | "rotated": true, 194 | "offsetX": 0, 195 | "offsetY": 3, 196 | "trimX": 835, 197 | "trimY": 2, 198 | "width": 69, 199 | "height": 89, 200 | "rawWidth": 69, 201 | "rawHeight": 99, 202 | "borderTop": 0, 203 | "borderBottom": 0, 204 | "borderLeft": 0, 205 | "borderRight": 0, 206 | "spriteType": "normal", 207 | "subMetas": {} 208 | }, 209 | "enemy2_down1.png": { 210 | "ver": "1.0.4", 211 | "uuid": "40348214-6d0d-4ead-9ed0-657ee00e5833", 212 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 213 | "trimType": "auto", 214 | "trimThreshold": 1, 215 | "rotated": true, 216 | "offsetX": 0, 217 | "offsetY": 0, 218 | "trimX": 2, 219 | "trimY": 42, 220 | "width": 69, 221 | "height": 93, 222 | "rawWidth": 69, 223 | "rawHeight": 95, 224 | "borderTop": 0, 225 | "borderBottom": 0, 226 | "borderLeft": 0, 227 | "borderRight": 0, 228 | "spriteType": "normal", 229 | "subMetas": {} 230 | }, 231 | "enemy2_down2.png": { 232 | "ver": "1.0.4", 233 | "uuid": "ed48f322-1cd9-473c-aacb-689a1bb2f770", 234 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 235 | "trimType": "auto", 236 | "trimThreshold": 1, 237 | "rotated": true, 238 | "offsetX": 0, 239 | "offsetY": 0, 240 | "trimX": 926, 241 | "trimY": 2, 242 | "width": 69, 243 | "height": 93, 244 | "rawWidth": 69, 245 | "rawHeight": 95, 246 | "borderTop": 0, 247 | "borderBottom": 0, 248 | "borderLeft": 0, 249 | "borderRight": 0, 250 | "spriteType": "normal", 251 | "subMetas": {} 252 | }, 253 | "enemy2_down3.png": { 254 | "ver": "1.0.4", 255 | "uuid": "d9b97614-a4fe-4f5f-b5de-8f9a718aad2b", 256 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 257 | "trimType": "auto", 258 | "trimThreshold": 1, 259 | "rotated": true, 260 | "offsetX": 0, 261 | "offsetY": 0, 262 | "trimX": 273, 263 | "trimY": 46, 264 | "width": 69, 265 | "height": 95, 266 | "rawWidth": 69, 267 | "rawHeight": 95, 268 | "borderTop": 0, 269 | "borderBottom": 0, 270 | "borderLeft": 0, 271 | "borderRight": 0, 272 | "spriteType": "normal", 273 | "subMetas": {} 274 | }, 275 | "enemy2_down4.png": { 276 | "ver": "1.0.4", 277 | "uuid": "757294e3-de13-4a1c-9c8d-f5f33e2d1583", 278 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 279 | "trimType": "auto", 280 | "trimThreshold": 1, 281 | "rotated": true, 282 | "offsetX": 0, 283 | "offsetY": -4, 284 | "trimX": 194, 285 | "trimY": 43, 286 | "width": 69, 287 | "height": 77, 288 | "rawWidth": 69, 289 | "rawHeight": 95, 290 | "borderTop": 0, 291 | "borderBottom": 0, 292 | "borderLeft": 0, 293 | "borderRight": 0, 294 | "spriteType": "normal", 295 | "subMetas": {} 296 | }, 297 | "enemy2_hit.png": { 298 | "ver": "1.0.4", 299 | "uuid": "8d5db4a5-09fd-4615-bee9-336f21a3e7c0", 300 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 301 | "trimType": "auto", 302 | "trimThreshold": 1, 303 | "rotated": true, 304 | "offsetX": 0, 305 | "offsetY": 0, 306 | "trimX": 97, 307 | "trimY": 43, 308 | "width": 69, 309 | "height": 95, 310 | "rawWidth": 69, 311 | "rawHeight": 99, 312 | "borderTop": 0, 313 | "borderBottom": 0, 314 | "borderLeft": 0, 315 | "borderRight": 0, 316 | "spriteType": "normal", 317 | "subMetas": {} 318 | }, 319 | "enemy3_down1.png": { 320 | "ver": "1.0.4", 321 | "uuid": "b7a39f10-98aa-4f3e-b89d-94bdaf0cf489", 322 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 323 | "trimType": "auto", 324 | "trimThreshold": 1, 325 | "rotated": true, 326 | "offsetX": 0, 327 | "offsetY": 1, 328 | "trimX": 2, 329 | "trimY": 324, 330 | "width": 165, 331 | "height": 255, 332 | "rawWidth": 165, 333 | "rawHeight": 261, 334 | "borderTop": 0, 335 | "borderBottom": 0, 336 | "borderLeft": 0, 337 | "borderRight": 0, 338 | "spriteType": "normal", 339 | "subMetas": {} 340 | }, 341 | "enemy3_down2.png": { 342 | "ver": "1.0.4", 343 | "uuid": "21805c5c-525d-45e2-a667-9e69d87b5b19", 344 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 345 | "trimType": "auto", 346 | "trimThreshold": 1, 347 | "rotated": true, 348 | "offsetX": 0, 349 | "offsetY": 2, 350 | "trimX": 464, 351 | "trimY": 164, 352 | "width": 165, 353 | "height": 255, 354 | "rawWidth": 165, 355 | "rawHeight": 261, 356 | "borderTop": 0, 357 | "borderBottom": 0, 358 | "borderLeft": 0, 359 | "borderRight": 0, 360 | "spriteType": "normal", 361 | "subMetas": {} 362 | }, 363 | "enemy3_down3.png": { 364 | "ver": "1.0.4", 365 | "uuid": "ecf47e0a-1017-4e27-9161-50cb43377817", 366 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 367 | "trimType": "auto", 368 | "trimThreshold": 1, 369 | "rotated": true, 370 | "offsetX": 0, 371 | "offsetY": 2, 372 | "trimX": 259, 373 | "trimY": 331, 374 | "width": 165, 375 | "height": 256, 376 | "rawWidth": 165, 377 | "rawHeight": 260, 378 | "borderTop": 0, 379 | "borderBottom": 0, 380 | "borderLeft": 0, 381 | "borderRight": 0, 382 | "spriteType": "normal", 383 | "subMetas": {} 384 | }, 385 | "enemy3_down4.png": { 386 | "ver": "1.0.4", 387 | "uuid": "fd198620-068b-4e15-9649-713061b62872", 388 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 389 | "trimType": "auto", 390 | "trimThreshold": 1, 391 | "rotated": true, 392 | "offsetX": 0, 393 | "offsetY": 2, 394 | "trimX": 207, 395 | "trimY": 157, 396 | "width": 165, 397 | "height": 255, 398 | "rawWidth": 165, 399 | "rawHeight": 261, 400 | "borderTop": 0, 401 | "borderBottom": 0, 402 | "borderLeft": 0, 403 | "borderRight": 0, 404 | "spriteType": "normal", 405 | "subMetas": {} 406 | }, 407 | "enemy3_down5.png": { 408 | "ver": "1.0.4", 409 | "uuid": "e46e6210-343f-4d75-a120-95ac16ab9c93", 410 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 411 | "trimType": "auto", 412 | "trimThreshold": 1, 413 | "rotated": true, 414 | "offsetX": 0, 415 | "offsetY": 2, 416 | "trimX": 2, 417 | "trimY": 498, 418 | "width": 166, 419 | "height": 256, 420 | "rawWidth": 166, 421 | "rawHeight": 260, 422 | "borderTop": 0, 423 | "borderBottom": 0, 424 | "borderLeft": 0, 425 | "borderRight": 0, 426 | "spriteType": "normal", 427 | "subMetas": {} 428 | }, 429 | "enemy3_down6.png": { 430 | "ver": "1.0.4", 431 | "uuid": "6a380b86-a165-4ed2-9c12-3c7d906f7c46", 432 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 433 | "trimType": "auto", 434 | "trimThreshold": 1, 435 | "rotated": true, 436 | "offsetX": -8, 437 | "offsetY": 18, 438 | "trimX": 2, 439 | "trimY": 114, 440 | "width": 144, 441 | "height": 203, 442 | "rawWidth": 166, 443 | "rawHeight": 261, 444 | "borderTop": 0, 445 | "borderBottom": 0, 446 | "borderLeft": 0, 447 | "borderRight": 0, 448 | "spriteType": "normal", 449 | "subMetas": {} 450 | }, 451 | "enemy3_hit.png": { 452 | "ver": "1.0.4", 453 | "uuid": "b88060dd-e519-4947-8c14-7b8704ff9d35", 454 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 455 | "trimType": "auto", 456 | "trimThreshold": 1, 457 | "rotated": true, 458 | "offsetX": 0, 459 | "offsetY": 0, 460 | "trimX": 721, 461 | "trimY": 175, 462 | "width": 165, 463 | "height": 256, 464 | "rawWidth": 169, 465 | "rawHeight": 258, 466 | "borderTop": 0, 467 | "borderBottom": 0, 468 | "borderLeft": 0, 469 | "borderRight": 0, 470 | "spriteType": "normal", 471 | "subMetas": {} 472 | }, 473 | "enemy3_n1.png": { 474 | "ver": "1.0.4", 475 | "uuid": "1e7abee4-7126-4381-aae3-39967c4b3496", 476 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 477 | "trimType": "auto", 478 | "trimThreshold": 1, 479 | "rotated": true, 480 | "offsetX": 0, 481 | "offsetY": 4, 482 | "trimX": 517, 483 | "trimY": 342, 484 | "width": 165, 485 | "height": 246, 486 | "rawWidth": 169, 487 | "rawHeight": 258, 488 | "borderTop": 0, 489 | "borderBottom": 0, 490 | "borderLeft": 0, 491 | "borderRight": 0, 492 | "spriteType": "normal", 493 | "subMetas": {} 494 | }, 495 | "enemy3_n2.png": { 496 | "ver": "1.0.4", 497 | "uuid": "f817bce6-3ac4-40fb-988b-d6aabfe0eb02", 498 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 499 | "trimType": "auto", 500 | "trimThreshold": 1, 501 | "rotated": true, 502 | "offsetX": 0, 503 | "offsetY": 3, 504 | "trimX": 765, 505 | "trimY": 342, 506 | "width": 165, 507 | "height": 250, 508 | "rawWidth": 169, 509 | "rawHeight": 258, 510 | "borderTop": 0, 511 | "borderBottom": 0, 512 | "borderLeft": 0, 513 | "borderRight": 0, 514 | "spriteType": "normal", 515 | "subMetas": {} 516 | }, 517 | "game_pause_nor.png": { 518 | "ver": "1.0.4", 519 | "uuid": "0e182eac-d0ea-4a77-bc00-81140173a4f8", 520 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 521 | "trimType": "auto", 522 | "trimThreshold": 1, 523 | "rotated": true, 524 | "offsetX": -1, 525 | "offsetY": 0, 526 | "trimX": 336, 527 | "trimY": 2, 528 | "width": 42, 529 | "height": 45, 530 | "rawWidth": 60, 531 | "rawHeight": 45, 532 | "borderTop": 0, 533 | "borderBottom": 0, 534 | "borderLeft": 0, 535 | "borderRight": 0, 536 | "spriteType": "normal", 537 | "subMetas": {} 538 | }, 539 | "game_pause_pressed.png": { 540 | "ver": "1.0.4", 541 | "uuid": "271cf2bd-1fad-48c4-9b79-48a0e3b69698", 542 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 543 | "trimType": "auto", 544 | "trimThreshold": 1, 545 | "rotated": true, 546 | "offsetX": -1, 547 | "offsetY": 0, 548 | "trimX": 289, 549 | "trimY": 2, 550 | "width": 42, 551 | "height": 45, 552 | "rawWidth": 60, 553 | "rawHeight": 45, 554 | "borderTop": 0, 555 | "borderBottom": 0, 556 | "borderLeft": 0, 557 | "borderRight": 0, 558 | "spriteType": "normal", 559 | "subMetas": {} 560 | }, 561 | "game_resume_nor.png": { 562 | "ver": "1.0.4", 563 | "uuid": "c8fcb3fb-2468-4733-b140-0ff78b8c6a8e", 564 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 565 | "trimType": "auto", 566 | "trimThreshold": 1, 567 | "rotated": true, 568 | "offsetX": 3, 569 | "offsetY": 0, 570 | "trimX": 91, 571 | "trimY": 2, 572 | "width": 38, 573 | "height": 41, 574 | "rawWidth": 60, 575 | "rawHeight": 45, 576 | "borderTop": 0, 577 | "borderBottom": 0, 578 | "borderLeft": 0, 579 | "borderRight": 0, 580 | "spriteType": "normal", 581 | "subMetas": {} 582 | }, 583 | "game_resume_pressed.png": { 584 | "ver": "1.0.4", 585 | "uuid": "b5c38109-a95e-4bf7-a079-a807a90a4717", 586 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 587 | "trimType": "auto", 588 | "trimThreshold": 1, 589 | "rotated": true, 590 | "offsetX": 3, 591 | "offsetY": 0, 592 | "trimX": 48, 593 | "trimY": 2, 594 | "width": 38, 595 | "height": 41, 596 | "rawWidth": 60, 597 | "rawHeight": 45, 598 | "borderTop": 0, 599 | "borderBottom": 0, 600 | "borderLeft": 0, 601 | "borderRight": 0, 602 | "spriteType": "normal", 603 | "subMetas": {} 604 | }, 605 | "hero1.png": { 606 | "ver": "1.0.4", 607 | "uuid": "757bdc28-b120-4eaa-868b-db290dcd4371", 608 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 609 | "trimType": "auto", 610 | "trimThreshold": 1, 611 | "rotated": true, 612 | "offsetX": 0, 613 | "offsetY": 0, 614 | "trimX": 872, 615 | "trimY": 73, 616 | "width": 100, 617 | "height": 124, 618 | "rawWidth": 102, 619 | "rawHeight": 126, 620 | "borderTop": 0, 621 | "borderBottom": 0, 622 | "borderLeft": 0, 623 | "borderRight": 0, 624 | "spriteType": "normal", 625 | "subMetas": {} 626 | }, 627 | "hero2.png": { 628 | "ver": "1.0.4", 629 | "uuid": "06157618-9b13-4e1a-be0a-e1e0179a1a73", 630 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 631 | "trimType": "auto", 632 | "trimThreshold": 1, 633 | "rotated": true, 634 | "offsetX": 0, 635 | "offsetY": 1, 636 | "trimX": 370, 637 | "trimY": 55, 638 | "width": 100, 639 | "height": 122, 640 | "rawWidth": 102, 641 | "rawHeight": 126, 642 | "borderTop": 0, 643 | "borderBottom": 0, 644 | "borderLeft": 0, 645 | "borderRight": 0, 646 | "spriteType": "normal", 647 | "subMetas": {} 648 | }, 649 | "hero_blowup_n1.png": { 650 | "ver": "1.0.4", 651 | "uuid": "23ac3e70-ce00-4210-a5bb-cf4fa20f71ad", 652 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 653 | "trimType": "auto", 654 | "trimThreshold": 1, 655 | "rotated": true, 656 | "offsetX": 0, 657 | "offsetY": -1, 658 | "trimX": 746, 659 | "trimY": 73, 660 | "width": 98, 661 | "height": 124, 662 | "rawWidth": 102, 663 | "rawHeight": 126, 664 | "borderTop": 0, 665 | "borderBottom": 0, 666 | "borderLeft": 0, 667 | "borderRight": 0, 668 | "spriteType": "normal", 669 | "subMetas": {} 670 | }, 671 | "hero_blowup_n2.png": { 672 | "ver": "1.0.4", 673 | "uuid": "fc606499-7598-47a4-a0ca-bf4d685e0c47", 674 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 675 | "trimType": "auto", 676 | "trimThreshold": 1, 677 | "rotated": true, 678 | "offsetX": 0, 679 | "offsetY": -1, 680 | "trimX": 620, 681 | "trimY": 64, 682 | "width": 98, 683 | "height": 124, 684 | "rawWidth": 102, 685 | "rawHeight": 126, 686 | "borderTop": 0, 687 | "borderBottom": 0, 688 | "borderLeft": 0, 689 | "borderRight": 0, 690 | "spriteType": "normal", 691 | "subMetas": {} 692 | }, 693 | "hero_blowup_n3.png": { 694 | "ver": "1.0.4", 695 | "uuid": "7f2c642f-833b-4f01-8a39-d316b5d051da", 696 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 697 | "trimType": "auto", 698 | "trimThreshold": 1, 699 | "rotated": true, 700 | "offsetX": 0, 701 | "offsetY": -1, 702 | "trimX": 494, 703 | "trimY": 62, 704 | "width": 98, 705 | "height": 124, 706 | "rawWidth": 102, 707 | "rawHeight": 126, 708 | "borderTop": 0, 709 | "borderBottom": 0, 710 | "borderLeft": 0, 711 | "borderRight": 0, 712 | "spriteType": "normal", 713 | "subMetas": {} 714 | }, 715 | "hero_blowup_n4.png": { 716 | "ver": "1.0.4", 717 | "uuid": "a0467d15-ec09-486a-8365-6e36e72eaed3", 718 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 719 | "trimType": "auto", 720 | "trimThreshold": 1, 721 | "rotated": true, 722 | "offsetX": 0, 723 | "offsetY": 5, 724 | "trimX": 755, 725 | "trimY": 2, 726 | "width": 66, 727 | "height": 78, 728 | "rawWidth": 102, 729 | "rawHeight": 126, 730 | "borderTop": 0, 731 | "borderBottom": 0, 732 | "borderLeft": 0, 733 | "borderRight": 0, 734 | "spriteType": "normal", 735 | "subMetas": {} 736 | }, 737 | "ufo1.png": { 738 | "ver": "1.0.4", 739 | "uuid": "8de7682c-16a3-44df-9fb6-2ba82275700e", 740 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 741 | "trimType": "auto", 742 | "trimThreshold": 1, 743 | "rotated": true, 744 | "offsetX": 0, 745 | "offsetY": 0, 746 | "trimX": 560, 747 | "trimY": 2, 748 | "width": 58, 749 | "height": 88, 750 | "rawWidth": 58, 751 | "rawHeight": 88, 752 | "borderTop": 0, 753 | "borderBottom": 0, 754 | "borderLeft": 0, 755 | "borderRight": 0, 756 | "spriteType": "normal", 757 | "subMetas": {} 758 | }, 759 | "ufo2.png": { 760 | "ver": "1.0.4", 761 | "uuid": "ebe5e008-ee8e-4c2f-be0d-712d802062c4", 762 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 763 | "trimType": "auto", 764 | "trimThreshold": 1, 765 | "rotated": true, 766 | "offsetX": 0, 767 | "offsetY": 0, 768 | "trimX": 650, 769 | "trimY": 2, 770 | "width": 60, 771 | "height": 103, 772 | "rawWidth": 60, 773 | "rawHeight": 107, 774 | "borderTop": 0, 775 | "borderBottom": 0, 776 | "borderLeft": 0, 777 | "borderRight": 0, 778 | "spriteType": "normal", 779 | "subMetas": {} 780 | } 781 | } 782 | } -------------------------------------------------------------------------------- /assets/Texture/shoot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/shoot.png -------------------------------------------------------------------------------- /assets/Texture/shoot.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "shoot": { 11 | "ver": "1.0.4", 12 | "uuid": "88eea3a8-5aef-4cfe-9605-05166984cd57", 13 | "rawTextureUuid": "b60fc61d-0869-437e-9223-edb1bbe9eed1", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": -1.5, 18 | "offsetY": 179, 19 | "trimX": 2, 20 | "trimY": 2, 21 | "width": 1017, 22 | "height": 662, 23 | "rawWidth": 1024, 24 | "rawHeight": 1024, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/start.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/start.png -------------------------------------------------------------------------------- /assets/Texture/start.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "3ed9ead6-3caf-4cae-9146-4d167145672b", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "start": { 11 | "ver": "1.0.4", 12 | "uuid": "33ce9f8e-61fe-4d15-ad15-782ccdc9a60b", 13 | "rawTextureUuid": "3ed9ead6-3caf-4cae-9146-4d167145672b", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": -0.5, 18 | "offsetY": -1.5, 19 | "trimX": 27, 20 | "trimY": 21, 21 | "width": 217, 22 | "height": 59, 23 | "rawWidth": 272, 24 | "rawHeight": 98, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/title.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/title.png -------------------------------------------------------------------------------- /assets/Texture/title.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "8ae16807-3c9a-443f-aa6c-d2cd502d295e", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "title": { 11 | "ver": "1.0.4", 12 | "uuid": "c2531f80-67fb-4c6f-bff9-f5e0b5ff1bbe", 13 | "rawTextureUuid": "8ae16807-3c9a-443f-aa6c-d2cd502d295e", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 7, 18 | "offsetY": -2, 19 | "trimX": 28, 20 | "trimY": 22, 21 | "width": 594, 22 | "height": 176, 23 | "rawWidth": 636, 24 | "rawHeight": 216, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /assets/Texture/yellow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/assets/Texture/yellow.png -------------------------------------------------------------------------------- /assets/Texture/yellow.png.meta: -------------------------------------------------------------------------------- 1 | { 2 | "ver": "2.3.1", 3 | "uuid": "8875fcf3-6f5b-4d91-87cc-c26396bac2e6", 4 | "type": "sprite", 5 | "wrapMode": "clamp", 6 | "filterMode": "bilinear", 7 | "premultiplyAlpha": false, 8 | "platformSettings": {}, 9 | "subMetas": { 10 | "yellow": { 11 | "ver": "1.0.4", 12 | "uuid": "d838d87c-dc65-4023-a2f8-d6eebe97ac6b", 13 | "rawTextureUuid": "8875fcf3-6f5b-4d91-87cc-c26396bac2e6", 14 | "trimType": "auto", 15 | "trimThreshold": 1, 16 | "rotated": false, 17 | "offsetX": 35, 18 | "offsetY": 0.5, 19 | "trimX": 70, 20 | "trimY": 71, 21 | "width": 380, 22 | "height": 307, 23 | "rawWidth": 450, 24 | "rawHeight": 450, 25 | "borderTop": 0, 26 | "borderBottom": 0, 27 | "borderLeft": 0, 28 | "borderRight": 0, 29 | "subMetas": {} 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /doc/game.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/doc/game.png -------------------------------------------------------------------------------- /doc/login.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/doc/login.png -------------------------------------------------------------------------------- /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 | } -------------------------------------------------------------------------------- /project.json: -------------------------------------------------------------------------------- 1 | { 2 | "engine": "cocos2d-html5", 3 | "packages": "packages", 4 | "version": "2.1.2" 5 | } -------------------------------------------------------------------------------- /settings/builder.json: -------------------------------------------------------------------------------- 1 | { 2 | "android-instant": { 3 | "REMOTE_SERVER_ROOT": "", 4 | "host": "", 5 | "pathPattern": "", 6 | "recordPath": "", 7 | "scheme": "https", 8 | "skipRecord": false 9 | }, 10 | "appBundle": false, 11 | "baidugame": { 12 | "REMOTE_SERVER_ROOT": "", 13 | "appid": "testappid", 14 | "orientation": "portrait", 15 | "subContext": "" 16 | }, 17 | "encryptJs": false, 18 | "excludeScenes": [], 19 | "fb-instant-games": {}, 20 | "includeSDKBox": false, 21 | "inlineSpriteFrames": true, 22 | "inlineSpriteFrames_native": false, 23 | "md5Cache": false, 24 | "mergeStartScene": false, 25 | "optimizeHotUpdate": false, 26 | "orientation": { 27 | "landscapeLeft": true, 28 | "landscapeRight": true, 29 | "portrait": false, 30 | "upsideDown": false 31 | }, 32 | "packageName": "org.cocos2d.shootgame", 33 | "qqplay": { 34 | "REMOTE_SERVER_ROOT": "", 35 | "orientation": "portrait" 36 | }, 37 | "startScene": "991efca1-4933-478e-b0b0-00c9e48fbbf6", 38 | "title": "avatar-fight-client", 39 | "webOrientation": "landscape", 40 | "wechatgame": { 41 | "appid": "", 42 | "orientation": "landscape" 43 | }, 44 | "xxteaKey": "28860d39-a818-43", 45 | "zipCompressJs": true 46 | } -------------------------------------------------------------------------------- /settings/builder.panel.json: -------------------------------------------------------------------------------- 1 | { 2 | "excludeScenes": [], 3 | "packageName": "org.cocos2d.helloworld", 4 | "platform": "web-mobile", 5 | "startScene": "2d2f792f-a40c-49bb-a189-ed176a246e49", 6 | "title": "HelloWorld" 7 | } -------------------------------------------------------------------------------- /settings/project.json: -------------------------------------------------------------------------------- 1 | { 2 | "assets-sort-type": "name", 3 | "collision-matrix": [ 4 | [ 5 | true 6 | ], 7 | [ 8 | false, 9 | false 10 | ] 11 | ], 12 | "design-resolution-height": 640, 13 | "design-resolution-width": 960, 14 | "excluded-modules": [ 15 | "Geom Utils", 16 | "3D", 17 | "3D Primitive" 18 | ], 19 | "facebook": { 20 | "appID": "", 21 | "audience": { 22 | "enable": false 23 | }, 24 | "enable": false, 25 | "live": { 26 | "enable": false 27 | } 28 | }, 29 | "fit-height": true, 30 | "fit-width": false, 31 | "group-list": [ 32 | "default", 33 | "UI" 34 | ], 35 | "last-module-event-record-time": 1683989540770, 36 | "simulator-orientation": false, 37 | "simulator-resolution": { 38 | "height": 640, 39 | "width": 960 40 | }, 41 | "start-scene": "991efca1-4933-478e-b0b0-00c9e48fbbf6", 42 | "use-customize-simulator": true, 43 | "use-project-simulator-setting": false 44 | } -------------------------------------------------------------------------------- /settings/services.json: -------------------------------------------------------------------------------- 1 | { 2 | "services": [ 3 | { 4 | "service_id": "315", 5 | "service_name": "易盾", 6 | "service_icon": "https://download.cocos.com/CocosUdc/client/ba8776b5e3/c14b56b30d2b156c2682cb820c7f55b1.png", 7 | "service_desc": "为开发者提供游戏包体加固及游戏反外挂能力,开发者构建过程中自助完成SDK集成、构建完成后一键式进行包体加固,开发者无需再为游戏安全防护进行额外开发工作,可以专注于游戏业务,轻松搭建游戏防御体系。支持全平台:Android、iOS、H5。", 8 | "service_title": "提供游戏包体加固、反外挂一站式服务", 9 | "service_guide_url": "https://service.cocos.com/document/zh/neteaseyidun.html", 10 | "service_sample_url": "https://github.com/CocosService/neteaseDemo", 11 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=315&app_id=&language=zh", 12 | "service_type": "3", 13 | "service_type_zh": "公司和个人游戏", 14 | "support_platform": [ 15 | "安卓", 16 | "iOS" 17 | ], 18 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-neteaseyidun/0.5.3_5.0.4_1.7.1.3.zip", 19 | "package_version_desc": "

更新日期: 2021/11/15
\n更新说明:
\n1.改为 WEBVIEW 的方式打开注册页面取代浏览器
\n2.注册时自动帮助用户填写公司名称和手机号等字段(由用户 Cocos 账号获取)
\n", 20 | "service_component_name": "service-neteaseyidun", 21 | "package_versions": [ 22 | "0.5.2_5.0.4_1.7.1.3", 23 | "0.5.3_5.0.4_1.7.1.3" 24 | ], 25 | "build_platform": [], 26 | "require_verify": 1, 27 | "service_price": "", 28 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 29 | "service_group": "", 30 | "service_group_id": "", 31 | "not_service": false 32 | }, 33 | { 34 | "service_id": "235", 35 | "service_name": "Cocos Analytics", 36 | "service_icon": "https://download.cocos.com/CocosUdc/client/dae922b126/1eb776afa85e5ae6dd17fd1939a12948.png", 37 | "service_desc": "Cocos Analytics 服务即将下线,开启服务的入口也将会尽快关闭。我们对此带来的不便表示歉意,若有需要可联系 chenfeng@cocos.com,感谢您的理解与支持", 38 | "service_title": "服务即将下线,开启服务的入口也将会尽快关闭。我们对此带来的不便表示歉意,若有需要可联系 chenfeng@cocos.com,感谢您的理解与支持", 39 | "service_guide_url": "https://n-analytics.cocos.com/docs", 40 | "service_sample_url": "https://github.com/CocosService/cocosAnalyticsDemo", 41 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=235&app_id=&language=zh", 42 | "service_type": "3", 43 | "service_type_zh": "公司和个人游戏", 44 | "support_platform": [ 45 | "安卓", 46 | "iOS", 47 | "H5" 48 | ], 49 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-analytics/1.4.5_3.0.2.zip", 50 | "package_version_desc": "

更新日志:
\n移除渠道信息网站。
\n", 51 | "service_component_name": "service-analytics", 52 | "package_versions": [ 53 | "1.0.0_1.0.5", 54 | "1.1.2_2.0.0", 55 | "1.1.3_2.0.1", 56 | "1.1.4_2.0.1", 57 | "1.1.5_2.0.1", 58 | "1.1.6_2.0.1_2.0.2", 59 | "1.1.7_2.0.3", 60 | "1.2.0_2.1.0", 61 | "1.2.3_2.1.1", 62 | "1.2.5_2.1.1", 63 | "1.2.6_2.1.1", 64 | "1.2.7_2.1.2", 65 | "1.2.8_2.1.3", 66 | "1.2.9_2.2.0", 67 | "1.3.5_2.2.1", 68 | "1.3.7_2.2.1", 69 | "1.4.0_3.0.2", 70 | "1.4.1_3.0.2", 71 | "1.4.4_3.0.2", 72 | "1.4.5_3.0.2" 73 | ], 74 | "build_platform": [], 75 | "require_verify": 0, 76 | "service_price": "", 77 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 78 | "service_group": "", 79 | "service_group_id": "", 80 | "not_service": false 81 | }, 82 | { 83 | "service_id": "242", 84 | "service_name": "Agora RTC", 85 | "service_icon": "https://download.cocos.com/CocosUdc/client/0ed3b350b5/273952d155b4cdb72d2b1bc61de91ade.png", 86 | "service_desc": "稳定、低耗、76ms超低延时、全球200+数据中心覆盖;变声器、超高音质、听声辩位等丰富玩法极速接入;全平台支持:Android、iOS、Web。", 87 | "service_title": "游戏内置实时音视频", 88 | "service_guide_url": "https://service.cocos.com/document/zh/agora.html", 89 | "service_sample_url": "https://github.com/AgoraIO-Community/Agora-Cocos-Quickstart/tree/master/CocosCreator", 90 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=242&app_id=&language=zh", 91 | "service_type": "3", 92 | "service_type_zh": "公司和个人游戏", 93 | "support_platform": [ 94 | "安卓", 95 | "iOS", 96 | "H5" 97 | ], 98 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-agora/1.3.2_3.4.6_3.6.2.zip", 99 | "package_version_desc": "

更新日期: 2021/08/19
\n更新说明:
\n修复iOS15不兼容问题
\n", 100 | "service_component_name": "service-agora", 101 | "package_versions": [ 102 | "1.0.1_2.2.3.20_2.5.2", 103 | "1.0.2_2.2.3.20_2.5.2", 104 | "1.1.0_2.2.3.20_2.5.2", 105 | "1.2.1_3.1.2", 106 | "1.3.1_3.1", 107 | "1.3.2_3.4.6_3.6.2" 108 | ], 109 | "build_platform": [], 110 | "require_verify": 1, 111 | "service_price": "该服务按使用量计费,为开发者提供一定的免费额度,超出免费额度将进行收费,详情请看 计费规则,所产生的费用将从您的 Cocos 账户余额 代扣。", 112 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 113 | "service_group": "", 114 | "service_group_id": "", 115 | "not_service": false 116 | }, 117 | { 118 | "service_id": "278", 119 | "service_name": "Cocos SDKHub", 120 | "service_icon": "https://download.cocos.com/CocosUdc/client/dae922b126/63f4169359e77ff35d9287c1a9506efb.png", 121 | "service_desc": "帮助游戏快速集成渠道SDK", 122 | "service_title": "帮助游戏快速集成渠道SDK", 123 | "service_guide_url": "https://service.cocos.com/document/zh/sdkhub.html", 124 | "service_sample_url": "https://github.com/CocosService/sdkhubDemo", 125 | "service_dev_url": "", 126 | "service_type": "3", 127 | "service_type_zh": "公司和个人游戏", 128 | "support_platform": [ 129 | "安卓" 130 | ], 131 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-sdkhub/0.7.0_0.1.1.zip", 132 | "package_version_desc": "

更新日志:

\n
    \n
  1. 修复一些BUG。
    \n", 133 | "service_component_name": "service-sdkhub", 134 | "package_versions": [ 135 | "0.6.1_0.1.0", 136 | "0.6.2_0.1.0", 137 | "0.6.4_0.1.1", 138 | "0.6.5_0.1.1", 139 | "0.6.6_0.1.1", 140 | "0.6.8_0.1.1", 141 | "0.6.9_0.1.1", 142 | "0.7.0_0.1.1" 143 | ], 144 | "build_platform": [], 145 | "require_verify": 0, 146 | "service_price": "", 147 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 148 | "service_group": "", 149 | "service_group_id": "", 150 | "not_service": false 151 | }, 152 | { 153 | "service_id": "301", 154 | "service_name": "定位服务", 155 | "service_icon": "https://download.cocos.com/CocosUdc/client/e8b3ed0ab3/11e7f4732119ae233a205ec417cfa43d.png", 156 | "service_desc": "华为定位服务(HUAWEI Location Kit)采用GPS、Wi-Fi、基站等多途径的混合定位模式进行定位,赋予应用开发者快速、精准地获取用户位置信息的能力。当前主要能力包含三个部分:融合定位、活动识别和地理围栏。", 157 | "service_title": "赋予应用开发者快速、精准地获取用户位置信息的能力", 158 | "service_guide_url": "https://service.cocos.com/document/zh/hms-location.html", 159 | "service_sample_url": "https://github.com/CocosService/HUAWEIDemo", 160 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=301&app_id=&language=zh", 161 | "service_type": "3", 162 | "service_type_zh": "公司和个人游戏", 163 | "support_platform": [ 164 | "安卓" 165 | ], 166 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-hmslocation/0.5.9_6.4.0.zip", 167 | "package_version_desc": "

    升级定位工具包版本。
    \n", 168 | "service_component_name": "service-hmslocation", 169 | "package_versions": [ 170 | "0.5.6_4.0.4", 171 | "0.5.8_5.0.2", 172 | "0.5.9_6.4.0" 173 | ], 174 | "build_platform": [], 175 | "require_verify": 0, 176 | "service_price": "", 177 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 178 | "service_group": "HUAWEI HMS Core", 179 | "service_group_id": "", 180 | "not_service": false 181 | }, 182 | { 183 | "service_id": "302", 184 | "service_name": "分析服务", 185 | "service_icon": "https://download.cocos.com/CocosUdc/client/e8b3ed0ab3/b134fdbad8be336fb4bbcaef240c99c2.png", 186 | "service_desc": "分析服务(Analytics Kit)预置大量分析模型,可帮助您清晰地了解用户的行为方式,从而实现用户、产品、内容的深度洞察,让您实现基于数据驱动的运营,可以就应用营销和产品优化制定明智的决策。", 187 | "service_title": "预置大量分析模型,可帮助您清晰地了解用户的行为方式", 188 | "service_guide_url": "https://service.cocos.com/document/zh/hms-analytics.html", 189 | "service_sample_url": "https://github.com/CocosService/HUAWEIDemo", 190 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=302&app_id=&language=zh", 191 | "service_type": "3", 192 | "service_type_zh": "公司和个人游戏", 193 | "support_platform": [ 194 | "安卓" 195 | ], 196 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-hmsanalytics/0.5.9_6.4.1.302.zip", 197 | "package_version_desc": "

    升级分析工具包版本。
    \n", 198 | "service_component_name": "service-hmsanalytics", 199 | "package_versions": [ 200 | "0.5.3_5.0.1", 201 | "0.5.5_5.0.5.301", 202 | "0.5.7_5.0.5.301", 203 | "0.5.8_5.0.5.301", 204 | "0.5.9_6.4.1.302" 205 | ], 206 | "build_platform": [], 207 | "require_verify": 0, 208 | "service_price": "", 209 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 210 | "service_group": "HUAWEI HMS Core", 211 | "service_group_id": "", 212 | "not_service": false 213 | }, 214 | { 215 | "service_id": "303", 216 | "service_name": "性能管理", 217 | "service_icon": "https://download.cocos.com/CocosUdc/client/e8b3ed0ab3/46053c315d7c023d22b87fb78fa03e0d.png", 218 | "service_desc": "性能管理(APM,App Performance Management)服务提供分钟级应用性能监控能力,开发者可以在AGC查看和分析APM收集到的应用性能数据,从而全面了解所开发应用的性能特点,快速精准修复应用存在的性能问题,持续提升应用的用户体验。", 219 | "service_title": "提供分钟级应用性能监控能力,收集应用性能数据", 220 | "service_guide_url": "https://service.cocos.com/document/zh/agc-apm.html", 221 | "service_sample_url": "https://github.com/CocosService/HUAWEIDemo", 222 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=303&app_id=&language=zh", 223 | "service_type": "3", 224 | "service_type_zh": "公司和个人游戏", 225 | "support_platform": [ 226 | "安卓" 227 | ], 228 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-agcapms/0.5.6_1.5.2.300.zip", 229 | "package_version_desc": "

    1、更新 AGC SDK 版本到 v1.6.0.300
    \n", 230 | "service_component_name": "service-agcapms", 231 | "package_versions": [ 232 | "0.5.1_1.3.1", 233 | "0.5.2_1.3.1.300", 234 | "0.5.3_1.5.2.300", 235 | "0.5.4_1.5.2.300", 236 | "0.5.6_1.5.2.300" 237 | ], 238 | "build_platform": [], 239 | "require_verify": 0, 240 | "service_price": "", 241 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 242 | "service_group": "HUAWEI AppGallery Connect", 243 | "service_group_id": "1001", 244 | "not_service": false 245 | }, 246 | { 247 | "service_id": "304", 248 | "service_name": "认证服务", 249 | "service_icon": "https://download.cocos.com/CocosUdc/client/e8b3ed0ab3/87fab3ee7098640a3a6bcaf9b6d41f31.png", 250 | "service_desc": "AppGallery Connect认证服务支持多种认证方式,并与其他Serverless服务紧密集成,您可以通过简单的规则定义来保护您的用户的数据安全。", 251 | "service_title": "基于预构建的托管式认证系统,更有效率地保护您的移动和Web用户的数据安全。", 252 | "service_guide_url": "https://service.cocos.com/document/zh/agc-auth.html", 253 | "service_sample_url": "https://github.com/CocosService/HUAWEIDemo", 254 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=304&app_id=&language=zh", 255 | "service_type": "3", 256 | "service_type_zh": "公司和个人游戏", 257 | "support_platform": [ 258 | "安卓" 259 | ], 260 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-agcauth/0.5.6_1.6.0.300.zip", 261 | "package_version_desc": "

    1、更新 AGC SDK 版本到 v1.6.0.300
    \n2、更新 service SDK 版本到 v1.6.0.300
    \n", 262 | "service_component_name": "service-agcauth", 263 | "package_versions": [ 264 | "0.5.1_1.3.1", 265 | "0.5.2_1.4.1.300", 266 | "0.5.3_1.4.1.300", 267 | "0.5.6_1.6.0.300" 268 | ], 269 | "build_platform": [], 270 | "require_verify": 0, 271 | "service_price": "", 272 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 273 | "service_group": "HUAWEI AppGallery Connect", 274 | "service_group_id": "1001", 275 | "not_service": false 276 | }, 277 | { 278 | "service_id": "305", 279 | "service_name": "崩溃服务", 280 | "service_icon": "https://download.cocos.com/CocosUdc/client/e8b3ed0ab3/8ea2f92ed25f2b15c194f1687d55f53e.png", 281 | "service_desc": "崩溃服务是一个轻量级崩溃分析服务,它为您提供了 Crash SDK,可以零代码快速集成。您可以通过崩溃报告了解您的应用崩溃情况,我们提供最近 1 小时的实时报告,您可以实时监测应用质量", 282 | "service_title": "实时数据报告,多维度分析,快速解决崩溃问题。", 283 | "service_guide_url": "https://service.cocos.com/document/zh/agc-crash.html", 284 | "service_sample_url": "https://github.com/CocosService/HUAWEIDemo", 285 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=305&app_id=&language=zh", 286 | "service_type": "3", 287 | "service_type_zh": "公司和个人游戏", 288 | "support_platform": [ 289 | "安卓" 290 | ], 291 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-agccrash/0.5.8_1.6.0.300.zip", 292 | "package_version_desc": "

    1、更新 AGC SDK 版本到 v1.6.0.300
    \n2、更新 service SDK 版本到 v1.6.0.300
    \n", 293 | "service_component_name": "service-agccrash", 294 | "package_versions": [ 295 | "0.5.3_1.3.2", 296 | "0.5.5_1.4.1.300", 297 | "0.5.8_1.6.0.300" 298 | ], 299 | "build_platform": [], 300 | "require_verify": 0, 301 | "service_price": "", 302 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 303 | "service_group": "HUAWEI AppGallery Connect", 304 | "service_group_id": "1001", 305 | "not_service": false 306 | }, 307 | { 308 | "service_id": "306", 309 | "service_name": "App Linking", 310 | "service_icon": "https://download.cocos.com/CocosUdc/client/e8b3ed0ab3/c6f540a4b1f061a3aa552e1875dd8bc2.png", 311 | "service_desc": "App Linking是一种无论应用是否已经安装都可以按照所需方式工作的跨平台链接,创建App Linking后将链接地址多渠道分发,用户点击链接后即可跳转到链接指定的内容,有长链接和短链接之分。", 312 | "service_title": "跨平台深度链接直达应用内内容,推动应用增长。", 313 | "service_guide_url": "https://service.cocos.com/document/zh/agc-applinking.html", 314 | "service_sample_url": "https://github.com/CocosService/HUAWEIDemo", 315 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=306&app_id=&language=zh", 316 | "service_type": "3", 317 | "service_type_zh": "公司和个人游戏", 318 | "support_platform": [ 319 | "安卓" 320 | ], 321 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-agcapplinking/0.6.2_1.6.0.300.zip", 322 | "package_version_desc": "

    1、更新 AGC SDK 版本到 v1.6.0.300
    \n2、更新 service SDK 版本到 v1.6.0.300
    \n", 323 | "service_component_name": "service-agcapplinking", 324 | "package_versions": [ 325 | "0.5.2_1.3.2", 326 | "0.5.4_1.3.2", 327 | "0.5.7_1.4.1.300", 328 | "0.5.9_1.4.1.300", 329 | "0.6.0_1.4.2.301", 330 | "0.6.2_1.6.0.300" 331 | ], 332 | "build_platform": [], 333 | "require_verify": 0, 334 | "service_price": "", 335 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 336 | "service_group": "HUAWEI AppGallery Connect", 337 | "service_group_id": "1001", 338 | "not_service": false 339 | }, 340 | { 341 | "service_id": "307", 342 | "service_name": "应用内消息", 343 | "service_icon": "https://download.cocos.com/CocosUdc/client/e8b3ed0ab3/8d648e354363686963ad739c5ae31113.png", 344 | "service_desc": "应用内消息服务(App Messaging),实现用户使用应用时,向活跃用户发送有针对性的消息来鼓励用户使用应用的关键功能,从而吸引这些用户。例如,通过应用内消息,您可以鼓励用户订阅、给出某个关卡的通过提示,或者推荐某个餐厅活动。", 345 | "service_title": "基于用户使用情境发送上下文相关消息,增强用户粘性。", 346 | "service_guide_url": "https://service.cocos.com/document/zh/agc-appmessaging.html", 347 | "service_sample_url": "https://github.com/CocosService/HUAWEIDemo", 348 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=307&app_id=&language=zh", 349 | "service_type": "3", 350 | "service_type_zh": "公司和个人游戏", 351 | "support_platform": [ 352 | "安卓" 353 | ], 354 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-agcappmessaging/0.6.0_1.6.0.300.zip", 355 | "package_version_desc": "

    1、更新 AGC SDK 版本到 v1.6.0.300
    \n2、更新 service SDK 版本到 v1.6.0.300
    \n", 356 | "service_component_name": "service-agcappmessaging", 357 | "package_versions": [ 358 | "0.5.2_1.4.0", 359 | "0.5.3_1.4.0", 360 | "0.5.3_1.4.0", 361 | "0.5.6_1.4.2.301", 362 | "0.6.0_1.6.0.300" 363 | ], 364 | "build_platform": [], 365 | "require_verify": 0, 366 | "service_price": "", 367 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 368 | "service_group": "HUAWEI AppGallery Connect", 369 | "service_group_id": "1001", 370 | "not_service": false 371 | }, 372 | { 373 | "service_id": "308", 374 | "service_name": "远程配置", 375 | "service_icon": "https://download.cocos.com/CocosUdc/client/e8b3ed0ab3/cb1415def30cb297a226334a4c8866c1.png", 376 | "service_desc": "AppGallery Connect远程配置服务提供了在线的配置项管理能力,可以实现应用在线更改行为和外观,而无需用户下载应用更新。", 377 | "service_title": "无需升级引用,也可灵活修改应用的行为和外观", 378 | "service_guide_url": "https://service.cocos.com/document/zh/agc-remote.html", 379 | "service_sample_url": "https://github.com/CocosService/HUAWEIDemo", 380 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=308&app_id=&language=zh", 381 | "service_type": "3", 382 | "service_type_zh": "公司和个人游戏", 383 | "support_platform": [ 384 | "安卓" 385 | ], 386 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-agcremoteconfig/0.5.3_1.6.0.300.zip", 387 | "package_version_desc": "

    1、更新 AGC SDK 版本到 v1.6.0.300
    \n2、更新 service SDK 版本到 v1.6.0.300
    \n", 388 | "service_component_name": "service-agcremoteconfig", 389 | "package_versions": [ 390 | "0.5.0_1.4.0", 391 | "0.5.1_1.4.1.300", 392 | "0.5.3_1.6.0.300" 393 | ], 394 | "build_platform": [], 395 | "require_verify": 0, 396 | "service_price": "", 397 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 398 | "service_group": "HUAWEI AppGallery Connect", 399 | "service_group_id": "1001", 400 | "not_service": false 401 | }, 402 | { 403 | "service_id": "309", 404 | "service_name": "云存储", 405 | "service_icon": "https://download.cocos.com/CocosUdc/client/e8b3ed0ab3/477f8cf2c59e70144f7c7060fa8710df.png", 406 | "service_desc": "云存储是专为开发者打造的可伸缩、免维护的云端存储服务,您可以用于存储图片、音频、视频或其他由用户生成的内容。", 407 | "service_title": "跨平台提供高效经济的文件上传下载服务", 408 | "service_guide_url": "https://service.cocos.com/document/zh/agc-cloudstorage.html", 409 | "service_sample_url": "https://github.com/CocosService/HUAWEIDemo", 410 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=309&app_id=&language=zh", 411 | "service_type": "3", 412 | "service_type_zh": "公司和个人游戏", 413 | "support_platform": [ 414 | "安卓" 415 | ], 416 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-agcstorage/0.5.4_1.4.0.100.zip", 417 | "package_version_desc": "

    1、更新 AGC SDK 版本到 v1.6.0.300
    \n", 418 | "service_component_name": "service-agcstorage", 419 | "package_versions": [ 420 | "0.5.1_1.3.0.300", 421 | "0.5.2_1.3.1.100", 422 | "0.5.4_1.4.0.100" 423 | ], 424 | "build_platform": [], 425 | "require_verify": 0, 426 | "service_price": "", 427 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 428 | "service_group": "HUAWEI AppGallery Connect", 429 | "service_group_id": "1001", 430 | "not_service": false 431 | }, 432 | { 433 | "service_id": "311", 434 | "service_name": "云数据库", 435 | "service_icon": "https://download.cocos.com/CocosUdc/client/e8b3ed0ab3/dd6263d489cf79ef7cc4ec8e59f5ca17.png", 436 | "service_desc": "Cloud DB 是一款端云协同的数据库产品,提供端云数据的协同管理、统一的数据模型和丰富的数据管理 API 接口等能力。在保证数据的可用性、可靠性、一致性,以及安全等特性基础上,能够实现数据在客户端和云端之间的无缝同步,并为应用提供离线支持,以帮助开发者快速构建端云、多端协同的应用。", 437 | "service_title": "安全可信的数据管理服务", 438 | "service_guide_url": "https://service.cocos.com/document/zh/agc-clouddb.html", 439 | "service_sample_url": "https://github.com/CocosService/HUAWEIDemo", 440 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=311&app_id=&language=zh", 441 | "service_type": "3", 442 | "service_type_zh": "公司和个人游戏", 443 | "support_platform": [ 444 | "安卓" 445 | ], 446 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-agcclouddb/0.5.7_1.2.3.301.zip", 447 | "package_version_desc": "

    1、更新 AGC SDK 版本到 v1.6.0.300
    \n", 448 | "service_component_name": "service-agcclouddb", 449 | "package_versions": [ 450 | "0.5.1_1.2.1.301", 451 | "0.5.3_1.2.3.301", 452 | "0.5.4_1.2.3.301", 453 | "0.5.5_1.2.3.301", 454 | "0.5.7_1.2.3.301" 455 | ], 456 | "build_platform": [], 457 | "require_verify": 0, 458 | "service_price": "", 459 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 460 | "service_group": "HUAWEI AppGallery Connect", 461 | "service_group_id": "1001", 462 | "not_service": false 463 | }, 464 | { 465 | "service_id": "312", 466 | "service_name": "云函数", 467 | "service_icon": "https://download.cocos.com/CocosUdc/client/e8b3ed0ab3/49138efdcfe5f9653331651da51ce838.png", 468 | "service_desc": "云函数是一项 Serverless 计算服务,提供 FaaS(Function as a Service)能力,可以帮助开发者大幅简化应用开发与运维相关的事务,降低应用功能的实现门槛,快速构建业务能力。", 469 | "service_title": "事件驱动的函数计算平台,保证高可用与伸缩,让您便捷运行代码而无需管理服务器。", 470 | "service_guide_url": "https://service.cocos.com/document/zh/agc-cloudfunc.html", 471 | "service_sample_url": "https://github.com/CocosService/HUAWEIDemo", 472 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=312&app_id=&language=zh", 473 | "service_type": "3", 474 | "service_type_zh": "公司和个人游戏", 475 | "support_platform": [ 476 | "安卓" 477 | ], 478 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-agcfunction/0.5.2_1.6.0.300.zip", 479 | "package_version_desc": "

    1、更新 AGC SDK 版本到 v1.6.0.300
    \n2、更新 service SDK 版本到 v1.6.0.300
    \n", 480 | "service_component_name": "service-agcfunction", 481 | "package_versions": [ 482 | "0.5.0_1.4.1.300", 483 | "0.5.2_1.6.0.300" 484 | ], 485 | "build_platform": [], 486 | "require_verify": 0, 487 | "service_price": "", 488 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 489 | "service_group": "HUAWEI AppGallery Connect", 490 | "service_group_id": "1001", 491 | "not_service": false 492 | }, 493 | { 494 | "service_id": "351", 495 | "service_name": "FrontJS", 496 | "service_icon": "https://download.cocos.com/CocosUdc/client/4b80de6d6b/0bc144d702f68e557ffa73aead1a14f1.png", 497 | "service_desc": "通过 FrontJS SDK 的集成监测应用 Cocos Creator 引擎层面上的脚本异常、网络请求、页面停留、以及UI卡顿等指标,提供异常报告、警报通知及可视化等功能。\n", 498 | "service_title": "蒲公英 FrontJS 崩溃分析性能监测服务", 499 | "service_guide_url": "https://service.cocos.com/document/zh/frontjs.html", 500 | "service_sample_url": "", 501 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=351&app_id=&language=zh", 502 | "service_type": "3", 503 | "service_type_zh": "公司和个人游戏", 504 | "support_platform": [ 505 | "安卓", 506 | "iOS", 507 | "H5", 508 | "小游戏" 509 | ], 510 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-frontjs/1.1.3_1.1.3.zip", 511 | "package_version_desc": "

    更新日期: 2021/06/04
    \n更新说明:
    \n1.修正华为快游戏平台 UA 问题
    \n2.完善本地化设置
    \n3.对于小游戏平台提示添加合法 Request 域名
    \n4.增强内网环境判断
    \n", 512 | "service_component_name": "service-frontjs", 513 | "package_versions": [ 514 | "1.0.1_1.0.1", 515 | "1.1.0_1.1.0", 516 | "1.1.3_1.1.3" 517 | ], 518 | "build_platform": [], 519 | "require_verify": 0, 520 | "service_price": "", 521 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 522 | "service_group": "", 523 | "service_group_id": "", 524 | "not_service": false 525 | }, 526 | { 527 | "service_id": "7", 528 | "service_name": "AnySDK", 529 | "service_icon": "https://download.cocos.com/CocosUdc/client/872b94af2e/3ba1fcf9029140cf08d95813e387d04a.png", 530 | "service_desc": "AnySDK计划关停公告 http://www.anysdk.com/2019/05/2203\n强烈建议新用户或新的游戏不要再开通和使用 AnySDK https://forum.cocos.com/t/creator2-0-10-ios-sdk/79061/10\n", 531 | "service_title": "游戏快速接入第三方SDK的解决方案", 532 | "service_guide_url": "http://docs.anysdk.com", 533 | "service_sample_url": "http://github.com/AnySDK", 534 | "service_dev_url": "https://service.cocos.com/serviceConsole/jump?client_id=7&app_id=&language=zh", 535 | "service_type": "2", 536 | "service_type_zh": "仅支持公司游戏", 537 | "support_platform": [ 538 | "安卓", 539 | "iOS", 540 | "H5" 541 | ], 542 | "package_download_url": "https://download.cocos.com/CocosUdc/plugins/service-anysdk/1.0.1_2.2.5.zip", 543 | "package_version_desc": "

    更新日期: 2019/3/7\n更新说明:\n1、修复 Creator 2.0.x 系列版本 2.0.7 以上因调用 cc.game.restart(); 而导致的 AnySDK 调用失败的错误

    ", 544 | "service_component_name": "service-anysdk", 545 | "package_versions": [ 546 | "1.0.1_2.2.5" 547 | ], 548 | "build_platform": [], 549 | "require_verify": 0, 550 | "service_price": "", 551 | "service_protocol": "游戏首次开启该服务时,Cocos会后台通知服务方为游戏开通服务并初始化参数,服务方根据需要可能会获取您的Cocos账户信息,包括账户基本资料、游戏基本资料、账户余额等,点击确认开通按钮即视为您同意该服务访问您的账户信息,详见《Cocos用户服务协议》《Cocos隐私政策》", 552 | "service_group": "", 553 | "service_group_id": "", 554 | "not_service": false 555 | } 556 | ], 557 | "game": { 558 | "name": "未知游戏", 559 | "appid": "UNKNOW" 560 | } 561 | } -------------------------------------------------------------------------------- /template-banner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/0990/avatar-fight-client/28e3b4c326990799866a242ae443702eb69acff3/template-banner.png -------------------------------------------------------------------------------- /template.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "TEMPLATES.helloworld.name", 3 | "desc": "TEMPLATES.helloworld.desc", 4 | "banner": "template-banner.png" 5 | } --------------------------------------------------------------------------------