Commit 8ab7dab4 authored by Tt's avatar Tt

基础流程待处理录音

parent 6179dbfa
......@@ -17,7 +17,7 @@
"__id__": 2
},
{
"__id__": 170
"__id__": 172
}
],
"_active": false,
......@@ -84,37 +84,37 @@
"__id__": 15
},
{
"__id__": 65
},
{
"__id__": 100
"__id__": 67
},
{
"__id__": 107
"__id__": 102
},
{
"__id__": 120
"__id__": 109
},
{
"__id__": 125
"__id__": 122
},
{
"__id__": 127
},
{
"__id__": 129
},
{
"__id__": 131
}
],
"_active": true,
"_components": [
{
"__id__": 167
"__id__": 169
},
{
"__id__": 168
"__id__": 170
},
{
"__id__": 169
"__id__": 171
}
],
"_prefab": null,
......@@ -759,19 +759,19 @@
"__id__": 42
},
{
"__id__": 46
"__id__": 48
},
{
"__id__": 50
"__id__": 52
},
{
"__id__": 57
"__id__": 59
}
],
"_active": true,
"_components": [
{
"__id__": 64
"__id__": 66
}
],
"_prefab": null,
......@@ -1121,7 +1121,7 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width": 790,
"width": 1020,
"height": 60
},
"_anchorPoint": {
......@@ -1187,7 +1187,7 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width": 690,
"width": 920,
"height": 126
},
"_anchorPoint": {
......@@ -1200,7 +1200,7 @@
"ctor": "Float64Array",
"array": [
0,
-2.915,
-12.303,
0,
0,
0,
......@@ -1368,7 +1368,7 @@
"_dstBlendFactor": 771,
"_string": "题目:请参照图片移动下方按钮,组成完整的一句话",
"_N$string": "题目:请参照图片移动下方按钮,组成完整的一句话",
"_fontSize": 30,
"_fontSize": 40,
"_lineHeight": 100,
"_enableWrapText": true,
"_N$file": {
......@@ -1396,7 +1396,7 @@
"_enabled": true,
"_layoutSize": {
"__type__": "cc.Size",
"width": 790,
"width": 1020,
"height": 60
},
"_resize": 1,
......@@ -1517,7 +1517,7 @@
"ctor": "Float64Array",
"array": [
0,
-30,
0,
0,
0,
0,
......@@ -1590,8 +1590,8 @@
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
-444.371,
-30.062,
-400,
-1073.576,
0,
0,
0,
......@@ -1717,7 +1717,7 @@
"__id__": 31
},
"_children": [],
"_active": false,
"_active": true,
"_components": [
{
"__id__": 35
......@@ -1812,7 +1812,7 @@
"__id__": 31
},
"_children": [],
"_active": false,
"_active": true,
"_components": [
{
"__id__": 37
......@@ -1906,7 +1906,7 @@
"__id__": 31
},
"_children": [],
"_active": false,
"_active": true,
"_components": [
{
"__id__": 39
......@@ -1917,8 +1917,8 @@
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 0,
"b": 0,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
......@@ -2000,7 +2000,7 @@
"__id__": 31
},
"_children": [],
"_active": false,
"_active": true,
"_components": [
{
"__id__": 41
......@@ -2103,6 +2103,9 @@
"_components": [
{
"__id__": 45
},
{
"__id__": 46
}
],
"_prefab": null,
......@@ -2269,6 +2272,88 @@
"_N$inverted": false,
"_id": "a9b+/Oq1pI9ZGxp0wPxysO"
},
{
"__type__": "cc.Button",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 42
},
"_enabled": true,
"_normalMaterial": null,
"_grayMaterial": null,
"duration": 0.1,
"zoomScale": 1.2,
"clickEvents": [
{
"__id__": 47
}
],
"_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": null,
"_id": "7b5tzzW3BPKbFdZgbQeW8/"
},
{
"__type__": "cc.ClickEvent",
"target": {
"__id__": 2
},
"component": "",
"_componentId": "408a6f4ZfpM8Yzyg+IOGg/V",
"handler": "onTouchStart",
"customEventData": ""
},
{
"__type__": "cc.Node",
"_name": "item_little",
......@@ -2278,13 +2363,13 @@
},
"_children": [
{
"__id__": 47
"__id__": 49
}
],
"_active": false,
"_components": [
{
"__id__": 49
"__id__": 51
}
],
"_prefab": null,
......@@ -2340,13 +2425,13 @@
"_name": "img",
"_objFlags": 0,
"_parent": {
"__id__": 46
"__id__": 48
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 48
"__id__": 50
}
],
"_prefab": null,
......@@ -2402,7 +2487,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 47
"__id__": 49
},
"_enabled": true,
"_materials": [
......@@ -2434,7 +2519,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 46
"__id__": 48
},
"_enabled": true,
"_materials": [
......@@ -2470,19 +2555,19 @@
},
"_children": [
{
"__id__": 51
"__id__": 53
},
{
"__id__": 53
"__id__": 55
}
],
"_active": false,
"_components": [
{
"__id__": 55
"__id__": 57
},
{
"__id__": 56
"__id__": 58
}
],
"_prefab": null,
......@@ -2538,13 +2623,13 @@
"_name": "img_0",
"_objFlags": 0,
"_parent": {
"__id__": 50
"__id__": 52
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 52
"__id__": 54
}
],
"_prefab": null,
......@@ -2600,7 +2685,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 51
"__id__": 53
},
"_enabled": true,
"_materials": [
......@@ -2632,13 +2717,13 @@
"_name": "img_1",
"_objFlags": 0,
"_parent": {
"__id__": 50
"__id__": 52
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 54
"__id__": 56
}
],
"_prefab": null,
......@@ -2694,7 +2779,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 53
"__id__": 55
},
"_enabled": true,
"_materials": [
......@@ -2726,7 +2811,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 50
"__id__": 52
},
"_enabled": true,
"_normalMaterial": null,
......@@ -2794,7 +2879,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 50
"__id__": 52
},
"_enabled": true,
"alignMode": 1,
......@@ -2825,19 +2910,19 @@
},
"_children": [
{
"__id__": 58
"__id__": 60
},
{
"__id__": 60
"__id__": 62
}
],
"_active": false,
"_components": [
{
"__id__": 62
"__id__": 64
},
{
"__id__": 63
"__id__": 65
}
],
"_prefab": null,
......@@ -2893,13 +2978,13 @@
"_name": "img_0",
"_objFlags": 0,
"_parent": {
"__id__": 57
"__id__": 59
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 59
"__id__": 61
}
],
"_prefab": null,
......@@ -2955,7 +3040,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 58
"__id__": 60
},
"_enabled": true,
"_materials": [
......@@ -2987,13 +3072,13 @@
"_name": "img_1",
"_objFlags": 0,
"_parent": {
"__id__": 57
"__id__": 59
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 61
"__id__": 63
}
],
"_prefab": null,
......@@ -3049,7 +3134,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 60
"__id__": 62
},
"_enabled": true,
"_materials": [
......@@ -3081,7 +3166,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 57
"__id__": 59
},
"_enabled": true,
"_normalMaterial": null,
......@@ -3149,7 +3234,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 57
"__id__": 59
},
"_enabled": true,
"alignMode": 1,
......@@ -3207,25 +3292,25 @@
},
"_children": [
{
"__id__": 66
"__id__": 68
},
{
"__id__": 70
"__id__": 72
},
{
"__id__": 73
"__id__": 75
},
{
"__id__": 84
"__id__": 86
}
],
"_active": false,
"_components": [
{
"__id__": 98
"__id__": 100
},
{
"__id__": 99
"__id__": 101
}
],
"_prefab": null,
......@@ -3281,19 +3366,19 @@
"_name": "bg",
"_objFlags": 0,
"_parent": {
"__id__": 65
"__id__": 67
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 67
"__id__": 69
},
{
"__id__": 68
"__id__": 70
},
{
"__id__": 69
"__id__": 71
}
],
"_prefab": null,
......@@ -3349,7 +3434,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 66
"__id__": 68
},
"_enabled": true,
"_materials": [
......@@ -3381,7 +3466,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 66
"__id__": 68
},
"_enabled": true,
"alignMode": 1,
......@@ -3408,7 +3493,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 66
"__id__": 68
},
"_enabled": true,
"_id": "97pflT+i1AyY1PE58Dq3+A"
......@@ -3418,16 +3503,16 @@
"_name": "btn_close",
"_objFlags": 0,
"_parent": {
"__id__": 65
"__id__": 67
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 71
"__id__": 73
},
{
"__id__": 72
"__id__": 74
}
],
"_prefab": null,
......@@ -3483,7 +3568,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 70
"__id__": 72
},
"_enabled": true,
"_materials": [
......@@ -3515,7 +3600,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 70
"__id__": 72
},
"_enabled": true,
"alignMode": 1,
......@@ -3542,12 +3627,9 @@
"_name": "card",
"_objFlags": 0,
"_parent": {
"__id__": 65
"__id__": 67
},
"_children": [
{
"__id__": 74
},
{
"__id__": 76
},
......@@ -3559,6 +3641,9 @@
},
{
"__id__": 82
},
{
"__id__": 84
}
],
"_active": true,
......@@ -3616,13 +3701,13 @@
"_name": "bg",
"_objFlags": 0,
"_parent": {
"__id__": 73
"__id__": 75
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 75
"__id__": 77
}
],
"_prefab": null,
......@@ -3678,7 +3763,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 74
"__id__": 76
},
"_enabled": true,
"_materials": [
......@@ -3710,13 +3795,13 @@
"_name": "text",
"_objFlags": 0,
"_parent": {
"__id__": 73
"__id__": 75
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 77
"__id__": 79
}
],
"_prefab": null,
......@@ -3772,7 +3857,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 76
"__id__": 78
},
"_enabled": true,
"_materials": [
......@@ -3805,13 +3890,13 @@
"_name": "image",
"_objFlags": 0,
"_parent": {
"__id__": 73
"__id__": 75
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 79
"__id__": 81
}
],
"_prefab": null,
......@@ -3867,7 +3952,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 78
"__id__": 80
},
"_enabled": true,
"_materials": [
......@@ -3899,13 +3984,13 @@
"_name": "image_text_image",
"_objFlags": 0,
"_parent": {
"__id__": 73
"__id__": 75
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 81
"__id__": 83
}
],
"_prefab": null,
......@@ -3961,7 +4046,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 80
"__id__": 82
},
"_enabled": true,
"_materials": [
......@@ -3993,13 +4078,13 @@
"_name": "image_text_text",
"_objFlags": 0,
"_parent": {
"__id__": 73
"__id__": 75
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 83
"__id__": 85
}
],
"_prefab": null,
......@@ -4055,7 +4140,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 82
"__id__": 84
},
"_enabled": true,
"_materials": [
......@@ -4088,14 +4173,14 @@
"_name": "btn_voice",
"_objFlags": 0,
"_parent": {
"__id__": 65
"__id__": 67
},
"_children": [
{
"__id__": 85
"__id__": 87
},
{
"__id__": 87
"__id__": 89
}
],
"_active": true,
......@@ -4153,13 +4238,13 @@
"_name": "normal",
"_objFlags": 0,
"_parent": {
"__id__": 84
"__id__": 86
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 86
"__id__": 88
}
],
"_prefab": null,
......@@ -4215,7 +4300,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 85
"__id__": 87
},
"_enabled": true,
"_materials": [
......@@ -4247,14 +4332,14 @@
"_name": "ing",
"_objFlags": 0,
"_parent": {
"__id__": 84
"__id__": 86
},
"_children": [
{
"__id__": 88
"__id__": 90
},
{
"__id__": 96
"__id__": 98
}
],
"_active": true,
......@@ -4312,23 +4397,23 @@
"_name": "bg",
"_objFlags": 0,
"_parent": {
"__id__": 87
},
"_children": [
{
"__id__": 89
},
"_children": [
{
"__id__": 91
},
{
"__id__": 93
},
{
"__id__": 95
}
],
"_active": true,
"_components": [
{
"__id__": 95
"__id__": 97
}
],
"_prefab": null,
......@@ -4384,13 +4469,13 @@
"_name": "fanka_img_circle1",
"_objFlags": 0,
"_parent": {
"__id__": 88
"__id__": 90
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 90
"__id__": 92
}
],
"_prefab": null,
......@@ -4446,7 +4531,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 89
"__id__": 91
},
"_enabled": true,
"_materials": [
......@@ -4478,13 +4563,13 @@
"_name": "fanka_img_circle2",
"_objFlags": 0,
"_parent": {
"__id__": 88
"__id__": 90
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 92
"__id__": 94
}
],
"_prefab": null,
......@@ -4540,7 +4625,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 91
"__id__": 93
},
"_enabled": true,
"_materials": [
......@@ -4572,13 +4657,13 @@
"_name": "fanka_img_circle3",
"_objFlags": 0,
"_parent": {
"__id__": 88
"__id__": 90
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 94
"__id__": 96
}
],
"_prefab": null,
......@@ -4634,7 +4719,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 93
"__id__": 95
},
"_enabled": true,
"_materials": [
......@@ -4666,18 +4751,18 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 88
"__id__": 90
},
"_enabled": true,
"imgList": [
{
"__id__": 89
},
{
"__id__": 91
},
{
"__id__": 93
},
{
"__id__": 95
}
],
"_id": "7eC6d9sttNuZu2bSqk1QTx"
......@@ -4687,13 +4772,13 @@
"_name": "ing",
"_objFlags": 0,
"_parent": {
"__id__": 87
"__id__": 89
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 97
"__id__": 99
}
],
"_prefab": null,
......@@ -4749,7 +4834,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 96
"__id__": 98
},
"_enabled": true,
"_materials": [
......@@ -4781,7 +4866,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 65
"__id__": 67
},
"_enabled": false,
"_materials": [
......@@ -4813,7 +4898,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 65
"__id__": 67
},
"_enabled": true,
"alignMode": 1,
......@@ -4843,14 +4928,14 @@
"__id__": 2
},
"_children": [
{
"__id__": 101
},
{
"__id__": 103
},
{
"__id__": 105
},
{
"__id__": 107
}
],
"_active": true,
......@@ -4908,13 +4993,13 @@
"_name": "JJ_Excellent_ske",
"_objFlags": 0,
"_parent": {
"__id__": 100
"__id__": 102
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 102
"__id__": 104
}
],
"_prefab": null,
......@@ -4970,7 +5055,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 101
"__id__": 103
},
"_enabled": true,
"_materials": [
......@@ -5010,13 +5095,13 @@
"_name": "JJ_Good_ske",
"_objFlags": 0,
"_parent": {
"__id__": 100
"__id__": 102
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 104
"__id__": 106
}
],
"_prefab": null,
......@@ -5072,7 +5157,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 103
"__id__": 105
},
"_enabled": true,
"_materials": [
......@@ -5112,13 +5197,13 @@
"_name": "JJ_Tryagain_ske",
"_objFlags": 0,
"_parent": {
"__id__": 100
"__id__": 102
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 106
"__id__": 108
}
],
"_prefab": null,
......@@ -5174,7 +5259,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 105
"__id__": 107
},
"_enabled": true,
"_materials": [
......@@ -5217,9 +5302,6 @@
"__id__": 2
},
"_children": [
{
"__id__": 108
},
{
"__id__": 110
},
......@@ -5234,6 +5316,9 @@
},
{
"__id__": 118
},
{
"__id__": 120
}
],
"_active": false,
......@@ -5291,13 +5376,13 @@
"_name": "point_orange_normal",
"_objFlags": 0,
"_parent": {
"__id__": 107
"__id__": 109
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 109
"__id__": 111
}
],
"_prefab": null,
......@@ -5353,7 +5438,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 108
"__id__": 110
},
"_enabled": true,
"_materials": [
......@@ -5385,13 +5470,13 @@
"_name": "point_orange_right",
"_objFlags": 0,
"_parent": {
"__id__": 107
"__id__": 109
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 111
"__id__": 113
}
],
"_prefab": null,
......@@ -5447,7 +5532,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 110
"__id__": 112
},
"_enabled": true,
"_materials": [
......@@ -5479,13 +5564,13 @@
"_name": "point_orange_select_normal",
"_objFlags": 0,
"_parent": {
"__id__": 107
"__id__": 109
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 113
"__id__": 115
}
],
"_prefab": null,
......@@ -5541,7 +5626,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 112
"__id__": 114
},
"_enabled": true,
"_materials": [
......@@ -5573,13 +5658,13 @@
"_name": "point_orange_select_right",
"_objFlags": 0,
"_parent": {
"__id__": 107
"__id__": 109
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 115
"__id__": 117
}
],
"_prefab": null,
......@@ -5635,7 +5720,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 114
"__id__": 116
},
"_enabled": true,
"_materials": [
......@@ -5667,13 +5752,13 @@
"_name": "point_orange_wrong",
"_objFlags": 0,
"_parent": {
"__id__": 107
"__id__": 109
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 117
"__id__": 119
}
],
"_prefab": null,
......@@ -5729,7 +5814,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 116
"__id__": 118
},
"_enabled": true,
"_materials": [
......@@ -5761,13 +5846,13 @@
"_name": "point_orange_select_wrong",
"_objFlags": 0,
"_parent": {
"__id__": 107
"__id__": 109
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 119
"__id__": 121
}
],
"_prefab": null,
......@@ -5823,7 +5908,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 118
"__id__": 120
},
"_enabled": true,
"_materials": [
......@@ -5859,16 +5944,16 @@
},
"_children": [
{
"__id__": 121
"__id__": 123
}
],
"_active": false,
"_components": [
{
"__id__": 123
"__id__": 125
},
{
"__id__": 124
"__id__": 126
}
],
"_prefab": null,
......@@ -5924,13 +6009,13 @@
"_name": "New Label",
"_objFlags": 0,
"_parent": {
"__id__": 120
"__id__": 122
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 122
"__id__": 124
}
],
"_prefab": null,
......@@ -5986,7 +6071,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 121
"__id__": 123
},
"_enabled": true,
"_materials": [
......@@ -6019,7 +6104,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 120
"__id__": 122
},
"_enabled": true,
"_materials": [
......@@ -6051,7 +6136,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 120
"__id__": 122
},
"_enabled": true,
"_layoutSize": {
......@@ -6089,7 +6174,7 @@
"_active": false,
"_components": [
{
"__id__": 126
"__id__": 128
}
],
"_prefab": null,
......@@ -6145,7 +6230,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 125
"__id__": 127
},
"_enabled": true,
"_materials": [
......@@ -6183,7 +6268,7 @@
"_active": false,
"_components": [
{
"__id__": 128
"__id__": 130
}
],
"_prefab": null,
......@@ -6239,7 +6324,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 127
"__id__": 129
},
"_enabled": true,
"_materials": [
......@@ -6275,13 +6360,13 @@
},
"_children": [
{
"__id__": 130
"__id__": 132
},
{
"__id__": 133
"__id__": 135
},
{
"__id__": 136
"__id__": 138
}
],
"_active": false,
......@@ -6339,11 +6424,11 @@
"_name": "font",
"_objFlags": 0,
"_parent": {
"__id__": 129
"__id__": 131
},
"_children": [
{
"__id__": 131
"__id__": 133
}
],
"_active": true,
......@@ -6401,13 +6486,13 @@
"_name": "BRLNSDB",
"_objFlags": 0,
"_parent": {
"__id__": 130
"__id__": 132
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 132
"__id__": 134
}
],
"_prefab": null,
......@@ -6463,7 +6548,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 131
"__id__": 133
},
"_enabled": true,
"_materials": [],
......@@ -6494,11 +6579,11 @@
"_name": "img",
"_objFlags": 0,
"_parent": {
"__id__": 129
"__id__": 131
},
"_children": [
{
"__id__": 134
"__id__": 136
}
],
"_active": true,
......@@ -6556,13 +6641,13 @@
"_name": "icon",
"_objFlags": 0,
"_parent": {
"__id__": 133
"__id__": 135
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 135
"__id__": 137
}
],
"_prefab": null,
......@@ -6618,7 +6703,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 134
"__id__": 136
},
"_enabled": true,
"_materials": [],
......@@ -6646,12 +6731,9 @@
"_name": "audio",
"_objFlags": 0,
"_parent": {
"__id__": 129
"__id__": 131
},
"_children": [
{
"__id__": 137
},
{
"__id__": 139
},
......@@ -6693,6 +6775,9 @@
},
{
"__id__": 165
},
{
"__id__": 167
}
],
"_active": true,
......@@ -6750,13 +6835,13 @@
"_name": "btn",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 138
"__id__": 140
}
],
"_prefab": null,
......@@ -6812,7 +6897,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 137
"__id__": 139
},
"_enabled": true,
"_clip": {
......@@ -6831,13 +6916,13 @@
"_name": "tip",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 140
"__id__": 142
}
],
"_prefab": null,
......@@ -6893,7 +6978,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 139
"__id__": 141
},
"_enabled": true,
"_clip": {
......@@ -6912,13 +6997,13 @@
"_name": "tosmall",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 142
"__id__": 144
}
],
"_prefab": null,
......@@ -6974,7 +7059,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 141
"__id__": 143
},
"_enabled": true,
"_clip": {
......@@ -6993,13 +7078,13 @@
"_name": "pagenext",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 144
"__id__": 146
}
],
"_prefab": null,
......@@ -7055,7 +7140,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 143
"__id__": 145
},
"_enabled": true,
"_clip": {
......@@ -7074,13 +7159,13 @@
"_name": "arrow",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 146
"__id__": 148
}
],
"_prefab": null,
......@@ -7136,7 +7221,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 145
"__id__": 147
},
"_enabled": true,
"_clip": {
......@@ -7155,13 +7240,13 @@
"_name": "right",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 148
"__id__": 150
}
],
"_prefab": null,
......@@ -7217,7 +7302,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 147
"__id__": 149
},
"_enabled": true,
"_clip": {
......@@ -7236,13 +7321,13 @@
"_name": "touch_voice",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 150
"__id__": 152
}
],
"_prefab": null,
......@@ -7298,7 +7383,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 149
"__id__": 151
},
"_enabled": true,
"_clip": {
......@@ -7317,13 +7402,13 @@
"_name": "end",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 152
"__id__": 154
}
],
"_prefab": null,
......@@ -7379,7 +7464,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 151
"__id__": 153
},
"_enabled": true,
"_clip": {
......@@ -7398,13 +7483,13 @@
"_name": "fanka",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 154
"__id__": 156
}
],
"_prefab": null,
......@@ -7460,7 +7545,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 153
"__id__": 155
},
"_enabled": true,
"_clip": {
......@@ -7479,13 +7564,13 @@
"_name": "try",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 156
"__id__": 158
}
],
"_prefab": null,
......@@ -7541,7 +7626,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 155
"__id__": 157
},
"_enabled": true,
"_clip": {
......@@ -7560,13 +7645,13 @@
"_name": "wait",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 158
"__id__": 160
}
],
"_prefab": null,
......@@ -7622,7 +7707,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 157
"__id__": 159
},
"_enabled": true,
"_clip": {
......@@ -7641,13 +7726,13 @@
"_name": "excellent",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 160
"__id__": 162
}
],
"_prefab": null,
......@@ -7703,7 +7788,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 159
"__id__": 161
},
"_enabled": true,
"_clip": {
......@@ -7722,13 +7807,13 @@
"_name": "good",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 162
"__id__": 164
}
],
"_prefab": null,
......@@ -7784,7 +7869,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 161
"__id__": 163
},
"_enabled": true,
"_clip": {
......@@ -7803,13 +7888,13 @@
"_name": "record_wrong",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 164
"__id__": 166
}
],
"_prefab": null,
......@@ -7865,7 +7950,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 163
"__id__": 165
},
"_enabled": true,
"_clip": {
......@@ -7884,13 +7969,13 @@
"_name": "record_right",
"_objFlags": 0,
"_parent": {
"__id__": 136
"__id__": 138
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 166
"__id__": 168
}
],
"_prefab": null,
......@@ -7946,7 +8031,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 165
"__id__": 167
},
"_enabled": true,
"_clip": {
......@@ -8022,7 +8107,7 @@
"__id__": 29
},
"layer_item_little": {
"__id__": 46
"__id__": 48
},
"label_title": {
"__id__": 23
......@@ -8031,10 +8116,22 @@
"__id__": 12
},
"btn_last": {
"__id__": 50
"__id__": 52
},
"btn_next": {
"__id__": 57
"__id__": 59
},
"gou_node": {
"__id__": 18
},
"btn_start": {
"__id__": 42
},
"layout_record": {
"__id__": 67
},
"btn_close": {
"__id__": 72
},
"_id": "eaTVUpqahPfZeO9+sUI7RP"
},
......@@ -8047,34 +8144,34 @@
},
"_children": [
{
"__id__": 171
"__id__": 173
},
{
"__id__": 174
"__id__": 176
},
{
"__id__": 177
"__id__": 179
},
{
"__id__": 180
"__id__": 182
},
{
"__id__": 183
"__id__": 185
},
{
"__id__": 186
"__id__": 188
},
{
"__id__": 189
"__id__": 191
},
{
"__id__": 192
"__id__": 194
}
],
"_active": false,
"_components": [],
"_prefab": {
"__id__": 195
"__id__": 197
},
"_opacity": 255,
"_color": {
......@@ -8128,17 +8225,17 @@
"_name": "sahua",
"_objFlags": 0,
"_parent": {
"__id__": 170
"__id__": 172
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 172
"__id__": 174
}
],
"_prefab": {
"__id__": 173
"__id__": 175
},
"_opacity": 255,
"_color": {
......@@ -8192,7 +8289,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 171
"__id__": 173
},
"_enabled": true,
"_materials": [
......@@ -8222,7 +8319,7 @@
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 170
"__id__": 172
},
"asset": {
"__uuid__": "f64b76f1-fff3-40d6-8eb6-07f263db799d"
......@@ -8235,17 +8332,17 @@
"_name": "sahua",
"_objFlags": 0,
"_parent": {
"__id__": 170
"__id__": 172
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 175
"__id__": 177
}
],
"_prefab": {
"__id__": 176
"__id__": 178
},
"_opacity": 255,
"_color": {
......@@ -8299,7 +8396,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 174
"__id__": 176
},
"_enabled": true,
"_materials": [
......@@ -8329,7 +8426,7 @@
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 170
"__id__": 172
},
"asset": {
"__uuid__": "f64b76f1-fff3-40d6-8eb6-07f263db799d"
......@@ -8342,17 +8439,17 @@
"_name": "sahua",
"_objFlags": 0,
"_parent": {
"__id__": 170
"__id__": 172
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 178
"__id__": 180
}
],
"_prefab": {
"__id__": 179
"__id__": 181
},
"_opacity": 255,
"_color": {
......@@ -8406,7 +8503,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 177
"__id__": 179
},
"_enabled": true,
"_materials": [
......@@ -8436,7 +8533,7 @@
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 170
"__id__": 172
},
"asset": {
"__uuid__": "f64b76f1-fff3-40d6-8eb6-07f263db799d"
......@@ -8449,17 +8546,17 @@
"_name": "sahua",
"_objFlags": 0,
"_parent": {
"__id__": 170
"__id__": 172
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 181
"__id__": 183
}
],
"_prefab": {
"__id__": 182
"__id__": 184
},
"_opacity": 255,
"_color": {
......@@ -8513,7 +8610,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 180
"__id__": 182
},
"_enabled": true,
"_materials": [
......@@ -8543,7 +8640,7 @@
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 170
"__id__": 172
},
"asset": {
"__uuid__": "f64b76f1-fff3-40d6-8eb6-07f263db799d"
......@@ -8556,17 +8653,17 @@
"_name": "sahua",
"_objFlags": 0,
"_parent": {
"__id__": 170
"__id__": 172
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 184
"__id__": 186
}
],
"_prefab": {
"__id__": 185
"__id__": 187
},
"_opacity": 255,
"_color": {
......@@ -8620,7 +8717,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 183
"__id__": 185
},
"_enabled": true,
"_materials": [
......@@ -8650,7 +8747,7 @@
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 170
"__id__": 172
},
"asset": {
"__uuid__": "f64b76f1-fff3-40d6-8eb6-07f263db799d"
......@@ -8663,17 +8760,17 @@
"_name": "sahua",
"_objFlags": 0,
"_parent": {
"__id__": 170
"__id__": 172
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 187
"__id__": 189
}
],
"_prefab": {
"__id__": 188
"__id__": 190
},
"_opacity": 255,
"_color": {
......@@ -8727,7 +8824,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 186
"__id__": 188
},
"_enabled": true,
"_materials": [
......@@ -8757,7 +8854,7 @@
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 170
"__id__": 172
},
"asset": {
"__uuid__": "f64b76f1-fff3-40d6-8eb6-07f263db799d"
......@@ -8770,17 +8867,17 @@
"_name": "sahua",
"_objFlags": 0,
"_parent": {
"__id__": 170
"__id__": 172
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 190
"__id__": 192
}
],
"_prefab": {
"__id__": 191
"__id__": 193
},
"_opacity": 255,
"_color": {
......@@ -8834,7 +8931,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 189
"__id__": 191
},
"_enabled": true,
"_materials": [
......@@ -8864,7 +8961,7 @@
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 170
"__id__": 172
},
"asset": {
"__uuid__": "f64b76f1-fff3-40d6-8eb6-07f263db799d"
......@@ -8877,17 +8974,17 @@
"_name": "sahua",
"_objFlags": 0,
"_parent": {
"__id__": 170
"__id__": 172
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 193
"__id__": 195
}
],
"_prefab": {
"__id__": 194
"__id__": 196
},
"_opacity": 255,
"_color": {
......@@ -8941,7 +9038,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 192
"__id__": 194
},
"_enabled": true,
"_materials": [
......@@ -8971,7 +9068,7 @@
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 170
"__id__": 172
},
"asset": {
"__uuid__": "f64b76f1-fff3-40d6-8eb6-07f263db799d"
......@@ -8982,7 +9079,7 @@
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 170
"__id__": 172
},
"asset": {
"__uuid__": "f64b76f1-fff3-40d6-8eb6-07f263db799d"
......
......@@ -114,6 +114,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
this.layout_item.removeAllChildren();
}
initListener() {
pg.view.touchOn(this.btn_close, this.onTouchRecordClose, this);
pg.view.touchOn(this.btn_last, this.lastPage, this);
pg.view.touchOn(this.btn_next, this.nextPage, this);
pg.view.touchMoveOn(this.layer_touch, this.onTouchPanelMove, this);
......@@ -185,11 +186,11 @@ export default class SceneComponent extends MyCocosSceneComponent {
isAllOver() {
let isAllOver = true;
let layer = this.CurrentLayer;
let layout_up = pg.view.find(layer, 'layout_up')
layout_up.children.forEach(item => {
if (item.data.state != "collider") isAllOver = false;
})
return isAllOver;
// let layout_up = pg.view.find(layer, 'layout_up')
// layout_up.children.forEach(item => {
// if (item.data.state != "collider") isAllOver = false;
// })
return false;
}
checkCards(dt) {
this.checkCardsTime -= dt;
......@@ -217,68 +218,66 @@ export default class SceneComponent extends MyCocosSceneComponent {
pg.view.visible(pg.view.find(this.btn_next, 'img_1'), !!this.NextData);
}
initBottom() {
let layout_bottom = pg.view.find(this, 'layout_bottom')
layout_bottom.removeAllChildren();
this.list.forEach((data, i) => {
let item = pg.view.clone(pg.view.find(this, 'point'))
item.data = {
idx: i
}
item.x = 0;
item.y = 0;
layout_bottom.addChild(item);
})
// let layout_bottom = pg.view.find(this, 'layout_bottom')
// layout_bottom.removeAllChildren();
// this.list.forEach((data, i) => {
// let item = pg.view.clone(pg.view.find(this, 'point'))
// item.data = {
// idx: i
// }
// item.x = 0;
// item.y = 0;
// layout_bottom.addChild(item);
// })
}
updateBottom(dt) {
let layout_bottom = pg.view.find(this, 'layout_bottom')
layout_bottom.children.forEach((item, i) => {
let data = item.data;
let idx = data.idx;
let dt = this.list[idx];
// 每个游戏此处逻辑重写即可
// let isRight = (dt.right && dt.isChose == "yes") || (!dt.right && dt.isChose == "no");
let isRight = dt.isChose == "right";//
let point_orange_normal = pg.view.find(item, 'point_orange_normal')
let point_orange_right = pg.view.find(item, 'point_orange_right')
let point_orange_wrong = pg.view.find(item, 'point_orange_wrong')
let point_orange_select_normal = pg.view.find(item, 'point_orange_select_normal')
let point_orange_select_right = pg.view.find(item, 'point_orange_select_right')
let point_orange_select_wrong = pg.view.find(item, 'point_orange_select_wrong')
if (this.count == idx) {
point_orange_normal.active = false;
point_orange_right.active = false;
point_orange_wrong.active = false;
if (dt.isChose) {
point_orange_select_normal.active = false;
point_orange_select_right.active = isRight;
point_orange_select_wrong.active = !isRight;
} else {
point_orange_select_normal.active = true;
point_orange_select_right.active = false;
point_orange_select_wrong.active = false;
}
} else {
point_orange_select_normal.active = false;
point_orange_select_right.active = false;
point_orange_select_wrong.active = false;
if (dt.isChose) {
point_orange_normal.active = false;
point_orange_right.active = isRight;
point_orange_wrong.active = !isRight;
} else {
point_orange_normal.active = true;
point_orange_right.active = false;
point_orange_wrong.active = false;
}
}
})
// let layout_bottom = pg.view.find(this, 'layout_bottom')
// layout_bottom.children.forEach((item, i) => {
// let data = item.data;
// let idx = data.idx;
// let dt = this.list[idx];
// // 每个游戏此处逻辑重写即可
// // let isRight = (dt.right && dt.isChose == "yes") || (!dt.right && dt.isChose == "no");
// let isRight = dt.isChose == "right";//
// let point_orange_normal = pg.view.find(item, 'point_orange_normal')
// let point_orange_right = pg.view.find(item, 'point_orange_right')
// let point_orange_wrong = pg.view.find(item, 'point_orange_wrong')
// let point_orange_select_normal = pg.view.find(item, 'point_orange_select_normal')
// let point_orange_select_right = pg.view.find(item, 'point_orange_select_right')
// let point_orange_select_wrong = pg.view.find(item, 'point_orange_select_wrong')
// if (this.count == idx) {
// point_orange_normal.active = false;
// point_orange_right.active = false;
// point_orange_wrong.active = false;
// if (dt.isChose) {
// point_orange_select_normal.active = false;
// point_orange_select_right.active = isRight;
// point_orange_select_wrong.active = !isRight;
// } else {
// point_orange_select_normal.active = true;
// point_orange_select_right.active = false;
// point_orange_select_wrong.active = false;
// }
// } else {
// point_orange_select_normal.active = false;
// point_orange_select_right.active = false;
// point_orange_select_wrong.active = false;
// if (dt.isChose) {
// point_orange_normal.active = false;
// point_orange_right.active = isRight;
// point_orange_wrong.active = !isRight;
// } else {
// point_orange_normal.active = true;
// point_orange_right.active = false;
// point_orange_wrong.active = false;
// }
// }
// })
}
private readyNext: boolean;
private readyTime: number;
......@@ -467,199 +466,129 @@ export default class SceneComponent extends MyCocosSceneComponent {
layer.data = data;
// 根据数据来渲染 这里来增加按钮部分
console.log("items");
let btn_voice = pg.view.find(layer, "btn_voice");
let btn_play = pg.view.find(layer, "btn_play");
pg.view.touchOn(btn_voice, this.onTouchCardRecord, this);
pg.view.touchOn(btn_play, this.onTouchCardPlay, this);
let img = pg.view.find(layer, 'title/img')
pg.view.setNetImg(img, data.image, { w: 660, h: 320 })
let posList = {
"4": [-445, -150, 150, 445],
"3": [-400, -10, 380],
"2": [-150, 150],
"1": [-10]
}
let posArray = posList[data.options.length];
let posY = -30;
// let img = pg.view.find(layer, 'title/img')
// pg.view.setNetImg(img, data.image, { w: 660, h: 320 })
// 上层渲染
let layout_up = pg.view.find(layer, 'layout_up')
let list = data.letterList.concat();
let layout_card = pg.view.find(layer, 'layout_card')
let list = data.options.concat();
let card = pg.view.find(layer, 'card');
list.forEach((dt, i) => {
dt.idx = i;
dt.type = "up";
let item = pg.view.clone(card);
item.active = true;
item.x = 0;
item.y = 0;
item.x = posArray[i];
item.y = posY;
item.data = dt;
layout_up.addChild(item);
layout_card.addChild(item);
this.updateCard(item, dt);
// pg.view.touchOn(item, this.onTouchCard, this);
})
this.scheduleOnce(() => {
// 获取顶部得总长度,然后依次设定下方的坐标,
let upWidth = layout_up.width;
// 后期可以改造成按照宽度累加计算
function getPos(itemParent, i) {
let node = layout_up.children[i];
// 转换成世界坐标后 转换回来
let pos = pg.pos.getNodePosByTargetNode(itemParent, node)
return pos;
}
// 下层渲染
let layout_down = pg.view.find(layer, 'layout_down')
let downList = layer.data.letterList.concat();
downList.sort((a, b) => Math.random() - 0.5)
.sort((a, b) => Math.random() - 0.5)
.sort((a, b) => Math.random() - 0.5)
.sort((a, b) => Math.random() - 0.5)
.sort((a, b) => Math.random() - 0.5)
.sort((a, b) => Math.random() - 0.5)
downList.forEach((dt, i) => {
dt.idx = i;
dt.type = "down";
let item = pg.view.clone(card);
item.active = true;
item.x = getPos(layout_down, i).x;
item.y = 0;
item.orgPos = cc.v2(item.x, item.y)
layout_down.addChild(item);
this.updateCard(item, dt);
item.data = dt;
item.on(cc.Node.EventType.TOUCH_START, this.onTouchStart, this);
item.on(cc.Node.EventType.TOUCH_MOVE, this.onTouchMove, this);
item.on(cc.Node.EventType.TOUCH_END, this.onTouchEnd, this);
})
}, 0.1)
// let btn_voice = pg.view.find(layer, "btn_voice");
// let btn_play = pg.view.find(layer, "btn_play");
// pg.view.touchOn(btn_voice, this.onTouchCardRecord, this);
// pg.view.touchOn(btn_play, this.onTouchCardPlay, this);
}
private currentItem: cc.Node;
onTouchStart(event) {
if (this.currentItem) return;
console.log('1')
let node = event.target;
this.currentItem = node;
this.startCurrentItemAni();
}
onTouchMove(event) {
let node = event.target;
if (node != this.currentItem) return;
node.opacity = 255;
let delta = event.touch.getDelta();
let pos = cc.v2(delta);
let scale = 1;
pos.x /= scale;
pos.y /= scale;
node.x += pos.x;
node.y += pos.y;
}
onTouchEnd(event) {
let node = event.target;
if (node != this.currentItem) return;
this.stopCurrentItemAni();
this.currentItem = null;
// 跟字母区域进行碰撞检测
let colliderNode = this.collider(node);
// 获取当前待碰撞区域
if (!!colliderNode) {
// 碰撞的是当前item
colliderNode.data.state = "collider"
node.data.state = "collider"
// // 正确了 需要处理效果
this.playLocalAudio("right")
let right = pg.view.find(colliderNode, "right");
right.active = true;
pg.view.playDBAnimation(right, "newAnimation", 1)
// 移除node item更变状态
this.updateCard(colliderNode, colliderNode.data);
node.off(cc.Node.EventType.TOUCH_START, this.onTouchStart, this);
node.off(cc.Node.EventType.TOUCH_MOVE, this.onTouchMove, this);
node.off(cc.Node.EventType.TOUCH_END, this.onTouchEnd, this);
node.parent = null;
// 判定是否所有词都ok了
if (this.isAllOver()) {
this.showRecord(this.CurrentLayer);
}
updateCard(item, data) {
item.data = data;
let text = pg.view.find(item, 'text');
let image = pg.view.find(item, 'image');
let image_text_image = pg.view.find(item, 'image_text_image');
let image_text_text = pg.view.find(item, 'image_text_text');
pg.view.visible(text, data.type == 'txt');
pg.view.visible(image, data.type == 'img');
pg.view.visible(image_text_image, data.type == 'img_txt');
pg.view.visible(image_text_text, data.type == 'img_txt');
if (data.type == "img") {
pg.view.setNetImg(image, data.image, { w: 240, h: 350 })
} else if (data.type == 'txt') {
pg.view.setString(text, data.text)
} else {
// pg.audio.playLocalAudio(pg.view.find(this.res_audio, "fail"))
let subX = node.x - node.orgPos.x;
let subY = node.y - node.orgPos.y;
node.x -= subX;
node.y -= subY;
pg.view.setString(image_text_text, data.text)
pg.view.setNetImg(image_text_image, data.image, { w: 240, h: 270 })
}
}
private currentData: any;
private currentItem: any;
startCurrentItemAni() {
let child = this.currentItem;
cc.tween(child).to(0.15, { scaleX: 1.1, scaleY: 0.9 }).to(0.15, { scaleX: 1, scaleY: 1 }).delay(0.25).union().repeatForever().start();
}
stopCurrentItemAni() {
let child = this.currentItem;
cc.Tween.stopAllByTarget(child)
}
collider(node) {
// 当前节点和库中所有节点进行碰撞
@property(cc.Node)
private gou_node: cc.Node = null;
@property(cc.Node)
private btn_start: cc.Node = null;
onTouchStart(e) {
// 处理问题
let image = pg.view.find(this.btn_start, 'image');
cc.tween(image).by(0.1, { y: -50 }).by(0.1, { y: 50 }).start();
// 从剩余的item中取出一个执行。
let layer = this.CurrentLayer;
let layout_up = pg.view.find(layer, 'layout_up')
let layout_down = pg.view.find(layer, 'layout_down')
let itemList = layout_up.children;
let nodePos = cc.v2(node);
let colliderItem = null;
itemList.forEach(item => {
if (!node.parent) return;
if (item.data.state == "collider") return;
let pos = pg.pos.getNodePosByTargetNode(node.parent, item);
let width = item.width;
let height = item.height;
let maxX = pos.x + width / 2;
let minX = pos.x - width / 2;
let maxY = pos.y + height / 2;
let minY = pos.y - height / 2;
if (nodePos.x < maxX && nodePos.x > minX && nodePos.y < maxY && nodePos.y > minY) {
if (item.data.text == node.data.text) {
colliderItem = item;
}
}
let layout_card = pg.view.find(layer, 'layout_card')
let list = layout_card.children.concat()
.sort((A, B) => Math.random() - 0.5)
.sort((A, B) => Math.random() - 0.5)
.sort((A, B) => Math.random() - 0.5)
.sort((A, B) => Math.random() - 0.5)
.sort((A, B) => Math.random() - 0.5);
let item = list[0];
this.onTouchCard({ target: item })
}
onTouchCard(e) {
if (this.touchForbid) return;// 顶级禁止全部点击
let item = e.target;
let data = item.data;
this.currentItem = item;
this.currentData = data;
this.touchForbid = true;
// 移动钩子过来 然后弹出面板
cc.tween(this.gou_node)
.to(1, { x: item.x })
.to(0.5, { y: item.y })
.call(() => {
this.touchForbid = false;
this.showRecord(item);
})
return colliderItem;
.start();
}
updateCard(item, data) {
let item_0 = pg.view.find(item, 'item_0');
let item_1 = pg.view.find(item, 'item_1');
let item_0_text = pg.view.find(item_0, 'text');
let item_1_text = pg.view.find(item_1, 'text');
pg.view.setString(item_0_text, data.text);
pg.view.setString(item_1_text, data.text);
if (data.state == "collider") {
pg.view.visible(item_0, false);
pg.view.visible(item_1, true);
} else {
pg.view.visible(item_0, data.type == 'up');
pg.view.visible(item_1, data.type == 'down');
}
}
@property(cc.Node)
private layout_record: cc.Node = null;
@property(cc.Node)
private btn_close: cc.Node = null;
showRecord(item) {
this.layout_record.active = true;
showRecord(layer) {
// 展示待录音内容
this.updateRecordBtns(layer);
let btn_voice = pg.view.find(layer, "btn_voice");
let normal = pg.view.find(btn_voice, 'normal')
cc.tween(normal)
.repeatForever(
cc.tween()
.to(0.7, { scale: 1.1 })
.delay(0.3)
.to(0.7, { scale: 1.00 })
.delay(0.3)
)
.start();
this.btn_voice_time_id = setTimeout(() => {
if (!this.node || !this.node.parent) return;
// 摇晃mic
this.playLocalAudio("wait")
cc.tween(normal).to(0.25, { angle: -15 }).to(0.25, { angle: 0 }).to(0.25, { angle: 15 }).to(0.25, { angle: 0 }).start();
}, 3000);
// let btn_voice = pg.view.find(layer, "btn_voice");
// let normal = pg.view.find(btn_voice, 'normal')
// cc.tween(normal)
// .repeatForever(
// cc.tween()
// .to(0.7, { scale: 1.1 })
// .delay(0.3)
// .to(0.7, { scale: 1.00 })
// .delay(0.3)
// )
// .start();
// this.btn_voice_time_id = setTimeout(() => {
// if (!this.node || !this.node.parent) return;
// // 摇晃mic
// this.playLocalAudio("wait")
// cc.tween(normal).to(0.25, { angle: -15 }).to(0.25, { angle: 0 }).to(0.25, { angle: 15 }).to(0.25, { angle: 0 }).start();
// }, 3000);
}
onTouchRecordClose() {
this.layout_record.active = false;
}
// 前后切换一共有
updateRecordBtns(layer) {
......
export const defaultData =
{
"title": "zheshibiaoti",
"questions": [{
"questionAudio": "",
"duration": 120,
"type": "img",
"image": "http://staging-teach.cdn.ireadabc.com/a71f2b71e45ff2525714494f6edd624b.jpg",
"audio": "",
"text": "",
"right": false,
// "letterList": [{ "text": "one" }, { "text": "two" }, { "text": "three" }, { "text": "four" }]
"letterList": [{ "text": "one" }]
}, {
"questionAudio": "",
"duration": 120,
"type": "img",
"image": "http://staging-teach.cdn.ireadabc.com/c62b5960641fd7cf29613cc45fb00cd6.png",
"audio": "",
"text": "",
"right": false,
"letterList": [{ "text": "it" }, { "text": "is" }, { "text": "a" }, { "text": "wood" }]
}]
}
let m = {
export const defaultData = {
"title": "",
"questions": [
{
......
......@@ -4588,6 +4588,8 @@ declare namespace cc {
/** !#en Returns a normalized vector representing the forward direction (Z axis) of the node in world space.
!#zh 获取节点正前方(z 轴)面对的方向,返回值为世界坐标系下的归一化向量 */
forward: Vec3;
data: any;
orgPos: Vec2;
/**
@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