Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
op_input
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
template admin
op_input
Commits
85ea6811
Commit
85ea6811
authored
Aug 23, 2022
by
yu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
题目随机
parent
d7bbb9c5
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
210 additions
and
1278 deletions
+210
-1278
Game.ts
assets/op_input/scene/Game.ts
+12
-4
op_input.fire
assets/op_input/scene/op_input.fire
+168
-1246
op_input.ts
assets/op_input/scene/op_input.ts
+30
-28
No files found.
assets/op_input/scene/Game.ts
View file @
85ea6811
...
...
@@ -88,13 +88,21 @@ export default class Game {
this
.
page
=
1
;
this
.
start
=
true
;
this
.
lists
=
[];
let
arr
=
[];
for
(
let
i
=
0
;
i
<
this
.
data
.
length
;
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
[])
{
let
data
=
this
.
getCurrentPage
();
...
...
assets/op_input/scene/op_input.fire
View file @
85ea6811
...
...
@@ -96,34 +96,34 @@
"__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,
"_components": [
{
"__id__": 1
22
"__id__": 1
01
},
{
"__id__": 1
23
"__id__": 1
02
},
{
"__id__": 1
24
"__id__": 1
03
}
],
"_prefab": null,
...
...
@@ -3335,21 +3335,11 @@
"_parent": {
"__id__": 2
},
"_children": [
{
"__id__": 68
},
{
"__id__": 75
},
{
"__id__": 82
}
],
"_children": [],
"_active": true,
"_components": [
{
"__id__":
89
"__id__":
68
}
],
"_prefab": null,
...
...
@@ -3401,79 +3391,43 @@
"_id": "0e6bWq+VdFUaznqt/jJ9Lm"
},
{
"__type__": "cc.
Node
",
"_name": "
word_item
",
"__type__": "cc.
Layout
",
"_name": "",
"_objFlags": 0,
"
_parent
": {
"
node
": {
"__id__": 67
},
"_children": [
{
"__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": {
"_enabled": true,
"_layoutSize": {
"__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
]
"width": 426,
"height": 200
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
"_resize": 1,
"_N$layoutType": 1,
"_N$cellSize": {
"__type__": "cc.Size",
"width": 40,
"height": 40
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "bbj6wWTB9D9Zi24fKPos2T"
"_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": "
fangkuang
",
"_name": "
normal_layout
",
"_objFlags": 0,
"_parent": {
"__id__":
68
"__id__":
2
},
"_children": [],
"_active": true,
...
...
@@ -3493,8 +3447,8 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width": 1
22
,
"height":
116
"width": 1
00
,
"height":
200
},
"_anchorPoint": {
"__type__": "cc.Vec2",
...
...
@@ -3506,7 +3460,7 @@
"ctor": "Float64Array",
"array": [
0,
0
,
35.799
,
0,
0,
0,
...
...
@@ -3528,52 +3482,55 @@
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "
ecHYKLYIFGNZ0x7P6z0oXX
"
"_id": "
228OOlLMtAq6lo9RmLTw56
"
},
{
"__type__": "cc.
Sprite
",
"__type__": "cc.
Layout
",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 69
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "5ef02ff5-cfad-464f-8851-2cd44b3ab93d"
"_layoutSize": {
"__type__": "cc.Size",
"width": 100,
"height": 200
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
"_resize": 1,
"_N$layoutType": 1,
"_N$cellSize": {
"__type__": "cc.Size",
"width": 40,
"height": 40
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "7fPL5P025EPaDqCQvuVD6R"
"_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": "
word
",
"_name": "
nor_label
",
"_objFlags": 0,
"_parent": {
"__id__":
68
"__id__":
2
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 72
},
{
"__id__": 73
}
],
"_prefab": null,
...
...
@@ -3587,8 +3544,8 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width":
36.07
,
"height":
90.72
"width":
6
,
"height":
144.6
},
"_anchorPoint": {
"__type__": "cc.Vec2",
...
...
@@ -3600,7 +3557,7 @@
"ctor": "Float64Array",
"array": [
0,
11.122
,
24.851
,
0,
0,
0,
...
...
@@ -3622,7 +3579,7 @@
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "
eftlCDGaVNJIpMPbQux97W
"
"_id": "
94YF0tW7FGA4qvmhvv7roQ
"
},
{
"__type__": "cc.Label",
...
...
@@ -3639,10 +3596,10 @@
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "
e
",
"_N$string": "
e
",
"_fontSize":
72
,
"_lineHeight":
72
,
"_string": "",
"_N$string": "",
"_fontSize":
100
,
"_lineHeight":
110
,
"_enableWrapText": true,
"_N$file": {
"__uuid__": "10fca463-2764-409f-a7b4-c8b320f5d610"
...
...
@@ -3657,35 +3614,60 @@
"_N$fontFamily": "Arial",
"_N$overflow": 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",
"_name": "
line
",
"_name": "
tips
",
"_objFlags": 0,
"_parent": {
"__id__":
68
"__id__":
2
},
"_children": [],
"_active": false,
"_children": [
{
"__id__": 75
},
{
"__id__": 77
}
],
"_active": true,
"_components": [
{
"__id__":
74
"__id__":
82
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r":
7
5,
"g":
129
,
"b":
58
,
"r":
25
5,
"g":
255
,
"b":
255
,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width":
33.19
,
"height":
90.72
"width":
166
,
"height":
188
},
"_anchorPoint": {
"__type__": "cc.Vec2",
...
...
@@ -3697,7 +3679,7 @@
"ctor": "Float64Array",
"array": [
0,
6.232
,
205
,
0,
0,
0,
...
...
@@ -3719,1080 +3701,20 @@
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "
ffxrr82VhKvbB3zV1xImPL
"
"_id": "
72NxPjfKxPLJVuUdFp9MI0
"
},
{
"__type__": "cc.
Label
",
"_name": "",
"__type__": "cc.
Node
",
"_name": "
img
",
"_objFlags": 0,
"
node
": {
"__id__": 7
3
"
_parent
": {
"__id__": 7
4
},
"_enabled": true,
"_materials": [
"_children": [],
"_active": true,
"_components": [
{
"__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": "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
"__id__": 76
}
],
"_prefab": null,
...
...
@@ -4848,7 +3770,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
96
"__id__":
75
},
"_enabled": true,
"_materials": [
...
...
@@ -4880,20 +3802,20 @@
"_name": "icon",
"_objFlags": 0,
"_parent": {
"__id__":
95
"__id__":
74
},
"_children": [
{
"__id__":
99
"__id__":
78
}
],
"_active": false,
"_components": [
{
"__id__":
101
"__id__":
80
},
{
"__id__":
102
"__id__":
81
}
],
"_prefab": null,
...
...
@@ -4949,13 +3871,13 @@
"_name": "icon_2",
"_objFlags": 0,
"_parent": {
"__id__":
98
"__id__":
77
},
"_children": [],
"_active": true,
"_components": [
{
"__id__":
100
"__id__":
79
}
],
"_prefab": null,
...
...
@@ -5011,7 +3933,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
99
"__id__":
78
},
"_enabled": true,
"_materials": [
...
...
@@ -5043,7 +3965,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
98
"__id__":
77
},
"_enabled": true,
"_materials": [
...
...
@@ -5075,7 +3997,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
98
"__id__":
77
},
"_enabled": true,
"_normalMaterial": null,
...
...
@@ -5143,7 +4065,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
95
"__id__":
74
},
"_enabled": true,
"_materials": [
...
...
@@ -5181,7 +4103,7 @@
"_active": true,
"_components": [
{
"__id__":
105
"__id__":
84
}
],
"_prefab": null,
...
...
@@ -5237,7 +4159,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
104
"__id__":
83
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -5268,16 +4190,16 @@
},
"_children": [
{
"__id__":
107
"__id__":
86
},
{
"__id__":
110
"__id__":
89
}
],
"_active": false,
"_components": [
{
"__id__":
112
"__id__":
91
}
],
"_prefab": null,
...
...
@@ -5333,16 +4255,16 @@
"_name": "New Sprite(Splash)",
"_objFlags": 0,
"_parent": {
"__id__":
106
"__id__":
85
},
"_children": [],
"_active": true,
"_components": [
{
"__id__":
108
"__id__":
87
},
{
"__id__":
109
"__id__":
88
}
],
"_prefab": null,
...
...
@@ -5398,7 +4320,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
107
"__id__":
86
},
"_enabled": true,
"_materials": [
...
...
@@ -5430,7 +4352,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
107
"__id__":
86
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -5457,13 +4379,13 @@
"_name": "bg_good-job2",
"_objFlags": 0,
"_parent": {
"__id__":
106
"__id__":
85
},
"_children": [],
"_active": true,
"_components": [
{
"__id__":
111
"__id__":
90
}
],
"_prefab": null,
...
...
@@ -5519,7 +4441,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
110
"__id__":
89
},
"_enabled": true,
"_materials": [
...
...
@@ -5551,7 +4473,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
106
"__id__":
85
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -5582,19 +4504,19 @@
},
"_children": [
{
"__id__":
114
"__id__":
93
},
{
"__id__":
117
"__id__":
96
}
],
"_active": true,
"_components": [
{
"__id__":
120
"__id__":
99
},
{
"__id__": 1
21
"__id__": 1
00
}
],
"_prefab": null,
...
...
@@ -5650,16 +4572,16 @@
"_name": "bar",
"_objFlags": 512,
"_parent": {
"__id__":
113
"__id__":
92
},
"_children": [],
"_active": true,
"_components": [
{
"__id__":
115
"__id__":
94
},
{
"__id__":
116
"__id__":
95
}
],
"_prefab": null,
...
...
@@ -5715,7 +4637,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
114
"__id__":
93
},
"_enabled": true,
"_materials": [
...
...
@@ -5747,7 +4669,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
114
"__id__":
93
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -5774,16 +4696,16 @@
"_name": "pro_label",
"_objFlags": 0,
"_parent": {
"__id__":
113
"__id__":
92
},
"_children": [],
"_active": true,
"_components": [
{
"__id__":
118
"__id__":
97
},
{
"__id__":
119
"__id__":
98
}
],
"_prefab": null,
...
...
@@ -5839,7 +4761,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
117
"__id__":
96
},
"_enabled": true,
"_materials": [
...
...
@@ -5872,7 +4794,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
117
"__id__":
96
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -5899,7 +4821,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
113
"__id__":
92
},
"_enabled": true,
"_materials": [
...
...
@@ -5931,12 +4853,12 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
113
"__id__":
92
},
"_enabled": true,
"_N$totalLength": 540,
"_N$barSprite": {
"__id__":
115
"__id__":
94
},
"_N$mode": 0,
"_N$progress": 0,
...
...
@@ -6002,7 +4924,7 @@
"__id__": 67
},
"nor_label": {
"__id__":
92
"__id__":
71
},
"op_item": {
"__id__": 28
...
...
@@ -6011,13 +4933,13 @@
"__id__": 60
},
"tips": {
"__id__":
95
"__id__":
74
},
"progressBar": {
"__id__":
113
"__id__":
92
},
"goodJob": {
"__id__":
106
"__id__":
85
},
"_id": "c7RS18039BKJE5rgl8xIoE"
}
...
...
assets/op_input/scene/op_input.ts
View file @
85ea6811
...
...
@@ -259,9 +259,8 @@ export default class PuzzleJigsaw extends MyCocosSceneComponent {
itemBg
.
errorCount
++
;
if
(
itemBg
.
errorCount
>=
3
)
{
this
.
errorThere
(
target
,
itemBg
);
this
.
playLocalAudio
(
"
right
"
).
then
(()
=>
{
this
.
roundOver
();
});
this
.
playLocalAudio
(
"
right
"
);
this
.
roundOver
();
}
else
{
this
.
playLocalAudio
(
"
error
"
);
this
.
moveError
(
target
,
data
);
...
...
@@ -277,9 +276,8 @@ export default class PuzzleJigsaw extends MyCocosSceneComponent {
let
line
=
cc
.
find
(
"
line
"
,
item
);
word
.
active
=
true
;
line
.
active
=
false
;
this
.
playLocalAudio
(
"
right
"
).
then
(()
=>
{
this
.
roundOver
();
});
this
.
playLocalAudio
(
"
right
"
);
this
.
roundOver
();
}
private
moveError
(
target
,
data
)
{
this
.
op_layout
.
children
.
forEach
((
item
)
=>
{
...
...
@@ -313,29 +311,33 @@ export default class PuzzleJigsaw extends MyCocosSceneComponent {
}
private
roundOver
()
{
if
(
this
.
checkRoundOver
())
{
this
.
word_layout
.
active
=
false
;
this
.
word_layout
.
removeAllChildren
();
cc
.
tween
(
this
.
nor_label
).
to
(
0.1
,
{
opacity
:
255
}).
start
();
let
data
=
Game
.
getIns
().
getCurrentPage
();
pg
.
audio
.
playAudioByUrl
(
data
.
wordAudio
).
then
(()
=>
{
let
pro
=
this
.
progressBar
.
getComponent
(
cc
.
ProgressBar
);
let
p
=
Game
.
getIns
().
page
/
Game
.
getIns
().
getTotalPageNum
();
cc
.
tween
(
pro
).
to
(
1
,
{
progress
:
p
}).
delay
(
1
).
call
(()
=>
{
let
add
=
Game
.
getIns
().
addPage
();
if
(
add
)
{
this
.
nextPage
()
}
else
{
if
(
Game
.
getIns
().
roundCount
==
1
)
{
Game
.
getIns
().
roundCount
=
2
;
Game
.
getIns
().
page
=
1
;
this
.
startGame
();
}
else
{
this
.
goodJob
.
active
=
true
;
this
.
gameOver
();
}
}
cc
.
tween
(
this
.
nor_label
)
.
delay
(
0.5
).
call
(()
=>
{
this
.
word_layout
.
active
=
false
;
this
.
word_layout
.
removeAllChildren
();
})
.
to
(
0.1
,
{
opacity
:
255
}).
delay
(
0.5
).
call
(()
=>
{
let
data
=
Game
.
getIns
().
getCurrentPage
();
pg
.
audio
.
playAudioByUrl
(
data
.
wordAudio
).
then
(()
=>
{
let
pro
=
this
.
progressBar
.
getComponent
(
cc
.
ProgressBar
);
let
p
=
Game
.
getIns
().
page
/
Game
.
getIns
().
getTotalPageNum
();
cc
.
tween
(
pro
).
to
(
1
,
{
progress
:
p
}).
delay
(
1
).
call
(()
=>
{
let
add
=
Game
.
getIns
().
addPage
();
if
(
add
)
{
this
.
nextPage
()
}
else
{
if
(
Game
.
getIns
().
roundCount
==
1
)
{
Game
.
getIns
().
roundCount
=
2
;
Game
.
getIns
().
page
=
1
;
this
.
startGame
();
}
else
{
this
.
goodJob
.
active
=
true
;
this
.
gameOver
();
}
}
}).
start
();
})
}).
start
();
})
}
}
private
checkRoundOver
()
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment