Commit e885e1ae authored by Tt's avatar Tt

阶段内容上传

parent a6cd520b
...@@ -96,34 +96,31 @@ ...@@ -96,34 +96,31 @@
"__id__": 27 "__id__": 27
}, },
{ {
"__id__": 29 "__id__": 38
},
{
"__id__": 40
}, },
{ {
"__id__": 85 "__id__": 86
}, },
{ {
"__id__": 90 "__id__": 92
}, },
{ {
"__id__": 99 "__id__": 102
}, },
{ {
"__id__": 106 "__id__": 109
} }
], ],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 117 "__id__": 120
}, },
{ {
"__id__": 118 "__id__": 121
}, },
{ {
"__id__": 119 "__id__": 122
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -790,100 +787,6 @@ ...@@ -790,100 +787,6 @@
"preload": false, "preload": false,
"_id": "dey05oKrBIspvsDa6pOIQz" "_id": "dey05oKrBIspvsDa6pOIQz"
}, },
{
"__type__": "cc.Node",
"_name": "1-自动播放语音,点击文字区域可以随点随播",
"_objFlags": 0,
"_parent": {
"__id__": 2
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 16
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 1334,
"height": 750
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "fbM1ww7plFUo6O+6VpqS2t"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 15
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "e1114513-b3e1-4ae1-99f3-edd2b7832231"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "a0RwF4flRLWaTX5/Tw8Vbr"
},
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "2-进入游戏画面,热气球从页面", "_name": "2-进入游戏画面,热气球从页面",
...@@ -892,10 +795,10 @@ ...@@ -892,10 +795,10 @@
"__id__": 2 "__id__": 2
}, },
"_children": [], "_children": [],
"_active": true, "_active": false,
"_components": [ "_components": [
{ {
"__id__": 18 "__id__": 16
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -951,7 +854,7 @@ ...@@ -951,7 +854,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 17 "__id__": 15
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -986,10 +889,10 @@ ...@@ -986,10 +889,10 @@
"__id__": 2 "__id__": 2
}, },
"_children": [], "_children": [],
"_active": true, "_active": false,
"_components": [ "_components": [
{ {
"__id__": 20 "__id__": 18
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1045,7 +948,7 @@ ...@@ -1045,7 +948,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 19 "__id__": 17
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -1080,10 +983,10 @@ ...@@ -1080,10 +983,10 @@
"__id__": 2 "__id__": 2
}, },
"_children": [], "_children": [],
"_active": true, "_active": false,
"_components": [ "_components": [
{ {
"__id__": 22 "__id__": 20
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1139,7 +1042,7 @@ ...@@ -1139,7 +1042,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 21 "__id__": 19
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -1174,10 +1077,10 @@ ...@@ -1174,10 +1077,10 @@
"__id__": 2 "__id__": 2
}, },
"_children": [], "_children": [],
"_active": true, "_active": false,
"_components": [ "_components": [
{ {
"__id__": 24 "__id__": 22
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1233,7 +1136,7 @@ ...@@ -1233,7 +1136,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 23 "__id__": 21
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -1268,10 +1171,10 @@ ...@@ -1268,10 +1171,10 @@
"__id__": 2 "__id__": 2
}, },
"_children": [], "_children": [],
"_active": true, "_active": false,
"_components": [ "_components": [
{ {
"__id__": 26 "__id__": 24
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1327,7 +1230,7 @@ ...@@ -1327,7 +1230,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 25 "__id__": 23
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -1362,10 +1265,10 @@ ...@@ -1362,10 +1265,10 @@
"__id__": 2 "__id__": 2
}, },
"_children": [], "_children": [],
"_active": true, "_active": false,
"_components": [ "_components": [
{ {
"__id__": 28 "__id__": 26
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1421,7 +1324,7 @@ ...@@ -1421,7 +1324,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 27 "__id__": 25
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -1456,6 +1359,9 @@ ...@@ -1456,6 +1359,9 @@
"__id__": 2 "__id__": 2
}, },
"_children": [ "_children": [
{
"__id__": 28
},
{ {
"__id__": 30 "__id__": 30
}, },
...@@ -1467,12 +1373,9 @@ ...@@ -1467,12 +1373,9 @@
}, },
{ {
"__id__": 36 "__id__": 36
},
{
"__id__": 38
} }
], ],
"_active": false, "_active": true,
"_components": [], "_components": [],
"_prefab": null, "_prefab": null,
"_opacity": 255, "_opacity": 255,
...@@ -1527,13 +1430,13 @@ ...@@ -1527,13 +1430,13 @@
"_name": "bg", "_name": "bg",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 29 "__id__": 27
}, },
"_children": [], "_children": [],
"_active": false, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 31 "__id__": 29
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1589,7 +1492,7 @@ ...@@ -1589,7 +1492,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 30 "__id__": 28
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -1621,13 +1524,13 @@ ...@@ -1621,13 +1524,13 @@
"_name": "bg_could", "_name": "bg_could",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 29 "__id__": 27
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 33 "__id__": 31
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1683,7 +1586,7 @@ ...@@ -1683,7 +1586,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 32 "__id__": 30
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -1715,13 +1618,13 @@ ...@@ -1715,13 +1618,13 @@
"_name": "img_cloud1", "_name": "img_cloud1",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 29 "__id__": 27
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 35 "__id__": 33
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1777,7 +1680,7 @@ ...@@ -1777,7 +1680,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 34 "__id__": 32
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -1809,13 +1712,13 @@ ...@@ -1809,13 +1712,13 @@
"_name": "img_cloud2", "_name": "img_cloud2",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 29 "__id__": 27
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 37 "__id__": 35
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1871,7 +1774,7 @@ ...@@ -1871,7 +1774,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 36 "__id__": 34
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -1903,13 +1806,13 @@ ...@@ -1903,13 +1806,13 @@
"_name": "img_cloud3", "_name": "img_cloud3",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 29 "__id__": 27
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 39 "__id__": 37
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1965,7 +1868,7 @@ ...@@ -1965,7 +1868,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 38 "__id__": 36
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -2001,22 +1904,87 @@ ...@@ -2001,22 +1904,87 @@
}, },
"_children": [ "_children": [
{ {
"__id__": 41 "__id__": 39
}, },
{ {
"__id__": 43 "__id__": 48
}, },
{ {
"__id__": 45 "__id__": 50
}, },
{ {
"__id__": 47 "__id__": 75
}
],
"_active": true,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 0,
"height": 0
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "ecAbTd+vFBW4HGWdLsnaFO"
},
{
"__type__": "cc.Node",
"_name": "item_gun",
"_objFlags": 0,
"_parent": {
"__id__": 38
},
"_children": [
{
"__id__": 40
}, },
{ {
"__id__": 49 "__id__": 42
}, },
{ {
"__id__": 74 "__id__": 44
},
{
"__id__": 46
} }
], ],
"_active": true, "_active": true,
...@@ -2067,20 +2035,20 @@ ...@@ -2067,20 +2035,20 @@
"_is3DNode": false, "_is3DNode": false,
"_groupIndex": 0, "_groupIndex": 0,
"groupIndex": 0, "groupIndex": 0,
"_id": "ecAbTd+vFBW4HGWdLsnaFO" "_id": "c4hwCleGhMvajBhohaADy0"
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "弹弓动画1_ske", "_name": "gun1",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 40 "__id__": 39
}, },
"_children": [], "_children": [],
"_active": false, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 42 "__id__": 41
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -2136,7 +2104,7 @@ ...@@ -2136,7 +2104,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 41 "__id__": 40
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -2173,16 +2141,16 @@ ...@@ -2173,16 +2141,16 @@
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "弹弓动画2_ske", "_name": "gun2",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 40 "__id__": 39
}, },
"_children": [], "_children": [],
"_active": false, "_active": false,
"_components": [ "_components": [
{ {
"__id__": 44 "__id__": 43
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -2238,7 +2206,7 @@ ...@@ -2238,7 +2206,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 43 "__id__": 42
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -2275,16 +2243,16 @@ ...@@ -2275,16 +2243,16 @@
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "弹弓动画3_ske", "_name": "gun3",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 40 "__id__": 39
}, },
"_children": [], "_children": [],
"_active": false, "_active": false,
"_components": [ "_components": [
{ {
"__id__": 46 "__id__": 45
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -2333,14 +2301,116 @@ ...@@ -2333,14 +2301,116 @@
"_is3DNode": false, "_is3DNode": false,
"_groupIndex": 0, "_groupIndex": 0,
"groupIndex": 0, "groupIndex": 0,
"_id": "9bwvggVwBGWbT9d/vnDuoC" "_id": "9bwvggVwBGWbT9d/vnDuoC"
},
{
"__type__": "dragonBones.ArmatureDisplay",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 44
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_armatureName": "armatureName",
"_animationName": "newAnimation",
"_preCacheMode": 0,
"_cacheMode": 0,
"playTimes": -1,
"premultipliedAlpha": false,
"_armatureKey": "3962bc16-a24b-40ad-98d1-dd5f7319779d#3409bd50-12ff-4b10-9d92-bab93e9268ca",
"_accTime": 0,
"_playCount": 0,
"_frameCache": null,
"_curFrame": null,
"_playing": false,
"_armatureCache": null,
"_N$dragonAsset": {
"__uuid__": "3962bc16-a24b-40ad-98d1-dd5f7319779d"
},
"_N$dragonAtlasAsset": {
"__uuid__": "3409bd50-12ff-4b10-9d92-bab93e9268ca"
},
"_N$_defaultArmatureIndex": 0,
"_N$_animationIndex": 1,
"_N$_defaultCacheMode": 0,
"_N$timeScale": 1,
"_N$debugBones": false,
"_N$enableBatch": false,
"_id": "efEnChpRlOgZ+vqkjMNIgP"
},
{
"__type__": "cc.Node",
"_name": "gun4",
"_objFlags": 0,
"_parent": {
"__id__": 39
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 47
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 334.6058139534884,
"height": 462
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
-95,
0,
0,
0,
0,
1,
-1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "54bH5A28FB8oPwEI5Ak4Mp"
}, },
{ {
"__type__": "dragonBones.ArmatureDisplay", "__type__": "dragonBones.ArmatureDisplay",
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 45 "__id__": 46
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -2373,20 +2443,20 @@ ...@@ -2373,20 +2443,20 @@
"_N$timeScale": 1, "_N$timeScale": 1,
"_N$debugBones": false, "_N$debugBones": false,
"_N$enableBatch": false, "_N$enableBatch": false,
"_id": "efEnChpRlOgZ+vqkjMNIgP" "_id": "67DSeaZydOk6teZ9DPQdrD"
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "img_card2", "_name": "img_card2",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 40 "__id__": 38
}, },
"_children": [], "_children": [],
"_active": false, "_active": false,
"_components": [ "_components": [
{ {
"__id__": 48 "__id__": 49
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -2442,7 +2512,7 @@ ...@@ -2442,7 +2512,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 47 "__id__": 48
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -2474,11 +2544,11 @@ ...@@ -2474,11 +2544,11 @@
"_name": "layout_balloon", "_name": "layout_balloon",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 40 "__id__": 38
}, },
"_children": [ "_children": [
{ {
"__id__": 50 "__id__": 51
} }
], ],
"_active": false, "_active": false,
...@@ -2536,20 +2606,20 @@ ...@@ -2536,20 +2606,20 @@
"_name": "item", "_name": "item",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 49 "__id__": 50
}, },
"_children": [ "_children": [
{ {
"__id__": 51 "__id__": 52
}, },
{ {
"__id__": 68 "__id__": 69
}, },
{ {
"__id__": 70 "__id__": 71
}, },
{ {
"__id__": 72 "__id__": 73
} }
], ],
"_active": true, "_active": true,
...@@ -2607,32 +2677,32 @@ ...@@ -2607,32 +2677,32 @@
"_name": "res", "_name": "res",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 50 "__id__": 51
}, },
"_children": [ "_children": [
{ {
"__id__": 52 "__id__": 53
}, },
{ {
"__id__": 54 "__id__": 55
}, },
{ {
"__id__": 56 "__id__": 57
}, },
{ {
"__id__": 58 "__id__": 59
}, },
{ {
"__id__": 60 "__id__": 61
}, },
{ {
"__id__": 62 "__id__": 63
}, },
{ {
"__id__": 64 "__id__": 65
}, },
{ {
"__id__": 66 "__id__": 67
} }
], ],
"_active": false, "_active": false,
...@@ -2690,13 +2760,13 @@ ...@@ -2690,13 +2760,13 @@
"_name": "img_balloon1_2", "_name": "img_balloon1_2",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 51 "__id__": 52
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 53 "__id__": 54
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -2752,7 +2822,7 @@ ...@@ -2752,7 +2822,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 52 "__id__": 53
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -2784,13 +2854,13 @@ ...@@ -2784,13 +2854,13 @@
"_name": "img_balloon1_1", "_name": "img_balloon1_1",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 51 "__id__": 52
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 55 "__id__": 56
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -2846,7 +2916,7 @@ ...@@ -2846,7 +2916,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 54 "__id__": 55
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -2878,13 +2948,13 @@ ...@@ -2878,13 +2948,13 @@
"_name": "img_balloon2_2", "_name": "img_balloon2_2",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 51 "__id__": 52
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 57 "__id__": 58
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -2940,7 +3010,7 @@ ...@@ -2940,7 +3010,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 56 "__id__": 57
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -2972,13 +3042,13 @@ ...@@ -2972,13 +3042,13 @@
"_name": "img_balloon3_1", "_name": "img_balloon3_1",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 51 "__id__": 52
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 59 "__id__": 60
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -3034,7 +3104,7 @@ ...@@ -3034,7 +3104,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 58 "__id__": 59
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -3066,13 +3136,13 @@ ...@@ -3066,13 +3136,13 @@
"_name": "img_balloon3_2", "_name": "img_balloon3_2",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 51 "__id__": 52
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 61 "__id__": 62
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -3128,7 +3198,7 @@ ...@@ -3128,7 +3198,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 60 "__id__": 61
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -3160,13 +3230,13 @@ ...@@ -3160,13 +3230,13 @@
"_name": "img_balloon4_2", "_name": "img_balloon4_2",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 51 "__id__": 52
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 63 "__id__": 64
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -3222,7 +3292,7 @@ ...@@ -3222,7 +3292,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 62 "__id__": 63
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -3254,13 +3324,13 @@ ...@@ -3254,13 +3324,13 @@
"_name": "img_balloon2_1", "_name": "img_balloon2_1",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 51 "__id__": 52
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 65 "__id__": 66
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -3316,7 +3386,7 @@ ...@@ -3316,7 +3386,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 64 "__id__": 65
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -3348,13 +3418,13 @@ ...@@ -3348,13 +3418,13 @@
"_name": "img_balloon4_1", "_name": "img_balloon4_1",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 51 "__id__": 52
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 67 "__id__": 68
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -3410,7 +3480,7 @@ ...@@ -3410,7 +3480,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 66 "__id__": 67
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -3442,13 +3512,13 @@ ...@@ -3442,13 +3512,13 @@
"_name": "img_normal", "_name": "img_normal",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 50 "__id__": 51
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 69 "__id__": 70
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -3504,7 +3574,7 @@ ...@@ -3504,7 +3574,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 68 "__id__": 69
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -3536,13 +3606,13 @@ ...@@ -3536,13 +3606,13 @@
"_name": "img_fall", "_name": "img_fall",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 50 "__id__": 51
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 71 "__id__": 72
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -3598,7 +3668,7 @@ ...@@ -3598,7 +3668,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 70 "__id__": 71
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -3630,13 +3700,13 @@ ...@@ -3630,13 +3700,13 @@
"_name": "light", "_name": "light",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 50 "__id__": 51
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 73 "__id__": 74
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -3692,7 +3762,7 @@ ...@@ -3692,7 +3762,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 72 "__id__": 73
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -3724,14 +3794,14 @@ ...@@ -3724,14 +3794,14 @@
"_name": "layout_card", "_name": "layout_card",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 40 "__id__": 38
}, },
"_children": [ "_children": [
{ {
"__id__": 75 "__id__": 76
}, },
{ {
"__id__": 80 "__id__": 81
} }
], ],
"_active": false, "_active": false,
...@@ -3789,14 +3859,14 @@ ...@@ -3789,14 +3859,14 @@
"_name": "layout_txt", "_name": "layout_txt",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 74 "__id__": 75
}, },
"_children": [ "_children": [
{ {
"__id__": 76 "__id__": 77
}, },
{ {
"__id__": 78 "__id__": 79
} }
], ],
"_active": false, "_active": false,
...@@ -3854,13 +3924,13 @@ ...@@ -3854,13 +3924,13 @@
"_name": "bg1", "_name": "bg1",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 75 "__id__": 76
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 77 "__id__": 78
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -3916,7 +3986,7 @@ ...@@ -3916,7 +3986,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 76 "__id__": 77
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -3948,13 +4018,13 @@ ...@@ -3948,13 +4018,13 @@
"_name": "desc", "_name": "desc",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 75 "__id__": 76
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 79 "__id__": 80
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -4010,7 +4080,7 @@ ...@@ -4010,7 +4080,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 78 "__id__": 79
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -4045,14 +4115,14 @@ ...@@ -4045,14 +4115,14 @@
"_name": "layout_img", "_name": "layout_img",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 74 "__id__": 75
}, },
"_children": [ "_children": [
{ {
"__id__": 81 "__id__": 82
}, },
{ {
"__id__": 83 "__id__": 84
} }
], ],
"_active": false, "_active": false,
...@@ -4110,13 +4180,13 @@ ...@@ -4110,13 +4180,13 @@
"_name": "bg2", "_name": "bg2",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 80 "__id__": 81
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 82 "__id__": 83
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -4172,7 +4242,7 @@ ...@@ -4172,7 +4242,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 81 "__id__": 82
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -4204,13 +4274,13 @@ ...@@ -4204,13 +4274,13 @@
"_name": "New Sprite(Splash)", "_name": "New Sprite(Splash)",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 80 "__id__": 81
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 84 "__id__": 85
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -4266,7 +4336,7 @@ ...@@ -4266,7 +4336,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 83 "__id__": 84
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -4302,11 +4372,15 @@ ...@@ -4302,11 +4372,15 @@
}, },
"_children": [ "_children": [
{ {
"__id__": 86 "__id__": 87
}
],
"_active": true,
"_components": [
{
"__id__": 91
} }
], ],
"_active": false,
"_components": [],
"_prefab": null, "_prefab": null,
"_opacity": 255, "_opacity": 255,
"_color": { "_color": {
...@@ -4360,17 +4434,17 @@ ...@@ -4360,17 +4434,17 @@
"_name": "bg_title", "_name": "bg_title",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 85 "__id__": 86
}, },
"_children": [ "_children": [
{ {
"__id__": 87 "__id__": 88
} }
], ],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 89 "__id__": 90
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -4426,13 +4500,13 @@ ...@@ -4426,13 +4500,13 @@
"_name": "title", "_name": "title",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 86 "__id__": 87
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 88 "__id__": 89
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -4488,7 +4562,7 @@ ...@@ -4488,7 +4562,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 87 "__id__": 88
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -4521,7 +4595,7 @@ ...@@ -4521,7 +4595,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 86 "__id__": 87
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -4548,6 +4622,16 @@ ...@@ -4548,6 +4622,16 @@
"_atlas": null, "_atlas": null,
"_id": "48pAdz7GdG36mcICjWyJGN" "_id": "48pAdz7GdG36mcICjWyJGN"
}, },
{
"__type__": "6ea01SYgd1PcYj1tSJPXX7+",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 86
},
"_enabled": true,
"_id": "78N5o1/GhHa5t0r3SoI14W"
},
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "layout_start", "_name": "layout_start",
...@@ -4556,9 +4640,6 @@ ...@@ -4556,9 +4640,6 @@
"__id__": 2 "__id__": 2
}, },
"_children": [ "_children": [
{
"__id__": 91
},
{ {
"__id__": 93 "__id__": 93
}, },
...@@ -4567,9 +4648,12 @@ ...@@ -4567,9 +4648,12 @@
}, },
{ {
"__id__": 97 "__id__": 97
},
{
"__id__": 99
} }
], ],
"_active": false, "_active": true,
"_components": [], "_components": [],
"_prefab": null, "_prefab": null,
"_opacity": 255, "_opacity": 255,
...@@ -4624,13 +4708,13 @@ ...@@ -4624,13 +4708,13 @@
"_name": "New Sprite(Splash)", "_name": "New Sprite(Splash)",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 90 "__id__": 92
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 92 "__id__": 94
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -4686,7 +4770,7 @@ ...@@ -4686,7 +4770,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 91 "__id__": 93
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -4718,13 +4802,13 @@ ...@@ -4718,13 +4802,13 @@
"_name": "bg_instructions", "_name": "bg_instructions",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 90 "__id__": 92
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 94 "__id__": 96
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -4780,7 +4864,7 @@ ...@@ -4780,7 +4864,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 93 "__id__": 95
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -4812,13 +4896,13 @@ ...@@ -4812,13 +4896,13 @@
"_name": "desc", "_name": "desc",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 90 "__id__": 92
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 96 "__id__": 98
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -4874,7 +4958,7 @@ ...@@ -4874,7 +4958,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 95 "__id__": 97
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -4906,16 +4990,19 @@ ...@@ -4906,16 +4990,19 @@
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "btn_start1", "_name": "btn_start",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 90 "__id__": 92
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 98 "__id__": 100
},
{
"__id__": 101
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -4971,7 +5058,7 @@ ...@@ -4971,7 +5058,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 97 "__id__": 99
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -4998,6 +5085,76 @@ ...@@ -4998,6 +5085,76 @@
"_atlas": null, "_atlas": null,
"_id": "acgaVUHrtMQptWu1ShSW+x" "_id": "acgaVUHrtMQptWu1ShSW+x"
}, },
{
"__type__": "cc.Button",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 99
},
"_enabled": true,
"_normalMaterial": null,
"_grayMaterial": null,
"duration": 0.1,
"zoomScale": 1.2,
"clickEvents": [],
"_N$interactable": true,
"_N$enableAutoGrayEffect": false,
"_N$transition": 0,
"transition": 0,
"_N$normalColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_N$pressedColor": {
"__type__": "cc.Color",
"r": 211,
"g": 211,
"b": 211,
"a": 255
},
"pressedColor": {
"__type__": "cc.Color",
"r": 211,
"g": 211,
"b": 211,
"a": 255
},
"_N$hoverColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"hoverColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_N$disabledColor": {
"__type__": "cc.Color",
"r": 124,
"g": 124,
"b": 124,
"a": 255
},
"_N$normalSprite": null,
"_N$pressedSprite": null,
"pressedSprite": null,
"_N$hoverSprite": null,
"hoverSprite": null,
"_N$disabledSprite": null,
"_N$target": {
"__id__": 99
},
"_id": "7095HuemhJQ40wHbz5jlAy"
},
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "layou_speak", "_name": "layou_speak",
...@@ -5007,13 +5164,13 @@ ...@@ -5007,13 +5164,13 @@
}, },
"_children": [ "_children": [
{ {
"__id__": 100 "__id__": 103
}, },
{ {
"__id__": 102 "__id__": 105
}, },
{ {
"__id__": 104 "__id__": 107
} }
], ],
"_active": false, "_active": false,
...@@ -5071,13 +5228,13 @@ ...@@ -5071,13 +5228,13 @@
"_name": "speak_ske", "_name": "speak_ske",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 99 "__id__": 102
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 101 "__id__": 104
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5133,7 +5290,7 @@ ...@@ -5133,7 +5290,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 100 "__id__": 103
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5173,13 +5330,13 @@ ...@@ -5173,13 +5330,13 @@
"_name": "btn_start2", "_name": "btn_start2",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 99 "__id__": 102
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 103 "__id__": 106
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5235,7 +5392,7 @@ ...@@ -5235,7 +5392,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 102 "__id__": 105
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5267,13 +5424,13 @@ ...@@ -5267,13 +5424,13 @@
"_name": "btn_stop", "_name": "btn_stop",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 99 "__id__": 102
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 105 "__id__": 108
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5329,7 +5486,7 @@ ...@@ -5329,7 +5486,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 104 "__id__": 107
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5365,22 +5522,22 @@ ...@@ -5365,22 +5522,22 @@
}, },
"_children": [ "_children": [
{ {
"__id__": 107 "__id__": 110
}, },
{ {
"__id__": 109 "__id__": 112
}, },
{ {
"__id__": 111 "__id__": 114
}, },
{ {
"__id__": 113 "__id__": 116
}, },
{ {
"__id__": 115 "__id__": 118
} }
], ],
"_active": true, "_active": false,
"_components": [], "_components": [],
"_prefab": null, "_prefab": null,
"_opacity": 255, "_opacity": 255,
...@@ -5435,13 +5592,13 @@ ...@@ -5435,13 +5592,13 @@
"_name": "New Sprite(Splash)", "_name": "New Sprite(Splash)",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 106 "__id__": 109
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 108 "__id__": 111
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5497,7 +5654,7 @@ ...@@ -5497,7 +5654,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 107 "__id__": 110
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5529,13 +5686,13 @@ ...@@ -5529,13 +5686,13 @@
"_name": "img_light", "_name": "img_light",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 106 "__id__": 109
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 110 "__id__": 113
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5591,7 +5748,7 @@ ...@@ -5591,7 +5748,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 109 "__id__": 112
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5623,13 +5780,13 @@ ...@@ -5623,13 +5780,13 @@
"_name": "img_co", "_name": "img_co",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 106 "__id__": 109
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 112 "__id__": 115
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5685,7 +5842,7 @@ ...@@ -5685,7 +5842,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 111 "__id__": 114
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5717,13 +5874,13 @@ ...@@ -5717,13 +5874,13 @@
"_name": "img_gj", "_name": "img_gj",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 106 "__id__": 109
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 114 "__id__": 117
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5779,7 +5936,7 @@ ...@@ -5779,7 +5936,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 113 "__id__": 116
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5811,13 +5968,13 @@ ...@@ -5811,13 +5968,13 @@
"_name": "img_ta", "_name": "img_ta",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 106 "__id__": 109
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 116 "__id__": 119
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5873,7 +6030,7 @@ ...@@ -5873,7 +6030,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 115 "__id__": 118
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
......
import { asyncDelay, onHomeworkFinish } from "../script/util"; import { asyncDelay, onHomeworkFinish } from "../script/util";
import { MyCocosSceneComponent } from "../script/MyCocosSceneComponent"; import { MyCocosSceneComponent } from "../script/MyCocosSceneComponent";
import Game, { GAME_STATE } from "./tool/Game";
import pg from "./tool/pg";
const { ccclass, property } = cc._decorator; const { ccclass, property } = cc._decorator;
...@@ -25,161 +27,72 @@ export default class SceneComponent extends MyCocosSceneComponent { ...@@ -25,161 +27,72 @@ export default class SceneComponent extends MyCocosSceneComponent {
// TODO 加载完成后的逻辑写在这里, 下面的代码仅供参考 // TODO 加载完成后的逻辑写在这里, 下面的代码仅供参考
this.initData(); this.initData();
this.initView(); this.initView();
this.initListener(); this.initEvent();
}
protected onDestroy(): void {
pg.event.clear();
} }
_cantouch = null; _cantouch = null;
initData() { initData() {
Game.getIns().init(this.data);
Game.getIns().reset();
// 所有全局变量 默认都是null // 所有全局变量 默认都是null
this._cantouch = true; this._cantouch = true;
} }
private layout_start: cc.Node;
initView() { private audioId: any;
// this.initBg(); async initView() {
// this.initPic(); this.layout_start = pg.view.find(this, "layout_start");
// this.initBtn();
// this.initIcon(); this.layout_start.active = true;
} this.audioId = await pg.audio.playAudioByUrl(Game.getIns().question.audio);
if (this.audioId > -1 && Game.getIns().state == GAME_STATE.RUNNING) {
initBg() { cc.audioEngine.stopAllEffects();
const bgNode = cc.find('Canvas/bg'); // pg.audio.stopAudio(this.audioId);
bgNode.scale = this._mapScaleMax; }
}
pic1 = null;
pic2 = null;
initPic() {
const canvas = cc.find('Canvas');
const maxW = canvas.width * 0.7;
this.getSprNodeByUrl(this.data.pic_url, (sprNode) => {
const picNode1 = sprNode;
picNode1.scale = maxW / picNode1.width;
picNode1.baseX = picNode1.x;
canvas.addChild(picNode1);
this.pic1 = picNode1;
const labelNode = new cc.Node();
labelNode.color = cc.Color.YELLOW;
const label = labelNode.addComponent(cc.Label);
label.string = this.data.text;
label.fontSize = 60;
label.lineHeight = 60;
label.font = cc.find('Canvas/res/font/BRLNSDB').getComponent('cc.Label').font;
picNode1.addChild(labelNode);
});
this.getSprNodeByUrl(this.data.pic_url_2, (sprNode) => {
const picNode2 = sprNode;
picNode2.scale = maxW / picNode2.width;
canvas.addChild(picNode2);
picNode2.x = canvas.width;
picNode2.baseX = picNode2.x;
this.pic2 = picNode2;
const labelNode = new cc.Node();
const label = labelNode.addComponent(cc.RichText);
const size = 60
label.font = cc.find('Canvas/res/font/BRLNSDB').getComponent(cc.Label).font;
label.string = `<outline color=#751e00 width=4><size=${size}><color=#ffffff>${this.data.text}</color></size></outline>`
label.lineHeight = size;
picNode2.addChild(labelNode);
});
} }
initEvent() {
pg.view.touchOn(pg.view.find(this.layout_start, 'btn_start'), this.onTouchStart, this);
initIcon() { pg.event.on("game_start", () => {
const iconNode = this.getSprNode('icon'); this.gameStart();
iconNode.zIndex = 5;
iconNode.anchorX = 1;
iconNode.anchorY = 1;
iconNode.parent = cc.find('Canvas');
iconNode.x = iconNode.parent.width / 2 - 10;
iconNode.y = iconNode.parent.height / 2 - 10;
iconNode.on(cc.Node.EventType.TOUCH_START, () => {
this.playAudioByUrl(this.data.audio_url);
})
}
curPage = null;
initBtn() {
this.curPage = 0;
const bottomPart = cc.find('Canvas/bottomPart');
bottomPart.zIndex = 5; // 提高层级
bottomPart.x = bottomPart.parent.width / 2;
bottomPart.y = -bottomPart.parent.height / 2;
const leftBtnNode = bottomPart.getChildByName('btn_left');
//节点中添加了button组件 则可以添加click事件监听
leftBtnNode.on('click', () => {
if (!this._cantouch) {
return;
}
if (this.curPage == 0) {
return;
}
this.curPage = 0
this.leftMove();
this.playLocalAudio('btn');
}) })
pg.event.on("game_time_over", () => {
const rightBtnNode = bottomPart.getChildByName('btn_right'); // alert("game_time_over")
//节点中添加了button组件 则可以添加click事件监听 //这里的事件会发送的很早。但是我们需要等待动画执行完了之后再开始后续的内容
rightBtnNode.on('click', () => { Game.getIns().addPage();
if (!this._cantouch) { if (!Game.getIns().isOver) return pg.event.emit("game_start");
return; //发送给上端最后的数据
// alert("game_finish")
let player = { right: Game.getIns().player.score, error: Game.getIns().player.error }
let robot = { right: Game.getIns().robot.score, error: Game.getIns().robot.error }
if (Game.getIns().singleGame) {
onHomeworkFinish({ player })
} else {
onHomeworkFinish({ player, robot })
} }
if (this.curPage == 1) {
return;
}
this.curPage = 1
this.rightMove();
// 游戏结束时需要调用这个方法通知系统作业完成
onHomeworkFinish();
this.playLocalAudio('btn');
}) })
} }
onTouchStart() {
leftMove() { pg.audio.playLocalAudio(cc.find(`Canvas/res/audio/btn`));
this._cantouch = false; pg.event.emit("game_start");
const len = this.pic1.parent.width;
cc.tween(this.pic1)
.to(1, { x: this.pic1.baseX }, { easing: 'cubicInOut' })
.start();
cc.tween(this.pic2)
.to(1, { x: this.pic2.baseX }, { easing: 'cubicInOut' })
.call(() => {
this._cantouch = true;
})
.start();
} }
rightMove() { gameStart() {
this._cantouch = false; Game.getIns().state = GAME_STATE.RUNNING;
const len = this.pic1.parent.width; //游戏开始小鱼出现等等
cc.tween(this.pic1) this.layout_start.active = false;
.to(1, { x: this.pic1.baseX - len }, { easing: 'cubicInOut' }) if (this.audioId > -1 && Game.getIns().state != GAME_STATE.WAIT) {
.start(); cc.audioEngine.stopAllEffects();
// pg.audio.stopAudio(this.audioId);
cc.tween(this.pic2) }
.to(1, { x: this.pic2.baseX - len }, { easing: 'cubicInOut' })
.call(() => {
this._cantouch = true;
})
.start();
}
// update (dt) {},
//开始
initListener() { //根据数据随机热气球
//
} }
...@@ -187,9 +100,9 @@ export default class SceneComponent extends MyCocosSceneComponent { ...@@ -187,9 +100,9 @@ export default class SceneComponent extends MyCocosSceneComponent {
const audio = cc.find(`Canvas/res/audio/${audioName}`).getComponent(cc.AudioSource); const audio = cc.find(`Canvas/res/audio/${audioName}`).getComponent(cc.AudioSource);
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
const id = cc.audioEngine.playEffect(audio.clip, false); const id = cc.audioEngine.playEffect(audio.clip, false);
cc.audioEngine.setFinishCallback(id, () => { cc.audioEngine.setFinishCallback(id, () => { resolve(id); });
resolve(id);
});
}) })
} }
} }
{
"ver": "1.1.2",
"uuid": "24028cb8-b33b-4dac-bcd7-abfdd9c91d5c",
"isBundle": false,
"bundleName": "",
"priority": 1,
"compressionType": {},
"optimizeHotUpdate": {},
"inlineSpriteFrames": {},
"isRemoteBundle": {},
"subMetas": {}
}
\ No newline at end of file
// Learn TypeScript:
// - https://docs.cocos.com/creator/manual/en/scripting/typescript.html
// Learn Attribute:
// - https://docs.cocos.com/creator/manual/en/scripting/reference/attributes.html
// Learn life-cycle callbacks:
// - https://docs.cocos.com/creator/manual/en/scripting/life-cycle-callbacks.html
import Game, { FISH_OUT, GAME_STATE, Option } from "../tool/Game";
import pg from "../tool/pg";
const { ccclass, property } = cc._decorator;
export function getDegree(p1, p2) {
let vector = p2.sub(p1);
let degree = Math.atan(vector.y / vector.x) / Math.PI * 180;
if (vector.x >= 0) {
if (vector.y < 0) {
degree += 360;
}
} else {
if (vector.y > 0) {
degree += 180;
} else {
degree = 180 + degree;
}
}
return -(-degree + 90);//角度计算方法
}
@ccclass
export default class NewClass extends cc.Component {
@property(cc.Node)
res: cc.Node = null;
@property(cc.Node)
layout_player: cc.Node = null;
@property(cc.Node)
layout_robot: cc.Node = null;
@property(cc.Node)
item_left: cc.Node = null;
@property(cc.Node)
item_right: cc.Node = null;
onLoad() {
pg.event.on("game_start", () => {
this.gameStart();
})
}
private count: number;
private list: Option[];
private fishs: cc.Node[];
gameStart() {
//游戏开始。允许出鱼
let page = Game.getIns().getCurrentPage();
let list = page.optionList.concat();
list = JSON.parse(JSON.stringify(list));
list.sort((A, B) => { return Math.random() < 0.5 });
this.list = list;
this.count = 0;
this.lastCount = null;
this.robotFishTime = null;
this.fishs = [];
this.viewFishs = [];
this.touchFishs = [];
//根据顺序生成对应的鱼。
//顺序根据时间来进行跳动。当顺序跳动之后,就会产生新的鱼。
}
private lastCount: number;
private viewFishs: Option[];
private touchFishs: Option[];
getFishByCount(count) {
if (count <= this.lastCount) return null;
if (!this.list) return;
if (this.list.length == this.touchFishs.length) {
Game.getIns().state = GAME_STATE.OVER;
return pg.event.emit("game_time_over");
}
this.lastCount = count;
let list = this.list.filter((li) => {
return this.viewFishs.every(v => v.id != li.id) && this.touchFishs.every(t => t.id != li.id);
});
if (list.length == 0) return null;
let data = JSON.parse(JSON.stringify(list[count % list.length]));
data.fish.isLeft = Math.random() < 0.5;
let item_base = data.fish.isLeft ? this.item_left : this.item_right;
let item = cc.instantiate(item_base);
this.updateFish(item, data);
this.viewFishs.push(data);
return item;
}
private fishCount: number;
private lastY: number;
updateFish(item, data: Option) {
pg.view.touchOn(item, this.onTouchItem, this);
if (!this.fishCount) this.fishCount = 0;
let id = this.fishCount % 5 + 1;
this.fishCount++;
pg.view.visible(pg.view.find(item, 'fish/icon_fish1'), id == 1);
pg.view.visible(pg.view.find(item, 'fish/icon_fish2'), id == 2);
pg.view.visible(pg.view.find(item, 'fish/icon_fish3'), id == 3);
pg.view.visible(pg.view.find(item, 'fish/icon_fish4'), id == 4);
pg.view.visible(pg.view.find(item, 'fish/icon_fish5'), id == 5);
item.parent = this.node;
item.data = data;
data.fish.node = item;
//渲染部分
if (data.type == "txt") {
pg.view.visible(pg.view.find(item, 'layout_text'), true);
pg.view.visible(pg.view.find(item, 'layout_img'), false);
pg.view.setString(pg.view.find(item, "layout_text/text"), data.txt);
} else {
pg.view.visible(pg.view.find(item, 'layout_text'), false);
pg.view.visible(pg.view.find(item, 'layout_img'), true);
pg.view.setNetImg(pg.view.find(item, 'layout_img/img'), data.picUrl, { w: 118, h: 110 })
}
//x y 起始点 和终点 进行 随机
cc.Tween.stopAllByTarget(item);
if (data.fish.isLeft) {
//左往右
item.x = -(1334 / 2 + Math.random() * 200)
item.y = -290 + Math.random() * 400;//
cc.tween(item).to(10 + Math.random() * 10, { x: 1500 }).call(() => {
data.fish.isOut = FISH_OUT.OUT;
this.viewFishs = this.viewFishs.filter(v => v.id != data.id);
}).start();
} else {
//右往左
item.x = (1334 / 2) + Math.random() * 200;
item.y = -290 + Math.random() * 400;
cc.tween(item).to(10 + Math.random() * 10, { x: -1500 }).call(() => {
data.fish.isOut = FISH_OUT.OUT;
this.viewFishs = this.viewFishs.filter(v => v.id != data.id);
}).start();
}
}
private touching: boolean;
fishingRight(item, layout, data: Option) {
return new Promise((resolve, reject) => {
let wave = pg.view.find(layout, 'wave')
wave.active = true;
wave.angle = getDegree(cc.v2(item), cc.v2(layout).add(cc.v2(wave)));
let text = pg.view.find(layout, "text");
text.active = true;
data.audioUrl && pg.audio.playAudioByUrl(data.audioUrl)
cc.tween(item)
.to(1, { x: layout.x, y: layout.y + wave.y, scaleX: item.scaleX * 0.1, scaleY: item.scaleY * 0.1 }).call(() => {
//处理内容
data.fish.isOut = FISH_OUT.OUT;
wave.active = false;
text.active = false;
this.touching = false;
resolve('');
}).start();
});
}
fishingError(item, layout, data) {
return new Promise((resolve, reject) => {
pg.audio.playLocalAudio(pg.view.find(this.res, "audio/error"))
if (data.fish.isLeft) {
//左往右
cc.tween(item).to(3, { x: 1500 }).call(() => {
data.fish.isOut = FISH_OUT.OUT;
item.active = false;
setTimeout(() => { item.parent = null; }, 1000);
if (this.touchFishs.every(fish => fish.id != data.id)) {
resolve('');
}
}).start();
} else {
//右往左
cc.tween(item).to(3, { x: -1500 }).call(() => {
data.fish.isOut = FISH_OUT.OUT;
item.active = false;
setTimeout(() => { item.parent = null; }, 1000);
if (this.touchFishs.every(fish => fish.id != data.id)) {
resolve('');
}
}).start();
}
setTimeout(() => { this.touching = false; }, 500);
});
}
fishing(item, layout) {
return new Promise(async (resolve, reject) => {
let data = item.data;
//item停止动画并
cc.Tween.stopAllByTarget(item);
if (data.right) {
await this.fishingRight(item, layout, data);
} else {
await this.fishingError(item, layout, data);
}
this.touchFishs.push(data);
return resolve(data.right);
});
}
//开始点击 点击角色
async onTouchItem(e) {
if (this.touching) return;
this.touching = true;
let item = e.target;
let data = item.data;
if (this.touchFishs.some(fish => fish.id == data.id)) return;
if (data.fish.isOut != FISH_OUT.RUNNING) return;
data.fish.isOut = FISH_OUT.TOUCH;
let isRight = await this.fishing(item, this.layout_player);
isRight && Game.getIns().player.addScore();
!isRight && Game.getIns().player.addError();
}
//机器人随机钓鱼
private robotFishTime;
async onRobotFishing() {
this.layout_robot.active = !Game.getIns().singleGame;
if (!this.viewFishs) return;
if (Game.getIns().singleGame) return;
let nowTime = new Date().getTime();
if (!this.robotFishTime) this.robotFishTime = nowTime;
let time = 5000;//level来确定触发捕鱼的间隔时间。
if (nowTime - this.robotFishTime > time) {
let datas = this.viewFishs.filter(dat => dat.fish.node.x > -1334 / 2 && dat.fish.node.x < 1334 / 2);
let data = datas[Math.floor(Math.random() * datas.length)];
if (data.fish.isOut != FISH_OUT.RUNNING) return;
if (this.touchFishs.some(fish => fish.id == data.id)) return;
this.robotFishTime = nowTime - 1000;//-1000 动画时间
if (!data.right) return;
data.fish.isOut = FISH_OUT.TOUCH;
let isRight = await this.fishing(data.fish.node, this.layout_robot);
isRight && Game.getIns().robot.addScore();
!isRight && Game.getIns().player.addError();
}
}
get fishLen() {
if (!this.fishs) return 999;
let arr = this.fishs.filter(item => {
let data: Option = item.data;
return data.fish.isOut == FISH_OUT.RUNNING;
})
this.fishs = arr;
return this.fishs.length;
}
update(dt) {
if (Game.getIns().state != GAME_STATE.RUNNING) return;
if (this.fishLen < 5) this.count++;
this.onRobotFishing();
let fish = this.getFishByCount(this.count);
if (fish) this.fishs.push(fish);
}
}
{
"ver": "1.0.8",
"uuid": "7e5697f7-3598-4d41-ab4f-66aa53ffca4c",
"isPlugin": false,
"loadPluginInWeb": true,
"loadPluginInNative": true,
"loadPluginInEditor": false,
"subMetas": {}
}
\ No newline at end of file
// Learn TypeScript:
// - https://docs.cocos.com/creator/manual/en/scripting/typescript.html
// Learn Attribute:
// - https://docs.cocos.com/creator/manual/en/scripting/reference/attributes.html
// Learn life-cycle callbacks:
// - https://docs.cocos.com/creator/manual/en/scripting/life-cycle-callbacks.html
import Game, { GAME_STATE } from "../tool/Game";
import pg from "../tool/pg";
pg.event.clear();
const { ccclass, property } = cc._decorator;
@ccclass
export default class NewClass extends cc.Component {
// private btn_laba: cc.Node;
// private countDown: number = 999;
onLoad() {
this.initView();
this.initEvent();
}
private initEvent() {
pg.event.on("game_start", () => {
this.gameStart();
});
// pg.event.on("game_set_game_time", (count) => {
// this.countDown = count;
// });
// this.btn_laba.on(cc.Node.EventType.TOUCH_END, this.playLaba, this);
}
private gameStart() {
// this.countDown = Game.getIns().getCurrentPage().duration;
// this.playLaba();
}
private initView() {
// this.btn_laba = cc.find("btn_laba", this.node);
}
// private intervalId;
// private playLaba() {
// let btn_kaba2 = this.btn_laba.getChildByName("btn_laba2");
// let btn_kaba3 = this.btn_laba.getChildByName("btn_laba3");
// btn_kaba2.active = true;
// btn_kaba3.active = true;
// let count = 0;
// if (this.intervalId) clearInterval(this.intervalId);
// let stop = false;
// this.intervalId = setInterval(() => {
// count++;
// btn_kaba2.active = count % 3 == 1;
// btn_kaba3.active = count % 3 == 2;
// if (stop && count % 3 == 2) clearInterval(this.intervalId);
// }, 150)
// pg.audio.playAudioByUrl(Game.getIns().getCurrentPage().audio).then(() => { stop = true; })
// }
// private lastCount: number;
update(dt) {
if (Game.getIns().title) {
cc.find("bg_title/title", this.node).getComponent(cc.Label).string = Game.getIns().title;
}
// if (Game.getIns().state == GAME_STATE.OVER) return;
// if (Game.getIns().state == GAME_STATE.WAIT) return;
// if (this.countDown <= 0) {
// Game.getIns().state = GAME_STATE.OVER;
// pg.event.emit("game_time_over");
// return;
// }
// this.countDown = this.countDown - dt;
// if (this.countDown < 6) {
// let count = Math.floor(this.countDown);
// if (count != this.lastCount) {
// this.lastCount = count;
// if (this.lastCount == 1) {
// pg.audio.playLocalAudio(cc.find("bg_cd_red/audio_cd1", this.node))
// } else if (this.lastCount > 1) {
// pg.audio.playLocalAudio(cc.find("bg_cd_red/audio_cd", this.node))
// }
// }
// cc.find("bg_cd_red", this.node).active = true;
// cc.find("bg_cd_red/label_cd", this.node).getComponent(cc.Label).string = "" + parseInt("" + this.countDown);
// } else {
// cc.find("bg_cd_red", this.node).active = false;
// cc.find("bg_cd/label_cd", this.node).getComponent(cc.Label).string = "" + parseInt("" + this.countDown);
// }
}
}
\ No newline at end of file
{
"ver": "1.0.8",
"uuid": "6ea01498-81dd-4f71-88f5-b5224f5d7efe",
"isPlugin": false,
"loadPluginInWeb": true,
"loadPluginInNative": true,
"loadPluginInEditor": false,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "1.1.2",
"uuid": "6ac65a4c-4ac8-49e0-b66f-50e34324889c",
"isBundle": false,
"bundleName": "",
"priority": 1,
"compressionType": {},
"optimizeHotUpdate": {},
"inlineSpriteFrames": {},
"isRemoteBundle": {},
"subMetas": {}
}
\ No newline at end of file
export enum FISH_OUT {
RUNNING,
TOUCH,
CATCH,
ESCAP,
OUT
}
export class Fish {
public isOut: number;
public node: cc.Node;
public isLeft: boolean;//在左侧 向右运动
constructor() {
this.isOut = 0;
this.isLeft = Math.random() < 0.5;
}
}
export class Option {
public type;
public txt;
public picUrl;
public audioUrl;
public right: boolean;
public data;
public id: number;
public count: number;
public fish: Fish;
constructor(data, id) {
this.id = id;
this.data = data;
this.type = data.type;
this.txt = data.text;
this.picUrl = data.image;
this.audioUrl = data.audio;
this.right = data.right;
this.fish = new Fish();
}
}
export class Item {
public page;
public audio;
public duration;
public optionList;
constructor(data, page) {
this.audio = data.questionAudio;
this.duration = data.duration;
let id = 0;
this.optionList = data.options.map(o => {
return new Option(o, id++);
})
this.optionList.sort(function () {
return (0.5 - Math.random());
});
for (let i = 0; i < this.optionList.length; i++) {
this.optionList[i].count = i;
}
this.page = page;
}
}
class Role {
public score: number;
public error: number;
constructor() {
this.score = 0;
this.error = 0;
}
addScore(score: number = 1) {
this.score += score;
}
addError(score: number = 1) {
this.error += score;
}
}
export class Player extends Role {
constructor() {
super();
}
reset() {
}
}
export class Robot extends Role {
constructor() {
super();
}
reset() {
}
}
export enum GAME_STATE {
WAIT,
RUNNING,
OVER
}
export default class Game {
private static ins: Game;
public static getIns(): Game {
if (!Game.ins) Game.ins = new Game();
return Game.ins;
}
private data: any;
private lists: Array<Item>
public player: Player;
public robot: Robot;
public state: GAME_STATE;
constructor() {
this.start = false;
this.lists = [];
this.player = new Player();
this.robot = new Robot();
this.state = GAME_STATE.WAIT;
}
get len() {
return this.lists.length;
}
public singleGame: boolean;
public question: { text, audio };
public title: string;
public init(data) {
this.singleGame = !data.onlineFlg;
this.question = { text: data.questionText, audio: data.questionTextAudio };
this.title = data.title;
this.start = false;
this.lists = [];
this.data = data.questions;
}
public start: boolean;
public page: number;
reset() {
this.player.reset();
this.robot.reset();
this.page = 1;
this.start = true;
this.lists = [];
for (let i = 0; i < this.data.length; i++) {
let data = this.data[i];
this.lists.push(new Item(data, i + 1));
}
}
checkSuccess(arr: Option[]) {
let data = this.getCurrentPage();
let options = data.optionList.concat();
options.sort((A, B) => A.id - B.id)
for (let i = 0; i < options.length; i++) {
if (arr[i] && arr[i].id != options[i].id) {
return false;
}
}
return true;
}
getDataByPage(page): Item {
return this.lists.filter(li => li.page == page)[0]
}
getCurrentPage(): Item {
let page = this.page;
return this.lists.filter(li => li.page == page)[0]
}
getTotalPageNum() {
return this.lists.length;
}
getCurrentPageNum() {
return this.page;
}
addPage() {
this.page += 1;
}
get isOver() {
return this.page > this.lists.length;
}
}
\ No newline at end of file
{
"ver": "1.0.8",
"uuid": "5baeb71d-8316-4aad-ac1b-ed83e8dcbcc1",
"isPlugin": false,
"loadPluginInWeb": true,
"loadPluginInNative": true,
"loadPluginInEditor": false,
"subMetas": {}
}
\ No newline at end of file
class Emitter {
static instance;
static getInstance() {
if (!Emitter.instance) {
Emitter.instance = new Emitter();
}
return Emitter.instance;
}
_name: any;
_callbacks: any;
constructor(name = "") {
this._name = name;
this._callbacks = {};
return this;
}
clear() {
this._callbacks = {};
}
on(event, fn) {
if (!this._callbacks[event]) this._callbacks[event] = [];
this._callbacks[event].push(fn);
};
once(event, fn) {
function on() {
this.off(event, on);
fn.apply(this, arguments);
}
on.fn = fn;
this.on(event, on);
};
off(event, fn) {
// all
if (0 == arguments.length) {
this._callbacks = {};
return;
}
// specific event
let callbacks = this._callbacks[event];
if (!callbacks) return;
// remove all handlers
if (1 == arguments.length) {
delete this._callbacks[event];
return;
}
// remove specific handler
let cb;
for (let i = 0; i < callbacks.length; i++) {
cb = callbacks[i];
if (cb === fn || cb.fn === fn) {
callbacks.splice(i, 1);
break;
}
}
return;
}
emit(event, ...args) {
this._callbacks = this._callbacks || {};
// let args = [].slice.call(arguments, 1);
let callbacks = this._callbacks[event];
if (callbacks) {
callbacks = callbacks.slice(0);
for (let i = 0, len = callbacks.length; i < len; ++i) {
callbacks[i].apply(this, args);
}
}
}
listeners(event) {
this._callbacks = this._callbacks || {};
return this._callbacks[event] || [];
};
hasListeners(event) {
return !!this.listeners(event).length;
};
}
class TimeCtrl {
private current: number;
constructor() {
this.current = 0;
}
fillTime(time) {
this.current += (time * 1000)
return this;
}
setTime(time) {
this.current += (time * 1000)
return this;
}
wait() {
return new Promise((resolve, reject) => {
let lastTime = new Date().getTime();
let id = setInterval(() => {
let nowTime = new Date().getTime();
this.current -= (nowTime - lastTime);
lastTime = nowTime;
if (this.current <= 0) {
clearInterval(id);
resolve(true);
}
}, 1)
});
}
reset() {
this.current = 0;
return this;
}
}
let pg = {
logger: {
d: function (str) {
cc.log(str);
return null;
},
i: function (str) {
cc.log(str);
return null;
},
w: function (str) {
cc.warn(str);
return null;
}
},
view: {
//---------------------节点管理------------------------------
//创建节点
createNode() {
let node = new cc.Node();
return node;
},
//添加节点
addChild(item, child, zIndex) {
if (!child) return console.log("addChild error ->请传入子节点");
if (!item) return console.log("addChild error ->请传入父节点");
let node = item.node ? item.node : item;
if (!node) return console.log("addChild error ->请传入父节点");
if (child.parent)
return pg.logger.w("此节点已经有父节点->" + child.name);
if (zIndex >= 0) {
node.addChild(child, zIndex)
} else {
node.addChild(child);
}
return true;
},
//删除子节点
removeChild(item, child) {
if (!item) return pg.logger.w("节点remove失败,传入了错误的item");
let node = item.node ? item.node : item;
if (child.parent && child.parent == node) {
node.removeChild(child);
child.destroy();
}
return true;
},
removeSelf(item) {
if (!item) return pg.logger.w("节点移除失败,传入了错误的item");
let node = item.node ? item.node : item;
node.removeFromParent();
node.destroy();
},
//删除所有子节点
removChildren(item) {
if (!item) return pg.logger.w("节点remove失败,传入了错误的item");
let node = item.node ? item.node : item;
if (!node.parent) return pg.logger.w("节点remove失败,传入了错误的item");
node.removeAllChildren();
return true;
},
//查找节点
find(item, childPath): cc.Node {
if (typeof item == "string") {
childPath = item;
item = null;
}
if (!childPath || childPath == '' || typeof childPath != 'string') return pg.logger.w("findChildByPath error->" + "请传入路径");
let child = null;
if (item) {
let node = item.node ? item.node : item;
if (!node.children || node.children.length == 0) return pg.logger.w("findChild error->" + "找不到此节点,请检查层级路径:" + childPath);
child = cc.find(childPath, node);
} else {
child = cc.find(childPath);
}
if (!child) return pg.logger.w("findChildByPath error->" + "找不到此节点,请检查层级路径:" + childPath);
return child;
},
//--------------------触控事件--------------------------------
//添加监听
touchOn(item, callback, target) {
if (!item) return pg.logger.w("添加按钮响应失败,传入了错误的item");
if (!callback || !target) return pg.logger.w("添加按钮响应失败,传入了空回调");
let node = item.node ? item.node : item;
node.on(cc.Node.EventType.TOUCH_END, callback, target);
return true;
},
//移除监听
touchOff(item, callback, target) {
if (!item) return pg.logger.w("移除按钮响应失败,传入了错误的item");
if (!callback || !target) return pg.logger.w("移除按钮响应失败,传入了空回调");
let node = item.node ? item.node : item;
if (!node || !node.parent) return pg.logger.w("节点已移除");
node.off(cc.Node.EventType.TOUCH_END, callback, target);
return true;
},
//是否允许点击
touchEnable(item, isEnable) {
if (!item) return pg.logger.w("设置按钮响应失败,传入了错误的item");
let node = item.node ? item.node : item;
if (!node) return pg.logger.w("设置按钮响应失败,传入了错误的item");
let btn = node.getComponent(cc.Button);
if (!btn) return pg.logger.w("当前节点没有添加button->" + node.name);
btn.interactable = isEnable;
return true;
},
//-------------------渲染相关---------------------------------
//显示隐藏
visible(item, isVisible) {
if (!item) return pg.logger.w("节点显示失败,传入了错误的item");
let node = item.node ? item.node : item;
if (!node || !node.parent) return pg.logger.w("节点已移除");
node.active = isVisible;
return true;
},
//更换图片
setImg(item, res) {
return new Promise((resolve, reject) => {
if (!item) return pg.logger.w("图片更换失败,传入了错误的item");
if (!res) return pg.logger.w("图片更换失败,传入了错误的res");
pg.load.loadImg(res).then((spriteFrame: cc.SpriteFrame) => {
if (!cc.isValid(item)) return pg.logger.i("节点已销毁");
let node = item.node ? item.node : item;
if (!cc.isValid(node)) return pg.logger.i("节点已销毁");
let component = node.getComponent(cc.Sprite);
let { width, height } = spriteFrame.getRect();
component.spriteFrame = spriteFrame;
resolve({ width, height });
})
})
},
setNetImg(item, res, { w, h }) {
return new Promise((resolve, reject) => {
if (!item) return pg.logger.w("图片更换失败,传入了错误的item");
let node = item.node ? item.node : item;
if (!res) {
if (node) node.active = false;
return pg.logger.w("图片更换失败,传入了错误的res");
}
if (!node) return pg.logger.w("图片更换失败,传入了错误的item");
if (node.net_url == res) return;
node.active = false;//
pg.load.loadNetImg(res).then((texture: cc.Texture2D) => {
if (!cc.isValid(node)) return pg.logger.i("节点已销毁");
let nw = node.width = texture.width;
let nh = node.height = texture.height;
let component = node.getComponent(cc.Sprite);
let spriteFrame = new cc.SpriteFrame(texture);
component.spriteFrame = spriteFrame;
node.net_url = res;
if (!cc.isValid(node)) return pg.logger.i("节点已销毁");
if (!node) return pg.logger.w("节点已销毁");
if (w && h) {
let scaleX = w / nw;
let scaleY = h / nh;
let scale = scaleX <= scaleY ? scaleX : scaleY;
node.width = nw * scale;
node.height = nh * scale;
}
node.active = true;
resolve({ w: nw, h: nh });
})
})
},
switchMaterial(item, id0 = 0, id1 = 1) {
let material0 = item.getMaterial(id0);
let material1 = item.getMaterial(id1);
item.setMaterial(id0, material1);
item.setMaterial(id1, material0);
},
//更改文字
setString(item, text, count = 0) {
if (!item) return pg.logger.w("节点text失败,传入了错误的item");
if (count > 0) {
let parse_str = function (str, count) {
if (!str) return "";
var segmants = str.split('+');
str = segmants.join('');
var len = 0;
var idx = 0;
for (var i = 0; i < str.length; i++) {
var p = /[^x00-xff]/g;
var a = str.charAt(i);
if (p.test(a)) {
len += 2;
idx++;
}
else {
len += 1;
idx++;
}
if (len >= count * 2)
break;
}
return str.substr(0, idx);
}
text = parse_str(text, count);
}
let node = item.node ? item.node : item;
if (!node) return;
let component = node.getComponent(cc.Label);//组件功能 非node的功能
component.string = text;
return true;
},
//更变颜色
setColor(item, color, outlineWidth = -1) {
if (!item) return pg.logger.w("setColor warn->传入了错误的item");
let RGB = this.colorRgb(color);
if (!RGB || RGB.length == 0) return pg.logger.w("color ->传入了错误的color");
item.color = new cc.Color(RGB[0], RGB[1], RGB[2]);
if (outlineWidth < 0) return;
let LabelOutline = item.getComponent(cc.LabelOutline);
if (!LabelOutline) return pg.logger.w("LabelOutline warn->未添加描边");
LabelOutline.width = outlineWidth;
},
colorRgb(color) {
var reg = /^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/;
var sColor = color;
if (sColor && reg.test(sColor)) {
if (sColor.length === 4) {
var sColorNew = "#";
for (var i = 1; i < 4; i += 1) {
sColorNew += sColor.slice(i, i + 1).concat(sColor.slice(i, i + 1));
}
sColor = sColorNew;
}
//处理六位的颜色值
var sColorChange = [];
for (var i = 1; i < 7; i += 2) {
sColorChange.push(parseInt("0x" + sColor.slice(i, i + 2)));
}
return sColorChange;
} else {
return sColor;
}
},
//-------------------动画播放--------------------------------
playSpineAnimation(item, aniName, loop) {
if (!item || !cc.isValid(item)) return pg.logger.w("动画播放失败,传入了错误的item");
if (!aniName) return pg.logger.w("动画播放失败,传入了错误的aniName");
let node = item.node ? item.node : item;
if (!cc.isValid(node)) return pg.logger.w("节点已销毁");
let skl = node.getComponent(sp.Skeleton);
skl.setAnimation(0, aniName, loop);
return skl;
},
playDBAnimation(item, aniName, loop = -1) {
if (!item || !cc.isValid(item)) return pg.logger.w("动画播放失败,传入了错误的item");
if (!aniName) return pg.logger.w("动画播放失败,传入了错误的aniName");
let node = item.node ? item.node : item;
if (!cc.isValid(node)) return pg.logger.w("节点已销毁");
let skl: dragonBones.ArmatureDisplay = node.getComponent(dragonBones.ArmatureDisplay);
skl.playAnimation(aniName, loop);
return skl;
},
clone(node: cc.Node) {
return cc.instantiate(node)
}
},
load: {
//资源加载
// loadBundle: function (bundleName) {
// return new Promise((resolve, reject) => {
// // let hallBundle = cc.assetManager.getBundle(`hall`);
// // hallBundle.releaseAll();
// // cc.assetManager.removeBundle(hallBundle);
// let bundle = cc.assetManager.getBundle(bundleName);
// if (bundle) return resolve('');
// cc.assetManager.loadBundle(bundleName, (err, bundle) => {
// if (err) return cc.error(err);
// resolve(bundle);
// });
// });
// },
loadRes: function (res, type, bundleName) {
//此处需要二次封装,新的存在assetbundle
return new Promise((resolve, reject) => {
cc.loader.loadRes(res, type, (err, data) => {
if (err && !data) return resolve(pg.logger.d('loading loadRes error-> ' + res));
resolve(data);
});
})
},
loadImg: function (url) {
return new Promise((resolve, reject) => {
this.loadRes(url, cc.SpriteFrame).then((data) => {
if (!data || data.length == 0) return;
resolve(data);
})
})
},
loadPrefab: function (path = "") {
return new Promise((resolve, reject) => {
let url = "/prefabs/" + path;
this.loadRes(url, cc.Prefab).then((data) => {
if (!data || data.length == 0) return reject();
return resolve(cc.instantiate(data));
})
})
},
loadNetImg: function (url) {
return new Promise((resolve, reject) => {
cc.loader.load({ url }, (err, texture) => {
if (err && !texture) return resolve(pg.logger.w('loading loadRes warn-> ' + texture));
resolve(texture);
});
})
},
loadDB(item, config) {
return new Promise((resolve, reject) => {
if (!config.png || !config.ske || !config.tex) {
return resolve('');
}
pg.load.loadNetRes(config.png).then((png: any) => {
pg.load.loadNetRes(config.ske).then((ske: any) => {
pg.load.loadNetRes(config.tex).then((tex: any) => {
var atlas = new dragonBones.DragonBonesAtlasAsset();
atlas.atlasJson = JSON.stringify(tex.json);
atlas.texture = png;
var asset = new dragonBones.DragonBonesAsset();
asset.dragonBonesJson = JSON.stringify(ske.json);
let dragonDisplay = item.getComponent(dragonBones.ArmatureDisplay);
dragonDisplay.dragonAtlasAsset = atlas;
dragonDisplay.dragonAsset = asset;
//设置
let defaultArmature = ske.json.armature[0];//aramture 所有的骨骼名称
dragonDisplay.armatureName = defaultArmature.name;
resolve(defaultArmature.animation[0].name);
})
})
})
});
},
loadNetRes: function (url) {
return new Promise((resolve, reject) => {
cc.assetManager.loadRemote(url, (err, info) => {
if (err) return resolve(pg.logger.w('loading loadRes warn-> ' + err));
resolve(info);
});
})
},
},
localStorage: {
//本地存储
setItem: function (key, val) {
cc.sys.localStorage.setItem(key, val);
},
getItem: function (key, defVal) {
return cc.sys.localStorage.getItem(key) || defVal;
}
},
http: {
//http访问
send: function (type, url, data, callback) {
return new Promise((resolve) => {
return setTimeout(() => {
return resolve({ status: 200 });
}, 100 + Math.random() * 300);
let xhr = cc.loader.getXMLHttpRequest();
xhr.timeout = 5000;
xhr.responseType = "text";
xhr.open(type, url, true);
xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
xhr.onreadystatechange = () => {
if (xhr.readyState !== 4) return;
if (xhr.status >= 200 && xhr.status < 300) {
try {
let resp = xhr.responseText;
pg.logger.d("resp->" + JSON.stringify(resp));
callback(resp);
resolve(resp);
} catch (e) {
}
}
else {
}
};
xhr.onerror = (e) => {
pg.logger.w("onerror->" + url);
};
xhr.ontimeout = (e) => {
pg.logger.w("ontimeout->" + url);
};
xhr.send(data);
})
}
},
audio: {
playAudioByUrl(audio_url) {
return new Promise((resolve, reject) => {
if (!audio_url) return resolve(null);
cc.assetManager.loadRemote(audio_url, (err, audioClip: any) => {
const audioId = cc.audioEngine.play(audioClip, false, 0.8);
cc.audioEngine.setFinishCallback(audioId, () => {
});
resolve(audioId);
});
});
},
stopAudio(audioId) {
if (!audioId) return;
cc.audioEngine.stopEffect(audioId);
},
playAudio(audioClip, cb = null) {
if (audioClip) {
const audioId = cc.audioEngine.playEffect(audioClip, false);
if (cb) {
cc.audioEngine.setFinishCallback(audioId, () => {
cb();
});
}
return audioId;
}
},
playLocalAudio(audio: cc.Node) {
return new Promise((resolve, reject) => {
const id = cc.audioEngine.playEffect(audio.getComponent(cc.AudioSource).clip, false);
cc.audioEngine.setFinishCallback(id, () => {
resolve(id);
});
})
}
},
time: {
delay(time) {
return new Promise((resolve, reject) => {
setTimeout(() => {
resolve('');
}, time * 1000);
});
},
delayCtrl(): TimeCtrl {
return new TimeCtrl();
}
},
hw: {
playLocalAudio(audioName, loop = false) {
console.log("play audio->" + audioName);
const audio = cc.find(`Canvas/res/audio/${audioName}`).getComponent(cc.AudioSource);
return new Promise((resolve, reject) => {
const id = cc.audioEngine.playEffect(audio.clip, loop);
resolve(id);
})
}
},
event: Emitter.getInstance()
};
export default pg;
\ No newline at end of file
{
"ver": "1.0.8",
"uuid": "f0076f6e-185d-42fd-b61b-698a3efa67ca",
"isPlugin": false,
"loadPluginInWeb": true,
"loadPluginInNative": true,
"loadPluginInEditor": false,
"subMetas": {}
}
\ No newline at end of file
export const defaultData = { export const defaultData = {
"pic_url": "http://staging-teach.cdn.ireadabc.com/ed94332a503c31e0908bd4c6923a2665.png", onlineFlg: false, // 联机flg true联机版 false单机版
"pic_url_2": "http://staging-teach.cdn.ireadabc.com/5fb60317ade0195d35ad8034d5370a7f.png", title: "标题文本", // 标题文本
"text": "This is a test label.", questionText: "题目说明题目说明题目说明题目说明题目说明题目说明题目说明题目说明题目说明题目说明", // 题目说明
"audio_url": "http://staging-teach.cdn.ireadabc.com/f47f1d7b5c160fe1c59500d180346240.mp3" questionTextAudio: "http://staging-teach.cdn.ireadabc.com/b1019dcdb1f089ba9a65b71a1f52f67a.mp3", // 题目说明的语音
questions: [ // 题目,数组
{
questionAudio: "http://staging-teach.cdn.ireadabc.com/727a5af2f7ed99edb4a49d1126ecc9ca.mp3", // 题目音频
duration: 120, // 游戏倒计时(秒)
options: [ // 选项
{
type: "img",// 选项类型 img图片 txt文本
image: "http://staging-teach.cdn.ireadabc.com/03531e7ca2278b291da7d27bc1d60868.png", // 图片地址
audio: "http://staging-teach.cdn.ireadabc.com/727a5af2f7ed99edb4a49d1126ecc9ca.mp3", // 选项音频
text: "", // 选项类型为图片时,此选项没啥用
right: true // 这个选项是否是正确的
},
{
type: "text",// 选项类型 img图片 txt文本
image: "", // 选项类型为文本时,此选项没啥用
text: "asasdf", // 选项文本
audio: "http://staging-teach.cdn.ireadabc.com/727a5af2f7ed99edb4a49d1126ecc9ca.mp3",
right: true
},
{
image: "http://staging-teach.cdn.ireadabc.com/35bfd1d1342e1f2ea3db408afd072343.jpg",
audio: "",
type: "img",
text: "",
right: false
},
{
image: "",
audio: "",
type: "text",
text: "oliolioliooo",
right: false
}
]
},
{
questionAudio: "http://staging-teach.cdn.ireadabc.com/727a5af2f7ed99edb4a49d1126ecc9ca.mp3",
duration: 120, // 游戏倒计时(秒)
options: [
{
image: "http://staging-teach.cdn.ireadabc.com/03531e7ca2278b291da7d27bc1d60868.png",
audio: "http://staging-teach.cdn.ireadabc.com/727a5af2f7ed99edb4a49d1126ecc9ca.mp3",
type: "img",
text: "",
right: true
},
{
image: "",
audio: "http://staging-teach.cdn.ireadabc.com/727a5af2f7ed99edb4a49d1126ecc9ca.mp3",
type: "text",
text: "olio",
right: true
},
{
image: "http://staging-teach.cdn.ireadabc.com/35bfd1d1342e1f2ea3db408afd072343.jpg",
audio: "",
type: "img",
text: "",
right: false
},
{
image: "",
audio: "",
type: "text",
text: "oliolioliooo",
right: false
}
]
}
]
} }
\ No newline at end of file
...@@ -411,12 +411,13 @@ export function showTrebleFirework(baseNode, rabbonList) { ...@@ -411,12 +411,13 @@ export function showTrebleFirework(baseNode, rabbonList) {
showFireworks(right); showFireworks(right);
} }
export function onHomeworkFinish() {
export function onHomeworkFinish(data) {
const middleLayer = cc.find('middleLayer'); const middleLayer = cc.find('middleLayer');
if (middleLayer) { if (middleLayer) {
const middleLayerComponent = middleLayer.getComponent('middleLayer'); const middleLayerComponent = middleLayer.getComponent('middleLayer');
if (middleLayerComponent.role == 'student') { if (middleLayerComponent.role == 'student') {
middleLayerComponent.onHomeworkFinish(() => { }); middleLayerComponent.onHomeworkFinish(() => { }, data);
} }
} else { } else {
console.log('onHomeworkFinish'); console.log('onHomeworkFinish');
......
...@@ -4588,6 +4588,7 @@ declare namespace cc { ...@@ -4588,6 +4588,7 @@ declare namespace cc {
/** !#en Returns a normalized vector representing the forward direction (Z axis) of the node in world space. /** !#en Returns a normalized vector representing the forward direction (Z axis) of the node in world space.
!#zh 获取节点正前方(z 轴)面对的方向,返回值为世界坐标系下的归一化向量 */ !#zh 获取节点正前方(z 轴)面对的方向,返回值为世界坐标系下的归一化向量 */
forward: Vec3; forward: Vec3;
data: Option;
/** /**
@param name name @param name name
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment