Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
Coloring
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
Coloring
Commits
c32115d9
Commit
c32115d9
authored
Mar 23, 2022
by
张世斌
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.修复bug
parent
9a5658eb
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
476 additions
and
372 deletions
+476
-372
Coloring.fire
assets/Coloring/scene/Coloring.fire
+373
-283
MenuController.ts
assets/Coloring/script/Game/MenuController.ts
+55
-39
MenuModel.ts
assets/Coloring/script/Game/MenuModel.ts
+6
-6
MenuView.ts
assets/Coloring/script/Game/MenuView.ts
+23
-25
defaultData.js
assets/Coloring/script/defaultData.js
+19
-19
No files found.
assets/Coloring/scene/Coloring.fire
View file @
c32115d9
...
...
@@ -17,10 +17,10 @@
"__id__": 2
},
{
"__id__": 16
3
"__id__": 16
5
},
{
"__id__":
199
"__id__":
201
}
],
"_active": false,
...
...
@@ -81,25 +81,25 @@
"__id__": 5
},
{
"__id__": 1
49
"__id__": 1
51
},
{
"__id__": 15
7
"__id__": 15
9
}
],
"_active": true,
"_components": [
{
"__id__": 1
59
"__id__": 1
61
},
{
"__id__": 16
0
"__id__": 16
2
},
{
"__id__": 16
1
"__id__": 16
3
},
{
"__id__": 16
2
"__id__": 16
4
}
],
"_prefab": null,
...
...
@@ -272,25 +272,25 @@
"__id__": 67
},
{
"__id__": 7
3
"__id__": 7
6
},
{
"__id__": 8
4
"__id__": 8
6
},
{
"__id__": 9
6
"__id__": 9
8
},
{
"__id__": 1
38
"__id__": 1
40
}
],
"_active": true,
"_components": [
{
"__id__": 14
7
"__id__": 14
9
},
{
"__id__": 1
48
"__id__": 1
50
}
],
"_prefab": null,
...
...
@@ -3607,15 +3607,18 @@
"_children": [
{
"__id__": 68
},
{
"__id__": 71
}
],
"_active": false,
"_components": [
{
"__id__": 7
1
"__id__": 7
4
},
{
"__id__": 7
2
"__id__": 7
5
}
],
"_prefab": null,
...
...
@@ -3788,6 +3791,128 @@
"_originalHeight": 0,
"_id": "90EvF+rN5AHalyDyzIhte0"
},
{
"__type__": "cc.Node",
"_name": "bg_img",
"_objFlags": 512,
"_parent": {
"__id__": 67
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 72
},
{
"__id__": 73
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 1407,
"height": 731
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
-80,
0,
0,
0,
0,
1,
1.19,
1.19,
1.19
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "bc0WQq7JVI3Z03cj1OIsin"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 71
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": null,
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "70fuUf8ypJYJHKGczdvzYb"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 71
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 18,
"_left": 0,
"_right": 0,
"_top": 0,
"_bottom": 194.5,
"_verticalCenter": -80,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 0,
"_originalHeight": 0,
"_id": "0chxCAWjRKf6KZSCkZjaMl"
},
{
"__type__": "cc.Sprite",
"_name": "",
...
...
@@ -3856,13 +3981,13 @@
},
"_children": [
{
"__id__": 7
4
"__id__": 7
7
}
],
"_active": true,
"_components": [
{
"__id__": 8
3
"__id__": 8
5
}
],
"_prefab": null,
...
...
@@ -3918,23 +4043,23 @@
"_name": "paint",
"_objFlags": 512,
"_parent": {
"__id__": 7
3
"__id__": 7
6
},
"_children": [
{
"__id__": 7
5
"__id__": 7
8
},
{
"__id__":
78
"__id__":
80
}
],
"_active": true,
"_components": [
{
"__id__": 8
1
"__id__": 8
3
},
{
"__id__": 8
2
"__id__": 8
4
}
],
"_prefab": null,
...
...
@@ -3990,16 +4115,13 @@
"_name": "alligator",
"_objFlags": 512,
"_parent": {
"__id__": 7
4
"__id__": 7
7
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 76
},
{
"__id__": 77
"__id__": 79
}
],
"_prefab": null,
...
...
@@ -4055,7 +4177,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 7
5
"__id__": 7
8
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -4077,51 +4199,21 @@
"_originalHeight": 0,
"_id": "7e4UiOhhxEhLc7kaVxienp"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 75
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 1,
"_dstBlendFactor": 771,
"_spriteFrame": null,
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "efDuRxyZRCM4jn9HpjoAHw"
},
{
"__type__": "cc.Node",
"_name": "bg_img",
"_objFlags": 512,
"_parent": {
"__id__": 7
4
"__id__": 7
7
},
"_children": [],
"_active":
fals
e,
"_active":
tru
e,
"_components": [
{
"__id__":
79
"__id__":
81
},
{
"__id__": 8
0
"__id__": 8
2
}
],
"_prefab": null,
...
...
@@ -4135,8 +4227,8 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width": 1
407
,
"height":
731
"width": 1
305
,
"height":
635
},
"_anchorPoint": {
"__type__": "cc.Vec2",
...
...
@@ -4177,7 +4269,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
78
"__id__":
80
},
"_enabled": true,
"_materials": [
...
...
@@ -4185,11 +4277,9 @@
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor":
1
,
"_srcBlendFactor":
770
,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "96c0dd06-35f7-44c6-bcf9-85e895eb711e"
},
"_spriteFrame": null,
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
...
...
@@ -4209,7 +4299,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
78
"__id__":
80
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -4236,7 +4326,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 7
4
"__id__": 7
7
},
"_enabled": true,
"_materials": [
...
...
@@ -4268,7 +4358,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 7
4
"__id__": 7
7
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -4295,7 +4385,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 7
3
"__id__": 7
6
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -4326,19 +4416,19 @@
},
"_children": [
{
"__id__": 8
5
"__id__": 8
7
},
{
"__id__":
89
"__id__":
91
},
{
"__id__": 9
2
"__id__": 9
4
}
],
"_active": true,
"_components": [
{
"__id__": 9
5
"__id__": 9
7
}
],
"_prefab": null,
...
...
@@ -4394,19 +4484,19 @@
"_name": "btn_submit",
"_objFlags": 0,
"_parent": {
"__id__": 8
4
"__id__": 8
6
},
"_children": [],
"_active": false,
"_components": [
{
"__id__": 8
6
"__id__": 8
8
},
{
"__id__": 8
7
"__id__": 8
9
},
{
"__id__":
88
"__id__":
90
}
],
"_prefab": null,
...
...
@@ -4462,7 +4552,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 8
5
"__id__": 8
7
},
"_enabled": true,
"_materials": [
...
...
@@ -4494,7 +4584,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 8
5
"__id__": 8
7
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -4521,7 +4611,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 8
5
"__id__": 8
7
},
"_enabled": true,
"_normalMaterial": null,
...
...
@@ -4589,16 +4679,16 @@
"_name": "coolcat",
"_objFlags": 0,
"_parent": {
"__id__": 8
4
"__id__": 8
6
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 9
0
"__id__": 9
2
},
{
"__id__": 9
1
"__id__": 9
3
}
],
"_prefab": null,
...
...
@@ -4654,7 +4744,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
89
"__id__":
91
},
"_enabled": true,
"_materials": [
...
...
@@ -4694,7 +4784,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
89
"__id__":
91
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -4721,16 +4811,16 @@
"_name": "BtnCoolCat",
"_objFlags": 0,
"_parent": {
"__id__": 8
4
"__id__": 8
6
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 9
3
"__id__": 9
5
},
{
"__id__": 9
4
"__id__": 9
6
}
],
"_prefab": null,
...
...
@@ -4786,7 +4876,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 9
2
"__id__": 9
4
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -4813,7 +4903,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 9
2
"__id__": 9
4
},
"_enabled": true,
"_normalMaterial": null,
...
...
@@ -4881,7 +4971,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 8
4
"__id__": 8
6
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -4912,13 +5002,13 @@
},
"_children": [
{
"__id__": 9
7
"__id__": 9
9
}
],
"_active": false,
"_components": [
{
"__id__": 13
7
"__id__": 13
9
}
],
"_prefab": null,
...
...
@@ -4974,23 +5064,23 @@
"_name": "paint",
"_objFlags": 512,
"_parent": {
"__id__": 9
6
"__id__": 9
8
},
"_children": [
{
"__id__":
98
"__id__":
100
},
{
"__id__": 13
2
"__id__": 13
4
}
],
"_active": true,
"_components": [
{
"__id__": 13
5
"__id__": 13
7
},
{
"__id__": 13
6
"__id__": 13
8
}
],
"_prefab": null,
...
...
@@ -5046,38 +5136,38 @@
"_name": "alligator",
"_objFlags": 512,
"_parent": {
"__id__": 9
7
"__id__": 9
9
},
"_children": [
{
"__id__":
99
"__id__":
101
},
{
"__id__": 10
3
"__id__": 10
5
},
{
"__id__": 10
7
"__id__": 10
9
},
{
"__id__": 11
1
"__id__": 11
3
},
{
"__id__": 11
5
"__id__": 11
7
},
{
"__id__": 1
19
"__id__": 1
21
},
{
"__id__": 12
3
"__id__": 12
5
},
{
"__id__": 12
7
"__id__": 12
9
}
],
"_active": true,
"_components": [
{
"__id__": 13
1
"__id__": 13
3
}
],
"_prefab": null,
...
...
@@ -5133,17 +5223,17 @@
"_name": "t2",
"_objFlags": 0,
"_parent": {
"__id__":
98
"__id__":
100
},
"_children": [
{
"__id__": 10
0
"__id__": 10
2
}
],
"_active": true,
"_components": [
{
"__id__": 10
2
"__id__": 10
4
}
],
"_prefab": null,
...
...
@@ -5199,13 +5289,13 @@
"_name": "word",
"_objFlags": 0,
"_parent": {
"__id__":
99
"__id__":
101
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 10
1
"__id__": 10
3
}
],
"_prefab": null,
...
...
@@ -5261,7 +5351,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 10
0
"__id__": 10
2
},
"_enabled": true,
"_materials": [
...
...
@@ -5296,7 +5386,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
99
"__id__":
101
},
"_enabled": true,
"_materials": [
...
...
@@ -5328,17 +5418,17 @@
"_name": "t3",
"_objFlags": 0,
"_parent": {
"__id__":
98
"__id__":
100
},
"_children": [
{
"__id__": 10
4
"__id__": 10
6
}
],
"_active": true,
"_components": [
{
"__id__": 10
6
"__id__": 10
8
}
],
"_prefab": null,
...
...
@@ -5394,13 +5484,13 @@
"_name": "word",
"_objFlags": 0,
"_parent": {
"__id__": 10
3
"__id__": 10
5
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 10
5
"__id__": 10
7
}
],
"_prefab": null,
...
...
@@ -5456,7 +5546,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 10
4
"__id__": 10
6
},
"_enabled": true,
"_materials": [
...
...
@@ -5491,7 +5581,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 10
3
"__id__": 10
5
},
"_enabled": true,
"_materials": [
...
...
@@ -5523,17 +5613,17 @@
"_name": "t4",
"_objFlags": 0,
"_parent": {
"__id__":
98
"__id__":
100
},
"_children": [
{
"__id__": 1
08
"__id__": 1
10
}
],
"_active": true,
"_components": [
{
"__id__": 11
0
"__id__": 11
2
}
],
"_prefab": null,
...
...
@@ -5589,13 +5679,13 @@
"_name": "word",
"_objFlags": 0,
"_parent": {
"__id__": 10
7
"__id__": 10
9
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 1
09
"__id__": 1
11
}
],
"_prefab": null,
...
...
@@ -5651,7 +5741,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
08
"__id__": 1
10
},
"_enabled": true,
"_materials": [
...
...
@@ -5686,7 +5776,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 10
7
"__id__": 10
9
},
"_enabled": true,
"_materials": [
...
...
@@ -5718,17 +5808,17 @@
"_name": "t5",
"_objFlags": 0,
"_parent": {
"__id__":
98
"__id__":
100
},
"_children": [
{
"__id__": 11
2
"__id__": 11
4
}
],
"_active": true,
"_components": [
{
"__id__": 11
4
"__id__": 11
6
}
],
"_prefab": null,
...
...
@@ -5784,13 +5874,13 @@
"_name": "word",
"_objFlags": 0,
"_parent": {
"__id__": 11
1
"__id__": 11
3
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 11
3
"__id__": 11
5
}
],
"_prefab": null,
...
...
@@ -5846,7 +5936,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 11
2
"__id__": 11
4
},
"_enabled": true,
"_materials": [
...
...
@@ -5881,7 +5971,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 11
1
"__id__": 11
3
},
"_enabled": true,
"_materials": [
...
...
@@ -5913,17 +6003,17 @@
"_name": "t6",
"_objFlags": 0,
"_parent": {
"__id__":
98
"__id__":
100
},
"_children": [
{
"__id__": 11
6
"__id__": 11
8
}
],
"_active": true,
"_components": [
{
"__id__": 1
18
"__id__": 1
20
}
],
"_prefab": null,
...
...
@@ -5979,13 +6069,13 @@
"_name": "word",
"_objFlags": 0,
"_parent": {
"__id__": 11
5
"__id__": 11
7
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 11
7
"__id__": 11
9
}
],
"_prefab": null,
...
...
@@ -6041,7 +6131,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 11
6
"__id__": 11
8
},
"_enabled": true,
"_materials": [
...
...
@@ -6076,7 +6166,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 11
5
"__id__": 11
7
},
"_enabled": true,
"_materials": [
...
...
@@ -6108,17 +6198,17 @@
"_name": "t7",
"_objFlags": 0,
"_parent": {
"__id__":
98
"__id__":
100
},
"_children": [
{
"__id__": 12
0
"__id__": 12
2
}
],
"_active": true,
"_components": [
{
"__id__": 12
2
"__id__": 12
4
}
],
"_prefab": null,
...
...
@@ -6174,13 +6264,13 @@
"_name": "word",
"_objFlags": 0,
"_parent": {
"__id__": 1
19
"__id__": 1
21
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 12
1
"__id__": 12
3
}
],
"_prefab": null,
...
...
@@ -6236,7 +6326,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 12
0
"__id__": 12
2
},
"_enabled": true,
"_materials": [
...
...
@@ -6271,7 +6361,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
19
"__id__": 1
21
},
"_enabled": true,
"_materials": [
...
...
@@ -6303,17 +6393,17 @@
"_name": "t8",
"_objFlags": 0,
"_parent": {
"__id__":
98
"__id__":
100
},
"_children": [
{
"__id__": 12
4
"__id__": 12
6
}
],
"_active": true,
"_components": [
{
"__id__": 12
6
"__id__": 12
8
}
],
"_prefab": null,
...
...
@@ -6369,13 +6459,13 @@
"_name": "word",
"_objFlags": 0,
"_parent": {
"__id__": 12
3
"__id__": 12
5
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 12
5
"__id__": 12
7
}
],
"_prefab": null,
...
...
@@ -6431,7 +6521,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 12
4
"__id__": 12
6
},
"_enabled": true,
"_materials": [
...
...
@@ -6466,7 +6556,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 12
3
"__id__": 12
5
},
"_enabled": true,
"_materials": [
...
...
@@ -6498,17 +6588,17 @@
"_name": "t9",
"_objFlags": 0,
"_parent": {
"__id__":
98
"__id__":
100
},
"_children": [
{
"__id__": 1
28
"__id__": 1
30
}
],
"_active": true,
"_components": [
{
"__id__": 13
0
"__id__": 13
2
}
],
"_prefab": null,
...
...
@@ -6564,13 +6654,13 @@
"_name": "word",
"_objFlags": 0,
"_parent": {
"__id__": 12
7
"__id__": 12
9
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 1
29
"__id__": 1
31
}
],
"_prefab": null,
...
...
@@ -6626,7 +6716,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
28
"__id__": 1
30
},
"_enabled": true,
"_materials": [
...
...
@@ -6661,7 +6751,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 12
7
"__id__": 12
9
},
"_enabled": true,
"_materials": [
...
...
@@ -6693,7 +6783,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
98
"__id__":
100
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -6720,16 +6810,16 @@
"_name": "alligator_img",
"_objFlags": 512,
"_parent": {
"__id__": 9
7
"__id__": 9
9
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 13
3
"__id__": 13
5
},
{
"__id__": 13
4
"__id__": 13
6
}
],
"_prefab": null,
...
...
@@ -6785,7 +6875,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 13
2
"__id__": 13
4
},
"_enabled": true,
"_materials": [
...
...
@@ -6817,7 +6907,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 13
2
"__id__": 13
4
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -6844,7 +6934,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 9
7
"__id__": 9
9
},
"_enabled": true,
"_materials": [
...
...
@@ -6874,7 +6964,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 9
7
"__id__": 9
9
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -6901,7 +6991,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 9
6
"__id__": 9
8
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -6931,23 +7021,23 @@
"__id__": 5
},
"_children": [
{
"__id__": 139
},
{
"__id__": 141
},
{
"__id__": 143
},
{
"__id__": 145
}
],
"_active": false,
"_components": [
{
"__id__": 14
5
"__id__": 14
7
},
{
"__id__": 14
6
"__id__": 14
8
}
],
"_prefab": null,
...
...
@@ -7003,13 +7093,13 @@
"_name": "bg_circle2",
"_objFlags": 0,
"_parent": {
"__id__": 1
38
"__id__": 1
40
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 14
0
"__id__": 14
2
}
],
"_prefab": null,
...
...
@@ -7065,7 +7155,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
39
"__id__": 1
41
},
"_enabled": true,
"_materials": [
...
...
@@ -7097,13 +7187,13 @@
"_name": "bg_circle",
"_objFlags": 0,
"_parent": {
"__id__": 1
38
"__id__": 1
40
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 14
2
"__id__": 14
4
}
],
"_prefab": null,
...
...
@@ -7159,7 +7249,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 14
1
"__id__": 14
3
},
"_enabled": true,
"_materials": [
...
...
@@ -7191,13 +7281,13 @@
"_name": "btn_replay",
"_objFlags": 0,
"_parent": {
"__id__": 1
38
"__id__": 1
40
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 14
4
"__id__": 14
6
}
],
"_prefab": null,
...
...
@@ -7253,7 +7343,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 14
3
"__id__": 14
5
},
"_enabled": true,
"_materials": [
...
...
@@ -7285,7 +7375,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
38
"__id__": 1
40
},
"_enabled": true,
"_materials": [
...
...
@@ -7317,7 +7407,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
38
"__id__": 1
40
},
"_enabled": true,
"_normalMaterial": null,
...
...
@@ -7448,19 +7538,19 @@
},
"_children": [
{
"__id__": 15
0
"__id__": 15
2
},
{
"__id__": 15
3
"__id__": 15
5
}
],
"_active": false,
"_components": [
{
"__id__": 15
5
"__id__": 15
7
},
{
"__id__": 15
6
"__id__": 15
8
}
],
"_prefab": null,
...
...
@@ -7516,16 +7606,16 @@
"_name": "start_bg",
"_objFlags": 0,
"_parent": {
"__id__": 1
49
"__id__": 1
51
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 15
1
"__id__": 15
3
},
{
"__id__": 15
2
"__id__": 15
4
}
],
"_prefab": null,
...
...
@@ -7581,7 +7671,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 15
0
"__id__": 15
2
},
"_enabled": true,
"_materials": [
...
...
@@ -7613,7 +7703,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 15
0
"__id__": 15
2
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -7640,13 +7730,13 @@
"_name": "start",
"_objFlags": 0,
"_parent": {
"__id__": 1
49
"__id__": 1
51
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 15
4
"__id__": 15
6
}
],
"_prefab": null,
...
...
@@ -7702,7 +7792,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 15
3
"__id__": 15
5
},
"_enabled": true,
"_materials": [
...
...
@@ -7734,7 +7824,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
49
"__id__": 1
51
},
"_enabled": true,
"_normalMaterial": null,
...
...
@@ -7795,7 +7885,7 @@
"hoverSprite": null,
"_N$disabledSprite": null,
"_N$target": {
"__id__": 1
49
"__id__": 1
51
},
"_id": "dcCiAjNMREj6CcPYJOxYXZ"
},
...
...
@@ -7804,7 +7894,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
49
"__id__": 1
51
},
"_enabled": true,
"alignMode": 1,
...
...
@@ -7837,7 +7927,7 @@
"_active": false,
"_components": [
{
"__id__": 1
58
"__id__": 1
60
}
],
"_prefab": null,
...
...
@@ -7893,7 +7983,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 15
7
"__id__": 15
9
},
"_enabled": true,
"_cullingMask": 2,
...
...
@@ -7977,7 +8067,7 @@
},
"_enabled": false,
"paint": {
"__id__": 7
4
"__id__": 7
7
},
"paint2": {
"__id__": 67
...
...
@@ -7989,10 +8079,10 @@
"__id__": 15
},
"coolcat": {
"__id__":
89
"__id__":
91
},
"btn_submit": {
"__id__":
88
"__id__":
90
},
"btn_next": {
"__id__": 13
...
...
@@ -8068,13 +8158,13 @@
},
"_children": [
{
"__id__": 16
4
"__id__": 16
6
},
{
"__id__": 17
7
"__id__": 17
9
},
{
"__id__": 19
6
"__id__": 19
8
}
],
"_active": true,
...
...
@@ -8132,12 +8222,9 @@
"_name": "img",
"_objFlags": 0,
"_parent": {
"__id__": 163
},
"_children": [
{
"__id__": 165
},
"_children": [
{
"__id__": 167
},
...
...
@@ -8152,6 +8239,9 @@
},
{
"__id__": 175
},
{
"__id__": 177
}
],
"_active": false,
...
...
@@ -8209,13 +8299,13 @@
"_name": "time_strip",
"_objFlags": 0,
"_parent": {
"__id__": 16
4
"__id__": 16
6
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 16
6
"__id__": 16
8
}
],
"_prefab": null,
...
...
@@ -8271,7 +8361,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 16
5
"__id__": 16
7
},
"_enabled": true,
"_materials": [],
...
...
@@ -8297,13 +8387,13 @@
"_name": "time_strip_bg",
"_objFlags": 0,
"_parent": {
"__id__": 16
4
"__id__": 16
6
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 1
68
"__id__": 1
70
}
],
"_prefab": null,
...
...
@@ -8359,7 +8449,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 16
7
"__id__": 16
9
},
"_enabled": true,
"_materials": [],
...
...
@@ -8385,13 +8475,13 @@
"_name": "online_bg",
"_objFlags": 0,
"_parent": {
"__id__": 16
4
"__id__": 16
6
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 17
0
"__id__": 17
2
}
],
"_prefab": null,
...
...
@@ -8447,7 +8537,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
69
"__id__": 1
71
},
"_enabled": true,
"_materials": [
...
...
@@ -8477,13 +8567,13 @@
"_name": "smiling_face",
"_objFlags": 0,
"_parent": {
"__id__": 16
4
"__id__": 16
6
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 17
2
"__id__": 17
4
}
],
"_prefab": null,
...
...
@@ -8539,7 +8629,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 17
1
"__id__": 17
3
},
"_enabled": true,
"_materials": [],
...
...
@@ -8565,13 +8655,13 @@
"_name": "star",
"_objFlags": 0,
"_parent": {
"__id__": 16
4
"__id__": 16
6
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 17
4
"__id__": 17
6
}
],
"_prefab": null,
...
...
@@ -8627,7 +8717,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 17
3
"__id__": 17
5
},
"_enabled": true,
"_materials": [],
...
...
@@ -8653,13 +8743,13 @@
"_name": "me",
"_objFlags": 0,
"_parent": {
"__id__": 16
4
"__id__": 16
6
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 17
6
"__id__": 17
8
}
],
"_prefab": null,
...
...
@@ -8715,7 +8805,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 17
5
"__id__": 17
7
},
"_enabled": true,
"_materials": [],
...
...
@@ -8741,12 +8831,9 @@
"_name": "audio",
"_objFlags": 0,
"_parent": {
"__id__": 16
3
"__id__": 16
5
},
"_children": [
{
"__id__": 178
},
{
"__id__": 180
},
...
...
@@ -8770,6 +8857,9 @@
},
{
"__id__": 194
},
{
"__id__": 196
}
],
"_active": true,
...
...
@@ -8827,13 +8917,13 @@
"_name": "button",
"_objFlags": 0,
"_parent": {
"__id__": 17
7
"__id__": 17
9
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 1
79
"__id__": 1
81
}
],
"_prefab": null,
...
...
@@ -8889,7 +8979,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
78
"__id__": 1
80
},
"_enabled": true,
"_clip": {
...
...
@@ -8908,13 +8998,13 @@
"_name": "finish",
"_objFlags": 0,
"_parent": {
"__id__": 17
7
"__id__": 17
9
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 18
1
"__id__": 18
3
}
],
"_prefab": null,
...
...
@@ -8970,7 +9060,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 18
0
"__id__": 18
2
},
"_enabled": true,
"_clip": {
...
...
@@ -8989,13 +9079,13 @@
"_name": "click",
"_objFlags": 0,
"_parent": {
"__id__": 17
7
"__id__": 17
9
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 18
3
"__id__": 18
5
}
],
"_prefab": null,
...
...
@@ -9051,7 +9141,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 18
2
"__id__": 18
4
},
"_enabled": true,
"_clip": {
...
...
@@ -9070,13 +9160,13 @@
"_name": "correct",
"_objFlags": 0,
"_parent": {
"__id__": 17
7
"__id__": 17
9
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 18
5
"__id__": 18
7
}
],
"_prefab": null,
...
...
@@ -9132,7 +9222,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 18
4
"__id__": 18
6
},
"_enabled": true,
"_clip": {
...
...
@@ -9151,13 +9241,13 @@
"_name": "incorrect",
"_objFlags": 0,
"_parent": {
"__id__": 17
7
"__id__": 17
9
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 18
7
"__id__": 18
9
}
],
"_prefab": null,
...
...
@@ -9213,7 +9303,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 18
6
"__id__": 18
8
},
"_enabled": true,
"_clip": {
...
...
@@ -9232,13 +9322,13 @@
"_name": "lack",
"_objFlags": 0,
"_parent": {
"__id__": 17
7
"__id__": 17
9
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 1
89
"__id__": 1
91
}
],
"_prefab": null,
...
...
@@ -9294,7 +9384,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
88
"__id__": 1
90
},
"_enabled": true,
"_clip": {
...
...
@@ -9313,13 +9403,13 @@
"_name": "painted",
"_objFlags": 0,
"_parent": {
"__id__": 17
7
"__id__": 17
9
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 19
1
"__id__": 19
3
}
],
"_prefab": null,
...
...
@@ -9375,7 +9465,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 19
0
"__id__": 19
2
},
"_enabled": true,
"_clip": {
...
...
@@ -9394,13 +9484,13 @@
"_name": "demo",
"_objFlags": 0,
"_parent": {
"__id__": 17
7
"__id__": 17
9
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 19
3
"__id__": 19
5
}
],
"_prefab": null,
...
...
@@ -9456,7 +9546,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 19
2
"__id__": 19
4
},
"_enabled": true,
"_clip": {
...
...
@@ -9475,13 +9565,13 @@
"_name": "star",
"_objFlags": 0,
"_parent": {
"__id__": 17
7
"__id__": 17
9
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 19
5
"__id__": 19
7
}
],
"_prefab": null,
...
...
@@ -9537,7 +9627,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 19
4
"__id__": 19
6
},
"_enabled": true,
"_clip": null,
...
...
@@ -9554,11 +9644,11 @@
"_name": "font",
"_objFlags": 0,
"_parent": {
"__id__": 16
3
"__id__": 16
5
},
"_children": [
{
"__id__": 19
7
"__id__": 19
9
}
],
"_active": false,
...
...
@@ -9616,13 +9706,13 @@
"_name": "MMTextBook-Bold",
"_objFlags": 0,
"_parent": {
"__id__": 19
6
"__id__": 19
8
},
"_children": [],
"_active": true,
"_components": [
{
"__id__":
198
"__id__":
200
}
],
"_prefab": null,
...
...
@@ -9678,7 +9768,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 19
7
"__id__": 19
9
},
"_enabled": true,
"_materials": [
...
...
@@ -9717,7 +9807,7 @@
},
"_children": [
{
"__id__": 20
0
"__id__": 20
2
}
],
"_active": false,
...
...
@@ -9775,17 +9865,17 @@
"_name": "Ff",
"_objFlags": 0,
"_parent": {
"__id__":
199
"__id__":
201
},
"_children": [
{
"__id__": 20
1
"__id__": 20
3
}
],
"_active": true,
"_components": [
{
"__id__": 20
3
"__id__": 20
5
}
],
"_prefab": null,
...
...
@@ -9841,13 +9931,13 @@
"_name": "New Label",
"_objFlags": 0,
"_parent": {
"__id__": 20
0
"__id__": 20
2
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 20
2
"__id__": 20
4
}
],
"_prefab": null,
...
...
@@ -9903,7 +9993,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 20
1
"__id__": 20
3
},
"_enabled": true,
"_materials": [
...
...
@@ -9938,7 +10028,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 20
0
"__id__": 20
2
},
"_enabled": true,
"_materials": [
...
...
assets/Coloring/script/Game/MenuController.ts
View file @
c32115d9
...
...
@@ -38,19 +38,19 @@ export default class MenuController extends Controller{
await
this
.
view
.
updateData
(
this
.
model
);
this
.
view
.
open
();
let
gameData
=
this
.
model
.
getItem
(
this
.
stageIdx
);
//
let gameData=this.model.getItem(this.stageIdx);
let
words
=
gameData
.
words
.
split
(
""
);
let
answers
=
gameData
.
answers
.
split
(
""
);
let
itemAudio
=
gameData
.
audio_url
;
//
let words=gameData.words.split("");
//
let answers=gameData.answers.split("");
//
let itemAudio=gameData.audio_url;
this
.
answers
=
new
Array
();
cc
.
log
(
words
);
cc
.
log
(
answers
);
//
cc.log(words);
//
cc.log(answers);
let
colorBlocks
=
this
.
view
.
colorItems1
;
for
(
let
i
=
0
;
i
<
colorBlocks
.
length
;
i
++
){
cc
.
log
(
colorBlocks
[
i
].
name
);
let
word
=
colorBlocks
[
i
].
getComponentInChildren
(
cc
.
Label
);
word
.
string
=
words
[
i
];
//
let word=colorBlocks[i].getComponentInChildren(cc.Label);
//
word.string=words[i];
colorBlocks
[
i
].
color
=
cc
.
Color
.
WHITE
;
// colorBlocks[i].getComponent(cc.Sprite).trim=true;
colorBlocks
[
i
].
on
(
cc
.
Node
.
EventType
.
TOUCH_START
,()
=>
{
...
...
@@ -62,30 +62,46 @@ export default class MenuController extends Controller{
{
return
;
}
// this.onClickBlock(i,answers);
let
result
=
answers
.
findIndex
((
item
)
=>
{
return
item
==
i
.
toString
();
});
cc
.
log
(
"
i:
"
+
i
+
"
,result:
"
+
result
)
if
(
result
==-
1
){
this
.
onWrong
();
}
else
{
this
.
answers
[
result
]
=
i
.
toString
();
this
.
answers
.
push
(
i
.
toString
());
let
color
=
new
cc
.
Color
();
color
.
fromHEX
(
this
.
colorCur
);
colorBlocks
[
i
].
color
=
color
;
// cc.Color.fromHEX(colorBlocks[i].color,+"#"+this.colorCur);
this
.
onRight
();
let
flag
=
0
;
for
(
let
i
=
0
;
i
<
this
.
answers
.
length
;
i
++
){
if
(
this
.
answers
[
i
]
==
answers
[
i
]){
flag
++
;
}
}
(
flag
>=
answers
.
length
)
&&
this
.
finish
();
}
// let flag=0;
// for(let i=0;i<this.answers.length;i++){
// if(this.answers[i]==answers[i]){
// flag++;
// }
// }
(
this
.
answers
.
length
>=
colorBlocks
.
length
)
&&
this
.
finish
();
// // this.onClickBlock(i,answers);
// let result=answers.findIndex((item)=>{
// return item==i.toString();
// });
// cc.log("i:"+i+",result:"+result)
// if(result==-1){
// this.onWrong();
// }
// else{
// this.answers[result]=i.toString();
// let color=new cc.Color();
// color.fromHEX(this.colorCur);
// colorBlocks[i].color=color;
// // cc.Color.fromHEX(colorBlocks[i].color,+"#"+this.colorCur);
// this.onRight();
// let flag=0;
// for(let i=0;i<this.answers.length;i++){
// if(this.answers[i]==answers[i]){
// flag++;
// }
// }
// (flag>=answers.length)&&this.finish();
// }
});
colorBlocks
[
i
].
_hitTest
=
this
.
_hitTest
.
bind
(
this
);
}
...
...
@@ -119,10 +135,10 @@ export default class MenuController extends Controller{
}
private
enter
(){
let
gameData
=
this
.
model
.
getItem
(
this
.
stageIdx
);
let
itemAudio
=
gameData
.
audio_url
;
AppFacade
.
getMgr
(
SoundMgr
).
playEffectByUrl
(
itemAudio
);
//
AppFacade.getMgr(SoundMgr).playEffectByUrl(this.model.getStartAudio());
//
let gameData=this.model.getItem(this.stageIdx);
//
let itemAudio=gameData.audio_url;
//
AppFacade.getMgr(SoundMgr).playEffectByUrl(itemAudio);
AppFacade
.
getMgr
(
SoundMgr
).
playEffectByUrl
(
this
.
model
.
getStartAudio
());
this
.
playDragonBoneAnimation
(
this
.
catAni
,
"
begin
"
,
1
,()
=>
{
this
.
playDragonBoneAnimation
(
this
.
catAni
,
"
normal
"
,
-
1
);
});
...
...
@@ -160,9 +176,9 @@ export default class MenuController extends Controller{
{
item
.
color
=
cc
.
Color
.
WHITE
}
let
w
=
item
.
getComponentInChildren
(
cc
.
Label
);
w
.
string
=
word
.
string
;
w
.
node
.
color
=
cc
.
Color
.
BLACK
;
//
let w=item.getComponentInChildren(cc.Label);
//
w.string=word.string;
//
w.node.color=cc.Color.BLACK;
}
}
...
...
assets/Coloring/script/Game/MenuModel.ts
View file @
c32115d9
...
...
@@ -50,13 +50,13 @@ export default class MenuModel extends Model{
return
this
.
data
;
}
public
getItems
(){
return
this
.
data
.
items
;
}
//
public getItems(){
//
return this.data.items;
//
}
public
getItem
(
idx
:
number
){
return
this
.
data
.
items
[
idx
];
}
//
public getItem(idx:number){
//
return this.data.items[idx];
//
}
public
getStartAudio
(){
return
this
.
data
.
startAudio
;
...
...
assets/Coloring/script/Game/MenuView.ts
View file @
c32115d9
...
...
@@ -66,8 +66,8 @@ export default class MenuView extends UIFullView{
protected
async
onUpdateData
(
model
:
MenuModel
){
let
images
:{
img
:
string
}[]
=
model
.
getImages
();
let
bg1
=
this
.
getChildComp
(
"
main_area/paint/
alligator
"
,
cc
.
Sprite
);
let
bg2
=
this
.
getChildComp
(
"
paint2/
alligator
"
,
cc
.
Sprite
);
let
bg1
=
this
.
getChildComp
(
"
main_area/paint/
bg_img
"
,
cc
.
Sprite
);
let
bg2
=
this
.
getChildComp
(
"
paint2/
bg_img
"
,
cc
.
Sprite
);
bg1
.
spriteFrame
=
await
UIUtil
.
getSpriteByUrl
(
model
.
getBG
());
bg2
.
spriteFrame
=
await
UIUtil
.
getSpriteByUrl
(
model
.
getBG
());
...
...
@@ -78,9 +78,9 @@ export default class MenuView extends UIFullView{
this
.
colorItems2
=
new
Array
();
let
colorArea2
=
this
.
paint2
;
let
gameData
=
model
.
getItem
(
model
.
stageIdx
);
let
words
=
gameData
.
words
.
split
(
""
);
let
pos
=
gameData
.
pos
;
//
let gameData=model.getItem(model.stageIdx);
//
let words=gameData.words.split("");
//
let pos=gameData.pos;
for
(
let
i
=
0
;
i
<
images
.
length
;
i
++
)
{
let
spriteFrame
=
await
UIUtil
.
getSpriteByUrl
({
url
:
images
[
i
].
img
})
...
...
@@ -89,32 +89,30 @@ export default class MenuView extends UIFullView{
item1
.
group
=
"
camera
"
;
let
sprite1
:
cc
.
Sprite
=
this
.
addCCComp
(
item1
,
cc
.
Sprite
);
sprite1
.
spriteFrame
=
spriteFrame
;
let
wordNode1
=
GameUtil
.
createNode
(
"
word
"
,
item1
);
wordNode1
.
x
=
pos
[
i
][
0
];
wordNode1
.
y
=
pos
[
i
][
1
];
wordNode1
.
color
=
cc
.
Color
.
BLACK
;
let
label1
:
cc
.
Label
=
this
.
addCCComp
(
wordNode1
,
cc
.
Label
);
label1
.
string
=
words
[
i
];
label1
.
font
=
model
.
getFont
();
label1
.
fontSize
=
80
;
label1
.
lineHeight
=
80
;
//
let wordNode1=GameUtil.createNode("word",item1);
//
wordNode1.x= pos[i][0];
//
wordNode1.y=pos[i][1];
//
wordNode1.color=cc.Color.BLACK;
//
let label1:cc.Label=this.addCCComp(wordNode1,cc.Label);
//
label1.string=words[i];
//
label1.font=model.getFont();
//
label1.fontSize=80;
//
label1.lineHeight=80;
this
.
colorItems1
[
i
]
=
sprite1
.
node
;
let
item2
=
GameUtil
.
createNode
(
"
img
"
+
1
,
colorArea2
);
item2
.
group
=
"
camera
"
let
sprite2
:
cc
.
Sprite
=
this
.
addCCComp
(
item2
,
cc
.
Sprite
);
sprite2
.
spriteFrame
=
spriteFrame
;
let
wordNode2
=
GameUtil
.
createNode
(
"
word
"
,
item2
);
wordNode2
.
anchorX
=
0
;
wordNode2
.
x
=
pos
[
i
][
0
];
wordNode2
.
y
=
pos
[
i
][
1
];
wordNode2
.
color
=
cc
.
Color
.
BLACK
;
let
label2
:
cc
.
Label
=
this
.
addCCComp
(
wordNode2
,
cc
.
Label
);
label2
.
string
=
words
[
i
];
label2
.
font
=
model
.
getFont
();
label2
.
fontSize
=
80
;
label2
.
lineHeight
=
80
;
// let wordNode2=GameUtil.createNode("word",item2);
// wordNode2.x=pos[i][0];
// wordNode2.y=pos[i][1];
// wordNode2.color=cc.Color.BLACK;
// let label2:cc.Label=this.addCCComp(wordNode2,cc.Label);
// label2.string=words[i];
// label2.font=model.getFont();
// label2.fontSize=80;
// label2.lineHeight=80;
this
.
colorItems2
[
i
]
=
sprite2
.
node
;
}
}
...
...
assets/Coloring/script/defaultData.js
View file @
c32115d9
export
const
defaultData
=
{
"
items
"
:
[
{
"
words
"
:
"
FdFFf
"
,
"
answers
"
:
"
0
234
"
,
"
audio_url
"
:
"
http://staging-teach.cdn.ireadabc.com/18bf8207ddea222c9b82c68f2549dadc.mp3
"
,
"
pos
"
:[
[
-
425.989
,
-
6.456
],
[
-
37.043
,
195.708
],
[
151.487
,
-
129.498
],
[
570.348
,
200
],
[
617.5
,
43.247
]
]
},
{
"
words
"
:
"
aAcBaCbA
"
,
"
answers
"
:
"
0147
"
,
"
audio_url
"
:
"
http://staging-teach.cdn.ireadabc.com/18bf8207ddea222c9b82c68f2549dadc.mp3
"
},
],
//
"items": [
//
{
//
"words": "FdFFf",
// "answers": "01
234",
//
"audio_url": "http://staging-teach.cdn.ireadabc.com/18bf8207ddea222c9b82c68f2549dadc.mp3",
//
"pos":[
//
[-425.989,-6.456],
//
[-37.043,195.708],
//
[151.487,-129.498],
//
[570.348,200],
//
[617.5,43.247]
//
]
//
},
//
{
//
"words": "aAcBaCbA",
//
"answers": "0147",
//
"audio_url": "http://staging-teach.cdn.ireadabc.com/18bf8207ddea222c9b82c68f2549dadc.mp3"
//
},
//
],
"
startAudio
"
:
"
http://staging-teach.cdn.ireadabc.com/18bf8207ddea222c9b82c68f2549dadc.mp3
"
,
"
waitAudio
"
:
"
http://staging-teach.cdn.ireadabc.com/46cba1330608d848239ec6a68bb4707e.mp3
"
,
"
finishAudio
"
:
"
http://staging-teach.cdn.ireadabc.com/b3260e3d6972cc59b345f573aaab4290.mp3
"
,
...
...
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