Commit 85ea6811 authored by yu's avatar yu

题目随机

parent d7bbb9c5
...@@ -88,13 +88,21 @@ export default class Game { ...@@ -88,13 +88,21 @@ export default class Game {
this.page = 1; this.page = 1;
this.start = true; this.start = true;
this.lists = []; this.lists = [];
let arr = [];
for (let i = 0; i < this.data.length; i++) { for (let i = 0; i < this.data.length; i++) {
let data = this.data[i]; let data = this.data[i];
this.lists.push(new Item(data, i)); arr.push(new Item(data, i));
} }
this.lists.sort(function () {
return (0.5 - Math.random()); let page = arr[0].page;
}); do {
arr.sort(() => Math.random() - 0.5);
} while (arr[0].page == page);
arr.forEach((item, idx) => {
item.page = idx + 1;
this.lists.push(item);
})
} }
checkSuccess(arr: Option[]) { checkSuccess(arr: Option[]) {
let data = this.getCurrentPage(); let data = this.getCurrentPage();
......
...@@ -96,34 +96,34 @@ ...@@ -96,34 +96,34 @@
"__id__": 67 "__id__": 67
}, },
{ {
"__id__": 90 "__id__": 69
}, },
{ {
"__id__": 92 "__id__": 71
}, },
{ {
"__id__": 95 "__id__": 74
}, },
{ {
"__id__": 104 "__id__": 83
}, },
{ {
"__id__": 106 "__id__": 85
}, },
{ {
"__id__": 113 "__id__": 92
} }
], ],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 122 "__id__": 101
}, },
{ {
"__id__": 123 "__id__": 102
}, },
{ {
"__id__": 124 "__id__": 103
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -3335,21 +3335,11 @@ ...@@ -3335,21 +3335,11 @@
"_parent": { "_parent": {
"__id__": 2 "__id__": 2
}, },
"_children": [ "_children": [],
{
"__id__": 68
},
{
"__id__": 75
},
{
"__id__": 82
}
],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 89 "__id__": 68
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -3401,79 +3391,43 @@ ...@@ -3401,79 +3391,43 @@
"_id": "0e6bWq+VdFUaznqt/jJ9Lm" "_id": "0e6bWq+VdFUaznqt/jJ9Lm"
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Layout",
"_name": "word_item", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "node": {
"__id__": 67 "__id__": 67
}, },
"_children": [ "_enabled": true,
{ "_layoutSize": {
"__id__": 69
},
{
"__id__": 71
},
{
"__id__": 73
}
],
"_active": true,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 122, "width": 426,
"height": 116 "height": 200
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
-152,
-16.072,
0,
0,
0,
0,
1,
1,
1,
1
]
}, },
"_eulerAngles": { "_resize": 1,
"__type__": "cc.Vec3", "_N$layoutType": 1,
"x": 0, "_N$cellSize": {
"y": 0, "__type__": "cc.Size",
"z": 0 "width": 40,
"height": 40
}, },
"_skewX": 0, "_N$startAxis": 0,
"_skewY": 0, "_N$paddingLeft": 0,
"_is3DNode": false, "_N$paddingRight": 0,
"_groupIndex": 0, "_N$paddingTop": 0,
"groupIndex": 0, "_N$paddingBottom": 0,
"_id": "bbj6wWTB9D9Zi24fKPos2T" "_N$spacingX": 30,
"_N$spacingY": 0,
"_N$verticalDirection": 1,
"_N$horizontalDirection": 0,
"_N$affectedByScale": false,
"_id": "dculHDD/FJyLWvSjvjsbGg"
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "fangkuang", "_name": "normal_layout",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 68 "__id__": 2
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
...@@ -3493,8 +3447,8 @@ ...@@ -3493,8 +3447,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 122, "width": 100,
"height": 116 "height": 200
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
...@@ -3506,7 +3460,7 @@ ...@@ -3506,7 +3460,7 @@
"ctor": "Float64Array", "ctor": "Float64Array",
"array": [ "array": [
0, 0,
0, 35.799,
0, 0,
0, 0,
0, 0,
...@@ -3528,52 +3482,55 @@ ...@@ -3528,52 +3482,55 @@
"_is3DNode": false, "_is3DNode": false,
"_groupIndex": 0, "_groupIndex": 0,
"groupIndex": 0, "groupIndex": 0,
"_id": "ecHYKLYIFGNZ0x7P6z0oXX" "_id": "228OOlLMtAq6lo9RmLTw56"
}, },
{ {
"__type__": "cc.Sprite", "__type__": "cc.Layout",
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 69 "__id__": 69
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_layoutSize": {
{ "__type__": "cc.Size",
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" "width": 100,
} "height": 200
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "5ef02ff5-cfad-464f-8851-2cd44b3ab93d"
}, },
"_type": 0, "_resize": 1,
"_sizeMode": 1, "_N$layoutType": 1,
"_fillType": 0, "_N$cellSize": {
"_fillCenter": { "__type__": "cc.Size",
"__type__": "cc.Vec2", "width": 40,
"x": 0, "height": 40
"y": 0
}, },
"_fillStart": 0, "_N$startAxis": 0,
"_fillRange": 0, "_N$paddingLeft": 0,
"_isTrimmedMode": true, "_N$paddingRight": 0,
"_atlas": null, "_N$paddingTop": 0,
"_id": "7fPL5P025EPaDqCQvuVD6R" "_N$paddingBottom": 0,
"_N$spacingX": 15,
"_N$spacingY": 0,
"_N$verticalDirection": 1,
"_N$horizontalDirection": 0,
"_N$affectedByScale": false,
"_id": "80kXs1nmBPf6qBZQQmRMVT"
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "word", "_name": "nor_label",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 68 "__id__": 2
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 72 "__id__": 72
},
{
"__id__": 73
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -3587,8 +3544,8 @@ ...@@ -3587,8 +3544,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 36.07, "width": 6,
"height": 90.72 "height": 144.6
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
...@@ -3600,7 +3557,7 @@ ...@@ -3600,7 +3557,7 @@
"ctor": "Float64Array", "ctor": "Float64Array",
"array": [ "array": [
0, 0,
11.122, 24.851,
0, 0,
0, 0,
0, 0,
...@@ -3622,7 +3579,7 @@ ...@@ -3622,7 +3579,7 @@
"_is3DNode": false, "_is3DNode": false,
"_groupIndex": 0, "_groupIndex": 0,
"groupIndex": 0, "groupIndex": 0,
"_id": "eftlCDGaVNJIpMPbQux97W" "_id": "94YF0tW7FGA4qvmhvv7roQ"
}, },
{ {
"__type__": "cc.Label", "__type__": "cc.Label",
...@@ -3639,10 +3596,10 @@ ...@@ -3639,10 +3596,10 @@
], ],
"_srcBlendFactor": 770, "_srcBlendFactor": 770,
"_dstBlendFactor": 771, "_dstBlendFactor": 771,
"_string": "e", "_string": "",
"_N$string": "e", "_N$string": "",
"_fontSize": 72, "_fontSize": 100,
"_lineHeight": 72, "_lineHeight": 110,
"_enableWrapText": true, "_enableWrapText": true,
"_N$file": { "_N$file": {
"__uuid__": "10fca463-2764-409f-a7b4-c8b320f5d610" "__uuid__": "10fca463-2764-409f-a7b4-c8b320f5d610"
...@@ -3657,35 +3614,60 @@ ...@@ -3657,35 +3614,60 @@
"_N$fontFamily": "Arial", "_N$fontFamily": "Arial",
"_N$overflow": 0, "_N$overflow": 0,
"_N$cacheMode": 0, "_N$cacheMode": 0,
"_id": "316xzYPDRDD61sSRnCH9KP" "_id": "89gMgvLStGhpGKzNNw+bX0"
},
{
"__type__": "cc.LabelOutline",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 71
},
"_enabled": true,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_width": 3,
"_id": "b8SKtMTFpAYoivGC1DvFC9"
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "line", "_name": "tips",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 68 "__id__": 2
}, },
"_children": [], "_children": [
"_active": false, {
"__id__": 75
},
{
"__id__": 77
}
],
"_active": true,
"_components": [ "_components": [
{ {
"__id__": 74 "__id__": 82
} }
], ],
"_prefab": null, "_prefab": null,
"_opacity": 255, "_opacity": 255,
"_color": { "_color": {
"__type__": "cc.Color", "__type__": "cc.Color",
"r": 75, "r": 255,
"g": 129, "g": 255,
"b": 58, "b": 255,
"a": 255 "a": 255
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 33.19, "width": 166,
"height": 90.72 "height": 188
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
...@@ -3697,7 +3679,7 @@ ...@@ -3697,7 +3679,7 @@
"ctor": "Float64Array", "ctor": "Float64Array",
"array": [ "array": [
0, 0,
6.232, 205,
0, 0,
0, 0,
0, 0,
...@@ -3719,1080 +3701,20 @@ ...@@ -3719,1080 +3701,20 @@
"_is3DNode": false, "_is3DNode": false,
"_groupIndex": 0, "_groupIndex": 0,
"groupIndex": 0, "groupIndex": 0,
"_id": "ffxrr82VhKvbB3zV1xImPL" "_id": "72NxPjfKxPLJVuUdFp9MI0"
}, },
{ {
"__type__": "cc.Label", "__type__": "cc.Node",
"_name": "", "_name": "img",
"_objFlags": 0, "_objFlags": 0,
"node": { "_parent": {
"__id__": 73 "__id__": 74
}, },
"_enabled": true, "_children": [],
"_materials": [ "_active": true,
"_components": [
{ {
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432" "__id__": 76
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "_",
"_N$string": "_",
"_fontSize": 72,
"_lineHeight": 72,
"_enableWrapText": true,
"_N$file": {
"__uuid__": "10fca463-2764-409f-a7b4-c8b320f5d610"
},
"_isSystemFontUsed": false,
"_spacingX": 0,
"_batchAsBitmap": false,
"_styleFlags": 0,
"_underlineHeight": 0,
"_N$horizontalAlign": 1,
"_N$verticalAlign": 1,
"_N$fontFamily": "Arial",
"_N$overflow": 0,
"_N$cacheMode": 0,
"_id": "5chmK+y6pHLLjj3A2PxjYr"
},
{
"__type__": "cc.Node",
"_name": "word_item",
"_objFlags": 0,
"_parent": {
"__id__": 67
},
"_children": [
{
"__id__": 76
},
{
"__id__": 78
},
{
"__id__": 80
}
],
"_active": true,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 122,
"height": 116
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
-16.072,
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": "73J+xYFOxBGqE8jTsGOrM6"
},
{
"__type__": "cc.Node",
"_name": "fangkuang",
"_objFlags": 0,
"_parent": {
"__id__": 75
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 77
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 122,
"height": 116
},
"_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": "c32QYNJLZMe5xcWS81elUc"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 76
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "5ef02ff5-cfad-464f-8851-2cd44b3ab93d"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "a12ZMW/wZJA52ZQIOjnpQ3"
},
{
"__type__": "cc.Node",
"_name": "word",
"_objFlags": 0,
"_parent": {
"__id__": 75
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 79
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 75,
"g": 129,
"b": 58,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 36.07,
"height": 90.72
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
11.122,
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": "6ajZIpKGVJ7plufQ8wSuYI"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 78
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "e",
"_N$string": "e",
"_fontSize": 72,
"_lineHeight": 72,
"_enableWrapText": true,
"_N$file": {
"__uuid__": "10fca463-2764-409f-a7b4-c8b320f5d610"
},
"_isSystemFontUsed": false,
"_spacingX": 0,
"_batchAsBitmap": false,
"_styleFlags": 0,
"_underlineHeight": 0,
"_N$horizontalAlign": 1,
"_N$verticalAlign": 1,
"_N$fontFamily": "Arial",
"_N$overflow": 0,
"_N$cacheMode": 0,
"_id": "cagWzYTIlA86ujEdlrHY5N"
},
{
"__type__": "cc.Node",
"_name": "line",
"_objFlags": 0,
"_parent": {
"__id__": 75
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 81
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 75,
"g": 129,
"b": 58,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 33.19,
"height": 90.72
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
6.232,
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": "bflqvMToRMu62AeDXjanum"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 80
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "_",
"_N$string": "_",
"_fontSize": 72,
"_lineHeight": 72,
"_enableWrapText": true,
"_N$file": {
"__uuid__": "10fca463-2764-409f-a7b4-c8b320f5d610"
},
"_isSystemFontUsed": false,
"_spacingX": 0,
"_batchAsBitmap": false,
"_styleFlags": 0,
"_underlineHeight": 0,
"_N$horizontalAlign": 1,
"_N$verticalAlign": 1,
"_N$fontFamily": "Arial",
"_N$overflow": 0,
"_N$cacheMode": 0,
"_id": "2cmDNYy1dEErKcKPEWrRXN"
},
{
"__type__": "cc.Node",
"_name": "word_item",
"_objFlags": 0,
"_parent": {
"__id__": 67
},
"_children": [
{
"__id__": 83
},
{
"__id__": 85
},
{
"__id__": 87
}
],
"_active": true,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 122,
"height": 116
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
152,
-16.072,
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": "a0eW2afM1G0agHk+6qFIMG"
},
{
"__type__": "cc.Node",
"_name": "fangkuang",
"_objFlags": 0,
"_parent": {
"__id__": 82
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 84
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 122,
"height": 116
},
"_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": "21BKbJxk5IZ5/0OKrk30uU"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 83
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "5ef02ff5-cfad-464f-8851-2cd44b3ab93d"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "56Re128B5G0pxYDsdS6A8C"
},
{
"__type__": "cc.Node",
"_name": "word",
"_objFlags": 0,
"_parent": {
"__id__": 82
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 86
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 75,
"g": 129,
"b": 58,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 36.07,
"height": 90.72
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
11.122,
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": "015bbewXdOqaMnkf//PwbO"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 85
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "e",
"_N$string": "e",
"_fontSize": 72,
"_lineHeight": 72,
"_enableWrapText": true,
"_N$file": {
"__uuid__": "10fca463-2764-409f-a7b4-c8b320f5d610"
},
"_isSystemFontUsed": false,
"_spacingX": 0,
"_batchAsBitmap": false,
"_styleFlags": 0,
"_underlineHeight": 0,
"_N$horizontalAlign": 1,
"_N$verticalAlign": 1,
"_N$fontFamily": "Arial",
"_N$overflow": 0,
"_N$cacheMode": 0,
"_id": "81dRsLrTRKx6+CyX6UtwNv"
},
{
"__type__": "cc.Node",
"_name": "line",
"_objFlags": 0,
"_parent": {
"__id__": 82
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 88
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 75,
"g": 129,
"b": 58,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 33.19,
"height": 90.72
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
6.232,
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": "3eKICXw4BDpKUgn6UV5bfe"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 87
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "_",
"_N$string": "_",
"_fontSize": 72,
"_lineHeight": 72,
"_enableWrapText": true,
"_N$file": {
"__uuid__": "10fca463-2764-409f-a7b4-c8b320f5d610"
},
"_isSystemFontUsed": false,
"_spacingX": 0,
"_batchAsBitmap": false,
"_styleFlags": 0,
"_underlineHeight": 0,
"_N$horizontalAlign": 1,
"_N$verticalAlign": 1,
"_N$fontFamily": "Arial",
"_N$overflow": 0,
"_N$cacheMode": 0,
"_id": "edp3MfUw1CDowS70xjOHd7"
},
{
"__type__": "cc.Layout",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 67
},
"_enabled": true,
"_layoutSize": {
"__type__": "cc.Size",
"width": 426,
"height": 200
},
"_resize": 1,
"_N$layoutType": 1,
"_N$cellSize": {
"__type__": "cc.Size",
"width": 40,
"height": 40
},
"_N$startAxis": 0,
"_N$paddingLeft": 0,
"_N$paddingRight": 0,
"_N$paddingTop": 0,
"_N$paddingBottom": 0,
"_N$spacingX": 30,
"_N$spacingY": 0,
"_N$verticalDirection": 1,
"_N$horizontalDirection": 0,
"_N$affectedByScale": false,
"_id": "dculHDD/FJyLWvSjvjsbGg"
},
{
"__type__": "cc.Node",
"_name": "normal_layout",
"_objFlags": 0,
"_parent": {
"__id__": 2
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 91
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 100,
"height": 200
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
35.799,
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": "228OOlLMtAq6lo9RmLTw56"
},
{
"__type__": "cc.Layout",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 90
},
"_enabled": true,
"_layoutSize": {
"__type__": "cc.Size",
"width": 100,
"height": 200
},
"_resize": 1,
"_N$layoutType": 1,
"_N$cellSize": {
"__type__": "cc.Size",
"width": 40,
"height": 40
},
"_N$startAxis": 0,
"_N$paddingLeft": 0,
"_N$paddingRight": 0,
"_N$paddingTop": 0,
"_N$paddingBottom": 0,
"_N$spacingX": 15,
"_N$spacingY": 0,
"_N$verticalDirection": 1,
"_N$horizontalDirection": 0,
"_N$affectedByScale": false,
"_id": "80kXs1nmBPf6qBZQQmRMVT"
},
{
"__type__": "cc.Node",
"_name": "nor_label",
"_objFlags": 0,
"_parent": {
"__id__": 2
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 93
},
{
"__id__": 94
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 75,
"g": 129,
"b": 58,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 106,
"height": 144.6
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
24.851,
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": "94YF0tW7FGA4qvmhvv7roQ"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 92
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "",
"_N$string": "",
"_fontSize": 100,
"_lineHeight": 110,
"_enableWrapText": true,
"_N$file": {
"__uuid__": "10fca463-2764-409f-a7b4-c8b320f5d610"
},
"_isSystemFontUsed": false,
"_spacingX": 0,
"_batchAsBitmap": false,
"_styleFlags": 0,
"_underlineHeight": 0,
"_N$horizontalAlign": 1,
"_N$verticalAlign": 1,
"_N$fontFamily": "Arial",
"_N$overflow": 0,
"_N$cacheMode": 0,
"_id": "89gMgvLStGhpGKzNNw+bX0"
},
{
"__type__": "cc.LabelOutline",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 92
},
"_enabled": true,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_width": 3,
"_id": "b8SKtMTFpAYoivGC1DvFC9"
},
{
"__type__": "cc.Node",
"_name": "tips",
"_objFlags": 0,
"_parent": {
"__id__": 2
},
"_children": [
{
"__id__": 96
},
{
"__id__": 98
}
],
"_active": true,
"_components": [
{
"__id__": 103
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 166,
"height": 188
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
205,
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": "72NxPjfKxPLJVuUdFp9MI0"
},
{
"__type__": "cc.Node",
"_name": "img",
"_objFlags": 0,
"_parent": {
"__id__": 95
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 97
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -4848,7 +3770,7 @@ ...@@ -4848,7 +3770,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 96 "__id__": 75
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -4880,20 +3802,20 @@ ...@@ -4880,20 +3802,20 @@
"_name": "icon", "_name": "icon",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 95 "__id__": 74
}, },
"_children": [ "_children": [
{ {
"__id__": 99 "__id__": 78
} }
], ],
"_active": false, "_active": false,
"_components": [ "_components": [
{ {
"__id__": 101 "__id__": 80
}, },
{ {
"__id__": 102 "__id__": 81
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -4949,13 +3871,13 @@ ...@@ -4949,13 +3871,13 @@
"_name": "icon_2", "_name": "icon_2",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 98 "__id__": 77
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 100 "__id__": 79
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5011,7 +3933,7 @@ ...@@ -5011,7 +3933,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 99 "__id__": 78
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5043,7 +3965,7 @@ ...@@ -5043,7 +3965,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 98 "__id__": 77
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5075,7 +3997,7 @@ ...@@ -5075,7 +3997,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 98 "__id__": 77
}, },
"_enabled": true, "_enabled": true,
"_normalMaterial": null, "_normalMaterial": null,
...@@ -5143,7 +4065,7 @@ ...@@ -5143,7 +4065,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 95 "__id__": 74
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5181,7 +4103,7 @@ ...@@ -5181,7 +4103,7 @@
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 105 "__id__": 84
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5237,7 +4159,7 @@ ...@@ -5237,7 +4159,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 104 "__id__": 83
}, },
"_enabled": true, "_enabled": true,
"alignMode": 1, "alignMode": 1,
...@@ -5268,16 +4190,16 @@ ...@@ -5268,16 +4190,16 @@
}, },
"_children": [ "_children": [
{ {
"__id__": 107 "__id__": 86
}, },
{ {
"__id__": 110 "__id__": 89
} }
], ],
"_active": false, "_active": false,
"_components": [ "_components": [
{ {
"__id__": 112 "__id__": 91
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5333,16 +4255,16 @@ ...@@ -5333,16 +4255,16 @@
"_name": "New Sprite(Splash)", "_name": "New Sprite(Splash)",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 106 "__id__": 85
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 108 "__id__": 87
}, },
{ {
"__id__": 109 "__id__": 88
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5398,7 +4320,7 @@ ...@@ -5398,7 +4320,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 107 "__id__": 86
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5430,7 +4352,7 @@ ...@@ -5430,7 +4352,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 107 "__id__": 86
}, },
"_enabled": true, "_enabled": true,
"alignMode": 1, "alignMode": 1,
...@@ -5457,13 +4379,13 @@ ...@@ -5457,13 +4379,13 @@
"_name": "bg_good-job2", "_name": "bg_good-job2",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 106 "__id__": 85
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 111 "__id__": 90
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5519,7 +4441,7 @@ ...@@ -5519,7 +4441,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 110 "__id__": 89
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5551,7 +4473,7 @@ ...@@ -5551,7 +4473,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 106 "__id__": 85
}, },
"_enabled": true, "_enabled": true,
"alignMode": 1, "alignMode": 1,
...@@ -5582,19 +4504,19 @@ ...@@ -5582,19 +4504,19 @@
}, },
"_children": [ "_children": [
{ {
"__id__": 114 "__id__": 93
}, },
{ {
"__id__": 117 "__id__": 96
} }
], ],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 120 "__id__": 99
}, },
{ {
"__id__": 121 "__id__": 100
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5650,16 +4572,16 @@ ...@@ -5650,16 +4572,16 @@
"_name": "bar", "_name": "bar",
"_objFlags": 512, "_objFlags": 512,
"_parent": { "_parent": {
"__id__": 113 "__id__": 92
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 115 "__id__": 94
}, },
{ {
"__id__": 116 "__id__": 95
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5715,7 +4637,7 @@ ...@@ -5715,7 +4637,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 114 "__id__": 93
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5747,7 +4669,7 @@ ...@@ -5747,7 +4669,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 114 "__id__": 93
}, },
"_enabled": true, "_enabled": true,
"alignMode": 1, "alignMode": 1,
...@@ -5774,16 +4696,16 @@ ...@@ -5774,16 +4696,16 @@
"_name": "pro_label", "_name": "pro_label",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 113 "__id__": 92
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 118 "__id__": 97
}, },
{ {
"__id__": 119 "__id__": 98
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -5839,7 +4761,7 @@ ...@@ -5839,7 +4761,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 117 "__id__": 96
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5872,7 +4794,7 @@ ...@@ -5872,7 +4794,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 117 "__id__": 96
}, },
"_enabled": true, "_enabled": true,
"alignMode": 1, "alignMode": 1,
...@@ -5899,7 +4821,7 @@ ...@@ -5899,7 +4821,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 113 "__id__": 92
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -5931,12 +4853,12 @@ ...@@ -5931,12 +4853,12 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 113 "__id__": 92
}, },
"_enabled": true, "_enabled": true,
"_N$totalLength": 540, "_N$totalLength": 540,
"_N$barSprite": { "_N$barSprite": {
"__id__": 115 "__id__": 94
}, },
"_N$mode": 0, "_N$mode": 0,
"_N$progress": 0, "_N$progress": 0,
...@@ -6002,7 +4924,7 @@ ...@@ -6002,7 +4924,7 @@
"__id__": 67 "__id__": 67
}, },
"nor_label": { "nor_label": {
"__id__": 92 "__id__": 71
}, },
"op_item": { "op_item": {
"__id__": 28 "__id__": 28
...@@ -6011,13 +4933,13 @@ ...@@ -6011,13 +4933,13 @@
"__id__": 60 "__id__": 60
}, },
"tips": { "tips": {
"__id__": 95 "__id__": 74
}, },
"progressBar": { "progressBar": {
"__id__": 113 "__id__": 92
}, },
"goodJob": { "goodJob": {
"__id__": 106 "__id__": 85
}, },
"_id": "c7RS18039BKJE5rgl8xIoE" "_id": "c7RS18039BKJE5rgl8xIoE"
} }
......
...@@ -259,9 +259,8 @@ export default class PuzzleJigsaw extends MyCocosSceneComponent { ...@@ -259,9 +259,8 @@ export default class PuzzleJigsaw extends MyCocosSceneComponent {
itemBg.errorCount++; itemBg.errorCount++;
if (itemBg.errorCount >= 3) { if (itemBg.errorCount >= 3) {
this.errorThere(target, itemBg); this.errorThere(target, itemBg);
this.playLocalAudio("right").then(() => { this.playLocalAudio("right");
this.roundOver(); this.roundOver();
});
} else { } else {
this.playLocalAudio("error"); this.playLocalAudio("error");
this.moveError(target, data); this.moveError(target, data);
...@@ -277,9 +276,8 @@ export default class PuzzleJigsaw extends MyCocosSceneComponent { ...@@ -277,9 +276,8 @@ export default class PuzzleJigsaw extends MyCocosSceneComponent {
let line = cc.find("line", item); let line = cc.find("line", item);
word.active = true; word.active = true;
line.active = false; line.active = false;
this.playLocalAudio("right").then(() => { this.playLocalAudio("right");
this.roundOver(); this.roundOver();
});
} }
private moveError(target, data) { private moveError(target, data) {
this.op_layout.children.forEach((item) => { this.op_layout.children.forEach((item) => {
...@@ -313,9 +311,12 @@ export default class PuzzleJigsaw extends MyCocosSceneComponent { ...@@ -313,9 +311,12 @@ export default class PuzzleJigsaw extends MyCocosSceneComponent {
} }
private roundOver() { private roundOver() {
if (this.checkRoundOver()) { if (this.checkRoundOver()) {
cc.tween(this.nor_label)
.delay(0.5).call(() => {
this.word_layout.active = false; this.word_layout.active = false;
this.word_layout.removeAllChildren(); this.word_layout.removeAllChildren();
cc.tween(this.nor_label).to(0.1, { opacity: 255 }).start(); })
.to(0.1, { opacity: 255 }).delay(0.5).call(() => {
let data = Game.getIns().getCurrentPage(); let data = Game.getIns().getCurrentPage();
pg.audio.playAudioByUrl(data.wordAudio).then(() => { pg.audio.playAudioByUrl(data.wordAudio).then(() => {
let pro = this.progressBar.getComponent(cc.ProgressBar); let pro = this.progressBar.getComponent(cc.ProgressBar);
...@@ -336,6 +337,7 @@ export default class PuzzleJigsaw extends MyCocosSceneComponent { ...@@ -336,6 +337,7 @@ export default class PuzzleJigsaw extends MyCocosSceneComponent {
} }
}).start(); }).start();
}) })
}).start();
} }
} }
private checkRoundOver() { private checkRoundOver() {
......
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