Commit 79069541 authored by 杨一航's avatar 杨一航

feat;

parent 41336c91
...@@ -78,19 +78,19 @@ ...@@ -78,19 +78,19 @@
"__id__": 7 "__id__": 7
}, },
{ {
"__id__": 28 "__id__": 46
} }
], ],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 38 "__id__": 56
}, },
{ {
"__id__": 39 "__id__": 57
}, },
{ {
"__id__": 40 "__id__": 58
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -363,13 +363,13 @@ ...@@ -363,13 +363,13 @@
"__id__": 21 "__id__": 21
}, },
{ {
"__id__": 23 "__id__": 31
} }
], ],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 27 "__id__": 45
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1045,11 +1045,21 @@ ...@@ -1045,11 +1045,21 @@
"_parent": { "_parent": {
"__id__": 7 "__id__": 7
}, },
"_children": [], "_children": [
{
"__id__": 22
},
{
"__id__": 24
}
],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 22 "__id__": 29
},
{
"__id__": 30
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1076,7 +1086,7 @@ ...@@ -1076,7 +1086,7 @@
"ctor": "Float64Array", "ctor": "Float64Array",
"array": [ "array": [
734.565, 734.565,
-511.184, -490,
0, 0,
0, 0,
0, 0,
...@@ -1101,56 +1111,70 @@ ...@@ -1101,56 +1111,70 @@
"_id": "abBbHm2BpLGb56/HklpYzi" "_id": "abBbHm2BpLGb56/HklpYzi"
}, },
{ {
"__type__": "cc.Sprite", "__type__": "cc.Node",
"_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "_parent": {
"__id__": 21 "__id__": 21
}, },
"_enabled": true, "_prefab": {
"_materials": [ "__id__": 23
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "d3c8433a-a4b7-4e9c-972d-eb205af0351f"
}, },
"_type": 0, "_name": "boy",
"_sizeMode": 1, "_active": true,
"_fillType": 0, "_trs": {
"_fillCenter": { "__type__": "TypedArray",
"__type__": "cc.Vec2", "ctor": "Float64Array",
"array": [
-8.378,
29.205,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0, "x": 0,
"y": 0 "y": 0,
"z": 0
}, },
"_fillStart": 0, "_id": "c29H8fcIZL15V3YfPJDkOG"
"_fillRange": 0, },
"_isTrimmedMode": true, {
"_atlas": null, "__type__": "cc.PrefabInfo",
"_id": "b2GJnUiJVLxIcRmxg/jGZb" "root": {
"__id__": 22
},
"asset": {
"__uuid__": "e2c60f31-0e99-4c0d-bf7c-6355dae2c724"
},
"fileId": "",
"sync": true
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "img_board", "_name": "btn_next",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 7 "__id__": 21
}, },
"_children": [ "_children": [
{ {
"__id__": 24 "__id__": 25
} }
], ],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 25 "__id__": 27
}, },
{ {
"__id__": 26 "__id__": 28
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1164,8 +1188,8 @@ ...@@ -1164,8 +1188,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 1348, "width": 257,
"height": 1051 "height": 166
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
...@@ -1176,8 +1200,8 @@ ...@@ -1176,8 +1200,8 @@
"__type__": "TypedArray", "__type__": "TypedArray",
"ctor": "Float64Array", "ctor": "Float64Array",
"array": [ "array": [
-266, -8.378,
-14.5, 631.616,
0, 0,
0, 0,
0, 0,
...@@ -1185,7 +1209,7 @@ ...@@ -1185,7 +1209,7 @@
1, 1,
1, 1,
1, 1,
1 0.5
] ]
}, },
"_eulerAngles": { "_eulerAngles": {
...@@ -1199,18 +1223,22 @@ ...@@ -1199,18 +1223,22 @@
"_is3DNode": false, "_is3DNode": false,
"_groupIndex": 0, "_groupIndex": 0,
"groupIndex": 0, "groupIndex": 0,
"_id": "e34qnEBq9NibGTDzCtlGd6" "_id": "bbh8nn+UZNJLjyR/Dr/WEK"
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "ImgRoot", "_name": "lb",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 23 "__id__": 24
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [], "_components": [
{
"__id__": 26
}
],
"_prefab": null, "_prefab": null,
"_opacity": 255, "_opacity": 255,
"_color": { "_color": {
...@@ -1222,8 +1250,8 @@ ...@@ -1222,8 +1250,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 1100, "width": 0,
"height": 660 "height": 50.4
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
...@@ -1234,8 +1262,8 @@ ...@@ -1234,8 +1262,8 @@
"__type__": "TypedArray", "__type__": "TypedArray",
"ctor": "Float64Array", "ctor": "Float64Array",
"array": [ "array": [
1.2739999999999991, 0,
16.726, 0,
0, 0,
0, 0,
0, 0,
...@@ -1257,14 +1285,47 @@ ...@@ -1257,14 +1285,47 @@
"_is3DNode": false, "_is3DNode": false,
"_groupIndex": 0, "_groupIndex": 0,
"groupIndex": 0, "groupIndex": 0,
"_id": "e4HWg+wvJLzIIDmMMPsRZu" "_id": "c0g5Ja67FNd4pRXqBxgEhh"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 25
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "",
"_N$string": "",
"_fontSize": 40,
"_lineHeight": 40,
"_enableWrapText": true,
"_N$file": null,
"_isSystemFontUsed": true,
"_spacingX": 0,
"_batchAsBitmap": false,
"_styleFlags": 0,
"_underlineHeight": 0,
"_N$horizontalAlign": 1,
"_N$verticalAlign": 1,
"_N$fontFamily": "Arial",
"_N$overflow": 0,
"_N$cacheMode": 0,
"_id": "6dE8CqUpBCsbvf3PWt3n2i"
}, },
{ {
"__type__": "cc.Sprite", "__type__": "cc.Sprite",
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 23 "__id__": 24
}, },
"_enabled": true, "_enabled": true,
"_materials": [ "_materials": [
...@@ -1275,7 +1336,7 @@ ...@@ -1275,7 +1336,7 @@
"_srcBlendFactor": 770, "_srcBlendFactor": 770,
"_dstBlendFactor": 771, "_dstBlendFactor": 771,
"_spriteFrame": { "_spriteFrame": {
"__uuid__": "df072013-29d2-49cb-95f8-233ee1775287" "__uuid__": "66adddc2-6f77-4b14-b2bf-5b0e6da5ea60"
}, },
"_type": 0, "_type": 0,
"_sizeMode": 1, "_sizeMode": 1,
...@@ -1289,50 +1350,123 @@ ...@@ -1289,50 +1350,123 @@
"_fillRange": 0, "_fillRange": 0,
"_isTrimmedMode": true, "_isTrimmedMode": true,
"_atlas": null, "_atlas": null,
"_id": "8c7ljLraVBQaimu2HzcjxJ" "_id": "a30FZTfOxH1ogauqCM9x84"
}, },
{ {
"__type__": "cc.Widget", "__type__": "cc.Button",
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 23 "__id__": 24
}, },
"_enabled": true, "_enabled": true,
"alignMode": 1, "_normalMaterial": null,
"_target": null, "_grayMaterial": null,
"_alignFlags": 12, "duration": 0.1,
"_left": 40, "zoomScale": 1.2,
"_right": 0, "clickEvents": [],
"_top": 0, "_N$interactable": true,
"_bottom": 0, "_N$enableAutoGrayEffect": false,
"_verticalCenter": 0, "_N$transition": 0,
"_horizontalCenter": 0, "transition": 0,
"_isAbsLeft": true, "_N$normalColor": {
"_isAbsRight": true, "__type__": "cc.Color",
"_isAbsTop": true, "r": 255,
"_isAbsBottom": true, "g": 255,
"_isAbsHorizontalCenter": true, "b": 255,
"_isAbsVerticalCenter": true, "a": 255
"_originalWidth": 0, },
"_originalHeight": 0, "_N$pressedColor": {
"_id": "bbnlWlqe1JCJSiF103/7yD" "__type__": "cc.Color",
"r": 211,
"g": 211,
"b": 211,
"a": 255
},
"pressedColor": {
"__type__": "cc.Color",
"r": 211,
"g": 211,
"b": 211,
"a": 255
},
"_N$hoverColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"hoverColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_N$disabledColor": {
"__type__": "cc.Color",
"r": 124,
"g": 124,
"b": 124,
"a": 255
},
"_N$normalSprite": null,
"_N$pressedSprite": null,
"pressedSprite": null,
"_N$hoverSprite": null,
"hoverSprite": null,
"_N$disabledSprite": null,
"_N$target": null,
"_id": "10unTeIRJMe7K2aCMASUAl"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 21
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "d3c8433a-a4b7-4e9c-972d-eb205af0351f"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "b2GJnUiJVLxIcRmxg/jGZb"
}, },
{ {
"__type__": "cc.Widget", "__type__": "cc.Widget",
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 7 "__id__": 21
}, },
"_enabled": true, "_enabled": true,
"alignMode": 1, "alignMode": 1,
"_target": null, "_target": null,
"_alignFlags": 45, "_alignFlags": 36,
"_left": 0, "_left": 0,
"_right": 0, "_right": 0.9349999999999454,
"_top": 0, "_top": 0,
"_bottom": 0, "_bottom": -10,
"_verticalCenter": 0, "_verticalCenter": 0,
"_horizontalCenter": 0, "_horizontalCenter": 0,
"_isAbsLeft": true, "_isAbsLeft": true,
...@@ -1341,30 +1475,34 @@ ...@@ -1341,30 +1475,34 @@
"_isAbsBottom": true, "_isAbsBottom": true,
"_isAbsHorizontalCenter": true, "_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true, "_isAbsVerticalCenter": true,
"_originalWidth": 300, "_originalWidth": 0,
"_originalHeight": 200, "_originalHeight": 0,
"_id": "abVEh5lPdN97Kkpo3FsZcf" "_id": "abGn+9tfNA1ZASq3VSIVms"
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "res", "_name": "img_board",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 2 "__id__": 7
}, },
"_children": [ "_children": [
{ {
"__id__": 29 "__id__": 32
}, },
{ {
"__id__": 32 "__id__": 37
}
],
"_active": true,
"_components": [
{
"__id__": 43
}, },
{ {
"__id__": 33 "__id__": 44
} }
], ],
"_active": false,
"_components": [],
"_prefab": null, "_prefab": null,
"_opacity": 255, "_opacity": 255,
"_color": { "_color": {
...@@ -1376,8 +1514,8 @@ ...@@ -1376,8 +1514,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 0, "width": 1348,
"height": 0 "height": 1051
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
...@@ -1388,8 +1526,8 @@ ...@@ -1388,8 +1526,8 @@
"__type__": "TypedArray", "__type__": "TypedArray",
"ctor": "Float64Array", "ctor": "Float64Array",
"array": [ "array": [
0, -266,
0, -14.5,
0, 0,
0, 0,
0, 0,
...@@ -1411,22 +1549,26 @@ ...@@ -1411,22 +1549,26 @@
"_is3DNode": false, "_is3DNode": false,
"_groupIndex": 0, "_groupIndex": 0,
"groupIndex": 0, "groupIndex": 0,
"_id": "0aAzbH6R1E+6AmGRrkKa5O" "_id": "e34qnEBq9NibGTDzCtlGd6"
}, },
{ {
"__type__": "cc.Node", "__type__": "cc.Node",
"_name": "font", "_name": "bgIcon",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 28 "__id__": 31
}, },
"_children": [ "_children": [
{ {
"__id__": 30 "__id__": 33
} }
], ],
"_active": true, "_active": true,
"_components": [], "_components": [
{
"__id__": 36
}
],
"_prefab": null, "_prefab": null,
"_opacity": 255, "_opacity": 255,
"_color": { "_color": {
...@@ -1438,8 +1580,666 @@ ...@@ -1438,8 +1580,666 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 0, "width": 900,
"height": 0 "height": 660
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
1.2739999999999991,
16.726,
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": "e4HWg+wvJLzIIDmMMPsRZu"
},
{
"__type__": "cc.Node",
"_name": "rect",
"_objFlags": 0,
"_parent": {
"__id__": 32
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 34
},
{
"__id__": 35
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 900,
"height": 660
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0,
"y": 1
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
-450,
330,
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": "dcRSdg8EdB2oRKG5VR8oYT"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 33
},
"_enabled": false,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "a23235d1-15db-4b95-8439-a2e005bfff91"
},
"_type": 0,
"_sizeMode": 0,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "d1Xs/T6JhBzb0KZWISdb23"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 33
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 45,
"_left": 0,
"_right": 0,
"_top": 0,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 1100,
"_originalHeight": 660,
"_id": "edeLA6OtRMKK+RIMJ0Vupa"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 32
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": null,
"_type": 0,
"_sizeMode": 0,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": false,
"_atlas": null,
"_id": "48Ti57xpxNO7RK9YZAuAEm"
},
{
"__type__": "cc.Node",
"_name": "box",
"_objFlags": 0,
"_parent": {
"__id__": 31
},
"_children": [
{
"__id__": 38
},
{
"__id__": 40
}
],
"_active": true,
"_components": [
{
"__id__": 42
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 40,
"height": 50.4
},
"_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": "11zHkheGxGTLNxWsA6y6JS"
},
{
"__type__": "cc.Node",
"_name": "icon",
"_objFlags": 0,
"_parent": {
"__id__": 37
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 39
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 40,
"height": 36
},
"_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": "17Z2c2bh1Gip+5wD6KsuNj"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 38
},
"_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": "ccLtDnV8NF74l+Y7cnutbe"
},
{
"__type__": "cc.Node",
"_name": "lb",
"_objFlags": 0,
"_parent": {
"__id__": 37
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 41
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 0,
"b": 0,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 0,
"height": 50.4
},
"_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": "2eQIf4llRI4p9tgnX9UKNw"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 40
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_string": "",
"_N$string": "",
"_fontSize": 40,
"_lineHeight": 40,
"_enableWrapText": true,
"_N$file": null,
"_isSystemFontUsed": true,
"_spacingX": 0,
"_batchAsBitmap": false,
"_styleFlags": 0,
"_underlineHeight": 0,
"_N$horizontalAlign": 0,
"_N$verticalAlign": 0,
"_N$fontFamily": "Arial",
"_N$overflow": 0,
"_N$cacheMode": 0,
"_id": "cbCrK3tmhJ6bC5LADEIulF"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 37
},
"_enabled": false,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "a23235d1-15db-4b95-8439-a2e005bfff91"
},
"_type": 0,
"_sizeMode": 0,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "a9fOm4n1xKBJqeNnbsLFlA"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 31
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "df072013-29d2-49cb-95f8-233ee1775287"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "8c7ljLraVBQaimu2HzcjxJ"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 31
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 12,
"_left": 40,
"_right": 0,
"_top": 0,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 0,
"_originalHeight": 0,
"_id": "bbnlWlqe1JCJSiF103/7yD"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 7
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 45,
"_left": 0,
"_right": 0,
"_top": 0,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 300,
"_originalHeight": 200,
"_id": "abVEh5lPdN97Kkpo3FsZcf"
},
{
"__type__": "cc.Node",
"_name": "res",
"_objFlags": 0,
"_parent": {
"__id__": 2
},
"_children": [
{
"__id__": 47
},
{
"__id__": 50
},
{
"__id__": 51
}
],
"_active": false,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 0,
"height": 0
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "0aAzbH6R1E+6AmGRrkKa5O"
},
{
"__type__": "cc.Node",
"_name": "font",
"_objFlags": 0,
"_parent": {
"__id__": 46
},
"_children": [
{
"__id__": 48
}
],
"_active": true,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 0,
"height": 0
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
...@@ -1480,13 +2280,13 @@ ...@@ -1480,13 +2280,13 @@
"_name": "BRLNSDB", "_name": "BRLNSDB",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 29 "__id__": 47
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 31 "__id__": 49
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1542,7 +2342,7 @@ ...@@ -1542,7 +2342,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 30 "__id__": 48
}, },
"_enabled": true, "_enabled": true,
"_materials": [], "_materials": [],
...@@ -1573,7 +2373,7 @@ ...@@ -1573,7 +2373,7 @@
"_name": "img", "_name": "img",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 28 "__id__": 46
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
...@@ -1631,14 +2431,14 @@ ...@@ -1631,14 +2431,14 @@
"_name": "audio", "_name": "audio",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 28 "__id__": 46
}, },
"_children": [ "_children": [
{ {
"__id__": 34 "__id__": 52
}, },
{ {
"__id__": 36 "__id__": 54
} }
], ],
"_active": true, "_active": true,
...@@ -1696,13 +2496,13 @@ ...@@ -1696,13 +2496,13 @@
"_name": "click", "_name": "click",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 33 "__id__": 51
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 35 "__id__": 53
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1758,7 +2558,7 @@ ...@@ -1758,7 +2558,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 34 "__id__": 52
}, },
"_enabled": true, "_enabled": true,
"_clip": { "_clip": {
...@@ -1777,13 +2577,13 @@ ...@@ -1777,13 +2577,13 @@
"_name": "btn", "_name": "btn",
"_objFlags": 0, "_objFlags": 0,
"_parent": { "_parent": {
"__id__": 33 "__id__": 51
}, },
"_children": [], "_children": [],
"_active": true, "_active": true,
"_components": [ "_components": [
{ {
"__id__": 37 "__id__": 55
} }
], ],
"_prefab": null, "_prefab": null,
...@@ -1839,7 +2639,7 @@ ...@@ -1839,7 +2639,7 @@
"_name": "", "_name": "",
"_objFlags": 0, "_objFlags": 0,
"node": { "node": {
"__id__": 36 "__id__": 54
}, },
"_enabled": true, "_enabled": true,
"_clip": { "_clip": {
...@@ -1905,6 +2705,21 @@ ...@@ -1905,6 +2705,21 @@
"__id__": 2 "__id__": 2
}, },
"_enabled": true, "_enabled": true,
"boyNode": {
"__id__": 22
},
"bgIcon": {
"__id__": 32
},
"rect": {
"__id__": 33
},
"box": {
"__id__": 37
},
"btn_next": {
"__id__": 24
},
"_id": "eaTVUpqahPfZeO9+sUI7RP" "_id": "eaTVUpqahPfZeO9+sUI7RP"
} }
] ]
\ No newline at end of file
import { asyncDelay, onHomeworkFinish } from "../script/util_DG25"; import { getSpriteFrimeByUrl, goNextPage, onHomeworkFinish } from "../script/util_DG25";
import { MyCocosSceneComponent } from "../script/MyCocosSceneComponent_DG25"; import { MyCocosSceneComponent } from "../script/MyCocosSceneComponent_DG25";
import Boy from "../script/items/boy_DG25";
const { ccclass, property } = cc._decorator; const { ccclass, property } = cc._decorator;
@ccclass @ccclass
export default class SceneComponent extends MyCocosSceneComponent { export default class SceneComponent extends MyCocosSceneComponent {
@property(cc.Node)
boyNode: cc.Node = null;
@property(cc.Node)
bgIcon: cc.Node = null;
@property(cc.Node)
rect: cc.Node = null;
@property(cc.Node)
box: cc.Node = null;
@property(cc.Node)
btn_next: cc.Node = null;
_bgIconUrl: any;
_item_1_data: any;
_item_2_data: any;
_itemOffsetx: any;
_itemOffsety: any;
private _itemList: any;
addPreloadImage() { addPreloadImage() {
// TODO 根据自己的配置预加载图片资源 // TODO 根据自己的配置预加载图片资源
...@@ -14,7 +31,8 @@ export default class SceneComponent extends MyCocosSceneComponent { ...@@ -14,7 +31,8 @@ export default class SceneComponent extends MyCocosSceneComponent {
addPreloadAudio() { addPreloadAudio() {
// TODO 根据自己的配置预加载音频资源 // TODO 根据自己的配置预加载音频资源
// this._audioResList.push({ url: this.data.audio_url }); this._audioResList.push({ url: this.data.start_audio_url });
this._audioResList.push({ url: this.data.end_audio_url });
} }
addPreloadAnima() { addPreloadAnima() {
...@@ -22,6 +40,8 @@ export default class SceneComponent extends MyCocosSceneComponent { ...@@ -22,6 +40,8 @@ export default class SceneComponent extends MyCocosSceneComponent {
} }
async onLoadEnd() { async onLoadEnd() {
cc.log(JSON.stringify(this.data, null, 2))
// TODO 加载完成后的逻辑写在这里, 下面的代码仅供参考 // TODO 加载完成后的逻辑写在这里, 下面的代码仅供参考
this.initData(); this.initData();
this.initView(); this.initView();
...@@ -36,17 +56,112 @@ export default class SceneComponent extends MyCocosSceneComponent { ...@@ -36,17 +56,112 @@ export default class SceneComponent extends MyCocosSceneComponent {
initView() { initView() {
this.initBg(); this.initBg();
this.initPageData();
this.initPageView();
this.boyNode.getComponent(Boy).playtalk(-1);
this.playAudioByUrl(this.data.start_audio_url, () => {
this.boyNode.getComponent(Boy).playNormal();
})
} }
initBg() { initBg() {
const bgNode = cc.find('Canvas/bg'); const bgNode = cc.find('Canvas/bg');
bgNode.scale = this._mapScaleMax; bgNode.scale = this._mapScaleMax;
this.btn_next.on("click", () => {
cc.audioEngine.stopAllEffects();
goNextPage()
})
} }
initPageData() {
this._bgIconUrl = this.data.bgItem.url;
this._itemList = this.data.hotZoneItemArr || [];
}
initPageView() {
this.btn_next.active = false;
if (this.data.end_btn_text) {
this.btn_next.active = true;
this.btn_next.getChildByName("lb").getComponent(cc.Label).string = this.data.end_btn_text;
}
this.rect.removeAllChildren();
if (this._bgIconUrl) {
getSpriteFrimeByUrl(this._bgIconUrl, (spf) => {
this.bgIcon.getComponent(cc.Sprite).spriteFrame = spf;
this.bgIcon.width = this.data.bgItem.rect.width;
this.bgIcon.height = this.data.bgItem.rect.height;
this.rect.getComponent(cc.Widget).updateAlignment();
this.bgIcon.scale = Math.min(1100 / this.bgIcon.width, 660 / this.bgIcon.height)
})
}
let doneAudioIndex = 0;
for (let i = 0; i < this._itemList.length; ++i) {
let itemInfo = this._itemList[i];
let item = cc.instantiate(this.box);
item.parent = this.rect;
item.width = itemInfo.rect.width;
item.height = itemInfo.rect.height;
item.x = itemInfo.rect.x + itemInfo.rect.width / 2;
item.y = -itemInfo.rect.y - itemInfo.rect.height / 2;
item.addComponent(cc.Button);
cc.log("item scale == " + item.scale)
item.on("click", () => {
cc.audioEngine.stopAllEffects();
this.boyNode.getComponent(Boy).playNormal();
this.rect.children.forEach((val) => {
val.stopAllActions();
val.scale = 1;
})
if (!item["doneAudio"]) {
item["doneAudio"] = true;
doneAudioIndex++;
}
cc.tween(item).to(0.5, { scale: 1.05 }).to(0.5, { scale: 1 }).start()
this.playAudioByUrl(itemInfo.audio_url, () => {
this.ckeckEnd(doneAudioIndex);
})
})
if (itemInfo.pic_url) {
item.getChildByName("icon").active = true;
getSpriteFrimeByUrl(itemInfo.pic_url, (spf) => {
item.getChildByName("icon").getComponent(cc.Sprite).spriteFrame = spf;
item.getChildByName("icon").scale = itemInfo.imgScale;
// this.bgIcon.scale = Math.min(1100 / this.bgIcon.width, 660 / this.bgIcon.height)
})
} else {
item.getChildByName("icon").active = false;
}
if (itemInfo.text) {
item.getChildByName("lb").active = true;
item.getChildByName("lb").getComponent(cc.Label).string = itemInfo.text;
} else {
item.getChildByName("lb").active = false;
}
}
}
ckeckEnd(nowIndex) {
if (nowIndex == this._itemList.length) {
cc.log("donve");
this.boyNode.getComponent(Boy).playtalk(-1);
this.playAudioByUrl(this.data.end_audio_url, () => {
this.boyNode.getComponent(Boy).playNormal();
})
}
}
......
export const defaultData = { export const defaultData =
"pic_url": "http://staging-teach.cdn.ireadabc.com/ed94332a503c31e0908bd4c6923a2665.png", {
"pic_url_2": "http://staging-teach.cdn.ireadabc.com/5fb60317ade0195d35ad8034d5370a7f.png", "bgItem": {
"text": "This is a test label.", "url": "http://staging-teach.cdn.ireadabc.com/b98081742d4fd40f42e24284c89f48d9.png",
"audio_url": "http://staging-teach.cdn.ireadabc.com/f47f1d7b5c160fe1c59500d180346240.mp3" "rect": {
"x": 193.39,
"y": 0,
"width": 830.22,
"height": 467
}
},
"hotZoneItemArr": [
{
"id": "1700553479578",
"index": 0,
"pic_url": "http://staging-teach.cdn.ireadabc.com/ed1741e9231dd320033bf4ecbf283b0f.png",
"audio_url": "http://staging-teach.cdn.ireadabc.com/12eb0567ca90c61fc42964bd8344e8b3.mp3",
"itemType": "pic",
"fontScale": 0.95078125,
"imgScale": 0.2627906976744186,
"mapScale": 0.95078125,
"gIdx": "1",
"rect": {
"x": 75.86,
"y": 42.42,
"width": 247.81,
"height": 113
}
},
{
"id": "1700553482079",
"index": 1,
"pic_url": "http://staging-teach.cdn.ireadabc.com/727701ba34634c7d90cf794808064280.png",
"audio_url": "http://staging-teach.cdn.ireadabc.com/5e0ae1de90cff001bd0f6798341e723b.mp3",
"itemType": "pic",
"fontScale": 0.95078125,
"imgScale": 0.2534883720930233,
"mapScale": 0.95078125,
"gIdx": "1",
"rect": {
"x": 528.41,
"y": 48.46,
"width": 239.04,
"height": 109
}
}
],
"start_audio_url": "http://staging-teach.cdn.ireadabc.com/e66bac8d77385b01ce180987c9a0c601.mp3",
"end_audio_url": "http://staging-teach.cdn.ireadabc.com/9541b250b13a284ca28abf87ab0bdedb.mp3",
"end_btn_text": "去故事乐园"
} }
\ No newline at end of file
...@@ -416,3 +416,12 @@ export function getMinLv(num) { ...@@ -416,3 +416,12 @@ export function getMinLv(num) {
} }
} }
export function goNextPage() {
if (!cc.find('middleLayer')) {
console.log("==点击了下一页按钮==")
return;
}
const middleLayer = cc.find('middleLayer').getComponent('middleLayer');
middleLayer.goNextPage();
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "6aa31b3f-3dab-417a-b393-803509a6ead4",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 265,
"height": 175,
"platformSettings": {},
"subMetas": {
"btn_go_dg07_fanka": {
"ver": "1.0.4",
"uuid": "66adddc2-6f77-4b14-b2bf-5b0e6da5ea60",
"rawTextureUuid": "6aa31b3f-3dab-417a-b393-803509a6ead4",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": -4,
"offsetY": 1.5,
"trimX": 0,
"trimY": 3,
"width": 257,
"height": 166,
"rawWidth": 265,
"rawHeight": 175,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
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