Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
chooseWord
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
chooseWord
Commits
fde501d7
Commit
fde501d7
authored
Nov 29, 2020
by
asdf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
173afde1
Changes
37
Hide whitespace changes
Inline
Side-by-side
Showing
37 changed files
with
1863 additions
and
107 deletions
+1863
-107
form.component.html
form/src/app/form/form.component.html
+9
-6
form.component.ts
form/src/app/form/form.component.ts
+12
-15
fingerMove.anim
play/assets/tmpGame/aminations/fingerMove.anim
+7
-7
result1.anim
play/assets/tmpGame/aminations/result1.anim
+114
-0
result1.anim.meta
play/assets/tmpGame/aminations/result1.anim.meta
+5
-0
result2.anim
play/assets/tmpGame/aminations/result2.anim
+37
-0
result2.anim.meta
play/assets/tmpGame/aminations/result2.anim.meta
+5
-0
enter.mp3
play/assets/tmpGame/audios/enter.mp3
+0
-0
enter.mp3.meta
play/assets/tmpGame/audios/enter.mp3.meta
+2
-2
good.mp3
play/assets/tmpGame/audios/good.mp3
+0
-0
good.mp3.meta
play/assets/tmpGame/audios/good.mp3.meta
+7
-0
train.mp3
play/assets/tmpGame/audios/train.mp3
+0
-0
train.mp3.meta
play/assets/tmpGame/audios/train.mp3.meta
+2
-2
welldone.mp3
play/assets/tmpGame/audios/welldone.mp3
+0
-0
welldone.mp3.meta
play/assets/tmpGame/audios/welldone.mp3.meta
+7
-0
弹出骨骼动画.mp3
play/assets/tmpGame/audios/弹出骨骼动画.mp3
+0
-0
弹出骨骼动画.mp3.meta
play/assets/tmpGame/audios/弹出骨骼动画.mp3.meta
+8
-0
点击.mp3
play/assets/tmpGame/audios/点击.mp3
+0
-0
点击.mp3.meta
play/assets/tmpGame/audios/点击.mp3.meta
+8
-0
结尾小孩欢呼.mp3
play/assets/tmpGame/audios/结尾小孩欢呼.mp3
+0
-0
结尾小孩欢呼.mp3.meta
play/assets/tmpGame/audios/结尾小孩欢呼.mp3.meta
+8
-0
错误提示音.mp3
play/assets/tmpGame/audios/错误提示音.mp3
+0
-0
错误提示音.mp3.meta
play/assets/tmpGame/audios/错误提示音.mp3.meta
+8
-0
ItemLetter.prefab
play/assets/tmpGame/prefabs/ItemLetter.prefab
+1
-1
LayerResult.prefab
play/assets/tmpGame/prefabs/LayerResult.prefab
+924
-0
LayerResult.prefab.meta
play/assets/tmpGame/prefabs/LayerResult.prefab.meta
+8
-0
coach1.prefab
play/assets/tmpGame/prefabs/coach1.prefab
+2
-2
Scene.fire
play/assets/tmpGame/scene/Scene.fire
+354
-32
ItemCoach1.js
play/assets/tmpGame/script/ItemCoach1.js
+11
-6
ItemCoach2.js
play/assets/tmpGame/script/ItemCoach2.js
+11
-6
ItemCoach3.js
play/assets/tmpGame/script/ItemCoach3.js
+11
-6
ItemCoach4.js
play/assets/tmpGame/script/ItemCoach4.js
+11
-6
ItemLetter.js
play/assets/tmpGame/script/ItemLetter.js
+6
-1
LayerResult.js
play/assets/tmpGame/script/LayerResult.js
+209
-0
LayerResult.js.meta
play/assets/tmpGame/script/LayerResult.js.meta
+9
-0
Scene.js
play/assets/tmpGame/script/Scene.js
+66
-14
project.json
play/settings/project.json
+1
-1
No files found.
form/src/app/form/form.component.html
View file @
fde501d7
...
@@ -13,9 +13,11 @@
...
@@ -13,9 +13,11 @@
</div>
</div>
<div
class=
"section-content;text-align:center "
>
<div
class=
"section-content;text-align:center "
>
<span
style=
"margin-bottom: 10px;margin-left: 20px;"
>
字母(小写,无需符号隔开。例如:ab):
</span>
<span
style=
"margin-bottom: 10px;margin-left: 20px;"
>
匹配字母(每个输入框只能输入一个字母):
</span>
<input
style=
"width: 200px; margin-bottom: 10px;margin-left: 10px;"
type=
"text"
nz-input
<input
style=
"width: 35px; margin-bottom: 10px;margin-left: 10px;"
type=
"text"
nz-input
[(
ngModel
)]="
contentObj
.
letter
"
(
ngModelChange
)="
handleTextChange2
($
event
)"
>
[(
ngModel
)]="
contentObj
.
letter1
"
(
ngModelChange
)="
handleTextChange2
($
event
)"
>
<input
style=
"width: 35px; margin-bottom: 10px;margin-left: 10px;"
type=
"text"
nz-input
[(
ngModel
)]="
contentObj
.
letter2
"
(
ngModelChange
)="
handleTextChange3
($
event
)"
>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -59,9 +61,11 @@
...
@@ -59,9 +61,11 @@
<input
style=
"width: 200px; margin-bottom: 10px;margin-left: 10px;"
type=
"text"
nz-input
<input
style=
"width: 200px; margin-bottom: 10px;margin-left: 10px;"
type=
"text"
nz-input
[(
ngModel
)]="
item
.
text
"
(
ngModelChange
)="
handleTextChange
($
event
,
i
)"
>
[(
ngModel
)]="
item
.
text
"
(
ngModelChange
)="
handleTextChange
($
event
,
i
)"
>
</div>
</div>
</div>
<div
class=
"card-item-content border"
style=
"margin-top: 10px;"
>
<div
class=
"section-content;text-align:center "
>
<span
style=
"margin-bottom: 10px;margin-left: 20px;"
>
点击选择变色字母
</span>
</div>
<div
*
ngFor=
"let word of item.text.split(''); let j = index"
class=
"section-content;text-align:center"
<div
*
ngFor=
"let word of item.text.split(''); let j = index"
class=
"section-content;text-align:center"
style=
"padding: 0.5vw; display: inline-block"
>
style=
"padding: 0.5vw; display: inline-block"
>
<button
nz-button
[
nzType
]=
getButtonType
(
item
,
j
)
(
click
)="
setButtonType
(
item
,
j
)"
>
<button
nz-button
[
nzType
]=
getButtonType
(
item
,
j
)
(
click
)="
setButtonType
(
item
,
j
)"
>
...
@@ -70,7 +74,6 @@
...
@@ -70,7 +74,6 @@
</div>
</div>
</div>
</div>
<div
class=
"card-item-content border"
style=
"margin-top: 10px;"
>
<div
class=
"card-item-content border"
style=
"margin-top: 10px;"
>
<span
style=
"margin-left: 10px;"
>
骨骼动画 :
</span>
<span
style=
"margin-left: 10px;"
>
骨骼动画 :
</span>
<div
class=
"section-content;text-align:center"
style=
"margin-top: 10px"
>
<div
class=
"section-content;text-align:center"
style=
"margin-top: 10px"
>
...
...
form/src/app/form/form.component.ts
View file @
fde501d7
...
@@ -31,7 +31,8 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
...
@@ -31,7 +31,8 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
contentObj
=
{
contentObj
=
{
"
version
"
:
"
1.1
"
,
"
version
"
:
"
1.1
"
,
bgm_url
:
""
,
bgm_url
:
""
,
letter
:
""
,
letter1
:
""
,
letter2
:
""
,
dataArray
:
[]
dataArray
:
[]
}
}
/**
/**
...
@@ -40,7 +41,7 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
...
@@ -40,7 +41,7 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
* shortAudio_url:'',
* shortAudio_url:'',
* image_url:'',
* image_url:'',
* isRight:false,
* isRight:false,
* letter
s:[]
* letter
Index:-1
* }
* }
*/
*/
...
@@ -58,17 +59,17 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
...
@@ -58,17 +59,17 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
handleTextChange
(
text
,
index
)
{
handleTextChange
(
text
,
index
)
{
let
item
=
this
.
contentObj
.
dataArray
[
index
];
let
item
=
this
.
contentObj
.
dataArray
[
index
];
item
.
text
=
text
;
item
.
text
=
text
;
for
(
let
i
=
0
;
i
<
text
.
length
;
i
++
)
{
if
(
!
item
.
letters
[
i
])
{
item
.
letters
[
i
]
=
0
;
}
}
this
.
saveItem
()
this
.
saveItem
()
this
.
refresh
();
this
.
refresh
();
}
}
handleTextChange2
(
text
)
{
handleTextChange2
(
text
)
{
this
.
contentObj
.
letter
=
text
;
this
.
contentObj
.
letter1
=
text
;
this
.
saveItem
()
this
.
refresh
();
}
handleTextChange3
(
text
)
{
this
.
contentObj
.
letter2
=
text
;
this
.
saveItem
()
this
.
saveItem
()
this
.
refresh
();
this
.
refresh
();
}
}
...
@@ -137,16 +138,12 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
...
@@ -137,16 +138,12 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
}
}
setButtonType
(
item
,
j
)
{
setButtonType
(
item
,
j
)
{
if
(
item
.
letters
[
j
]
==
1
)
{
item
.
letterIndex
=
j
;
item
.
letters
[
j
]
=
0
;
}
else
{
item
.
letters
[
j
]
=
1
;
}
this
.
save
()
this
.
save
()
}
}
getButtonType
(
item
,
j
)
{
getButtonType
(
item
,
j
)
{
if
(
item
.
letter
s
[
j
]
==
1
)
{
if
(
item
.
letter
Index
==
j
)
{
return
'
primary
'
;
return
'
primary
'
;
}
}
return
'
text
'
;
return
'
text
'
;
...
@@ -162,7 +159,7 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
...
@@ -162,7 +159,7 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
}
}
addItem
(
item
)
{
addItem
(
item
)
{
item
.
push
({
text
:
""
,
isRight
:
false
,
shortAudio_url
:
''
,
image_url
:
""
,
letter
s
:
{}
})
item
.
push
({
text
:
""
,
isRight
:
false
,
shortAudio_url
:
''
,
image_url
:
""
,
letter
Index
:
-
1
})
this
.
saveItem
();
this
.
saveItem
();
setTimeout
(()
=>
{
setTimeout
(()
=>
{
window
.
scrollTo
(
0
,
document
.
body
.
scrollHeight
);
window
.
scrollTo
(
0
,
document
.
body
.
scrollHeight
);
...
...
play/assets/tmpGame/aminations/fingerMove.anim
View file @
fde501d7
...
@@ -14,31 +14,31 @@
...
@@ -14,31 +14,31 @@
"x": [
"x": [
{
{
"frame": 0,
"frame": 0,
"value": 6
90
"value": 6
13.022
},
},
{
{
"frame": 0.08333333333333333,
"frame": 0.08333333333333333,
"value": 6
90
"value": 6
13.022
},
},
{
{
"frame": 0.16666666666666666,
"frame": 0.16666666666666666,
"value":
900
"value":
820.305
},
},
{
{
"frame": 0.25,
"frame": 0.25,
"value":
900
"value":
820.305
},
},
{
{
"frame": 0.3333333333333333,
"frame": 0.3333333333333333,
"value": 1
108
"value": 1
026.796
},
},
{
{
"frame": 0.4166666666666667,
"frame": 0.4166666666666667,
"value": 1
108
"value": 1
026.796
},
},
{
{
"frame": 0.5,
"frame": 0.5,
"value": 1
315
"value": 1
233.686
}
}
],
],
"active": [
"active": [
...
...
play/assets/tmpGame/aminations/result1.anim
0 → 100644
View file @
fde501d7
{
"__type__": "cc.AnimationClip",
"_name": "result1",
"_objFlags": 0,
"_native": "",
"_duration": 0.6666666666666666,
"sample": 60,
"speed": 1,
"wrapMode": 1,
"curveData": {
"paths": {
"dragonBone": {
"props": {
"position": [
{
"frame": 0,
"value": [
250,
218
],
"motionPath": [
[
-38,
266,
69,
256,
-158,
277
]
]
},
{
"frame": 0.2,
"value": [
-216.2,
260.2
],
"motionPath": [
[
-248.8,
215.5,
-261.2,
238.8,
-240.2,
199.3
],
[
-167.7,
160.7,
-232.5,
188.4,
-73.7,
127.3
]
]
},
{
"frame": 0.4166666666666667,
"value": [
-2,
110.8
],
"motionPath": []
}
],
"scale": [
{
"frame": 0,
"value": {
"__type__": "cc.Vec2",
"x": 0.1,
"y": 0.1
}
},
{
"frame": 0.4166666666666667,
"value": {
"__type__": "cc.Vec2",
"x": 1,
"y": 1
}
}
]
}
},
"lettters": {
"props": {
"scaleX": [
{
"frame": 0.5,
"value": 0,
"curve": "quintOut"
},
{
"frame": 0.6666666666666666,
"value": 1
}
],
"angle": [
{
"frame": 0.5,
"value": -45
},
{
"frame": 0.6666666666666666,
"value": 0
}
]
}
}
}
},
"events": []
}
\ No newline at end of file
play/assets/tmpGame/aminations/result1.anim.meta
0 → 100644
View file @
fde501d7
{
"ver": "2.1.0",
"uuid": "15ba7314-ae90-4f24-82d2-41fafddb7553",
"subMetas": {}
}
\ No newline at end of file
play/assets/tmpGame/aminations/result2.anim
0 → 100644
View file @
fde501d7
{
"__type__": "cc.AnimationClip",
"_name": "result2",
"_objFlags": 0,
"_native": "",
"_duration": 0.21666666666666667,
"sample": 60,
"speed": 1,
"wrapMode": 1,
"curveData": {
"paths": {
"wrong": {
"props": {
"scale": [
{
"frame": 0,
"value": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
}
},
{
"frame": 0.21666666666666667,
"value": {
"__type__": "cc.Vec2",
"x": 1,
"y": 1
}
}
]
}
}
}
},
"events": []
}
\ No newline at end of file
play/assets/tmpGame/aminations/result2.anim.meta
0 → 100644
View file @
fde501d7
{
"ver": "2.1.0",
"uuid": "380b1c1a-7cb2-484d-88ea-a56bdb59cb4a",
"subMetas": {}
}
\ No newline at end of file
play/assets/tmpGame/audios/enter.mp3
View file @
fde501d7
No preview for this file type
play/assets/tmpGame/audios/enter.mp3.meta
View file @
fde501d7
{
{
"ver": "2.0.1",
"ver": "2.0.1",
"uuid": "
3b4d792e-6e1e-4a06-9f07-8368268755b7
",
"uuid": "
dcd876c9-19be-4007-8074-069e28524108
",
"downloadMode": 0,
"downloadMode": 0,
"duration": 1.
184417
,
"duration": 1.
477333
,
"subMetas": {}
"subMetas": {}
}
}
\ No newline at end of file
play/assets/tmpGame/audios/good.mp3
0 → 100644
View file @
fde501d7
File added
play/assets/tmpGame/audios/good.mp3.meta
0 → 100644
View file @
fde501d7
{
"ver": "2.0.1",
"uuid": "a709194a-2a36-4d5d-9af5-3a2235e573c5",
"downloadMode": 0,
"duration": 0.6131,
"subMetas": {}
}
\ No newline at end of file
play/assets/tmpGame/audios/train.mp3
View file @
fde501d7
No preview for this file type
play/assets/tmpGame/audios/train.mp3.meta
View file @
fde501d7
{
{
"ver": "2.0.1",
"ver": "2.0.1",
"uuid": "
a7e0fc53-293f-4b46-81ca-8e1c62a84a9
c",
"uuid": "
97bbdd40-339a-4483-8495-cad59f594c4
c",
"downloadMode": 0,
"downloadMode": 0,
"duration":
9.351837
,
"duration":
4.5803
,
"subMetas": {}
"subMetas": {}
}
}
\ No newline at end of file
play/assets/tmpGame/audios/welldone.mp3
0 → 100644
View file @
fde501d7
File added
play/assets/tmpGame/audios/welldone.mp3.meta
0 → 100644
View file @
fde501d7
{
"ver": "2.0.1",
"uuid": "6c517aba-74b4-4a4d-ba9c-ebcff8396b4c",
"downloadMode": 0,
"duration": 0.7079,
"subMetas": {}
}
\ No newline at end of file
play/assets/tmpGame/audios/弹出骨骼动画.mp3
0 → 100644
View file @
fde501d7
File added
play/assets/tmpGame/audios/弹出骨骼动画.mp3.meta
0 → 100644
View file @
fde501d7
{
"ver": "2.0.1",
"uuid": "ccc98fd8-785a-4bc1-ac6e-1854b10ffb08",
"downloadMode": 0,
"duration": 0.333333,
"subMetas": {}
}
\ No newline at end of file
play/assets/tmpGame/audios/点击.mp3
0 → 100644
View file @
fde501d7
File added
play/assets/tmpGame/audios/点击.mp3.meta
0 → 100644
View file @
fde501d7
{
"ver": "2.0.1",
"uuid": "77d0d09c-25c7-46b8-86e3-ac2def488077",
"downloadMode": 0,
"duration": 0.195894,
"subMetas": {}
}
\ No newline at end of file
play/assets/tmpGame/audios/结尾小孩欢呼.mp3
0 → 100644
View file @
fde501d7
File added
play/assets/tmpGame/audios/结尾小孩欢呼.mp3.meta
0 → 100644
View file @
fde501d7
{
"ver": "2.0.1",
"uuid": "da6d6e4f-aa6c-4aba-8a9a-9038c82af8a3",
"downloadMode": 0,
"duration": 3.3701,
"subMetas": {}
}
\ No newline at end of file
play/assets/tmpGame/audios/错误提示音.mp3
0 → 100644
View file @
fde501d7
File added
play/assets/tmpGame/audios/错误提示音.mp3.meta
0 → 100644
View file @
fde501d7
{
"ver": "2.0.1",
"uuid": "059d55e5-a26c-4b9e-9806-b32e350a8b79",
"downloadMode": 0,
"duration": 1.7258,
"subMetas": {}
}
\ No newline at end of file
play/assets/tmpGame/prefabs/ItemLetter.prefab
View file @
fde501d7
...
@@ -51,7 +51,7 @@
...
@@ -51,7 +51,7 @@
"__type__": "TypedArray",
"__type__": "TypedArray",
"ctor": "Float64Array",
"ctor": "Float64Array",
"array": [
"array": [
-28.37
,
0
,
0,
0,
0,
0,
0,
0,
...
...
play/assets/tmpGame/prefabs/LayerResult.prefab
0 → 100644
View file @
fde501d7
[
{
"__type__": "cc.Prefab",
"_name": "",
"_objFlags": 0,
"_native": "",
"data": {
"__id__": 1
},
"optimizationPolicy": 0,
"asyncLoadAssets": false,
"readonly": false
},
{
"__type__": "cc.Node",
"_name": "LayerResult",
"_objFlags": 0,
"_parent": null,
"_children": [
{
"__id__": 2
},
{
"__id__": 6
},
{
"__id__": 9
},
{
"__id__": 12
}
],
"_active": true,
"_components": [
{
"__id__": 23
},
{
"__id__": 24
},
{
"__id__": 25
},
{
"__id__": 26
}
],
"_prefab": {
"__id__": 27
},
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 1280,
"height": 720
},
"_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": ""
},
{
"__type__": "cc.Node",
"_name": "bg",
"_objFlags": 0,
"_parent": {
"__id__": 1
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 3
},
{
"__id__": 4
}
],
"_prefab": {
"__id__": 5
},
"_opacity": 178.5,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 1280,
"height": 720
},
"_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": ""
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 2
},
"_enabled": true,
"_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": ""
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 2
},
"_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": 100,
"_originalHeight": 100,
"_id": ""
},
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 1
},
"asset": {
"__uuid__": "08949af0-f133-4990-8a03-95403eb67c2d"
},
"fileId": "3fD7KPBuJADI6Qywy0LiAV",
"sync": false
},
{
"__type__": "cc.Node",
"_name": "dragonBone",
"_objFlags": 0,
"_parent": {
"__id__": 1
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 7
}
],
"_prefab": {
"__id__": 8
},
"_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,
117.753,
0,
0,
0,
0,
1,
0,
0,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": ""
},
{
"__type__": "dragonBones.ArmatureDisplay",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 6
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_armatureName": "",
"_animationName": "",
"_preCacheMode": -1,
"_cacheMode": 0,
"playTimes": -1,
"premultipliedAlpha": false,
"_armatureKey": "",
"_accTime": 0,
"_playCount": 0,
"_frameCache": null,
"_curFrame": null,
"_playing": false,
"_armatureCache": null,
"_N$dragonAsset": null,
"_N$dragonAtlasAsset": null,
"_N$_defaultArmatureIndex": 0,
"_N$_animationIndex": 0,
"_N$_defaultCacheMode": 0,
"_N$timeScale": 1,
"_N$debugBones": false,
"_N$enableBatch": false,
"_id": ""
},
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 1
},
"asset": {
"__uuid__": "08949af0-f133-4990-8a03-95403eb67c2d"
},
"fileId": "e1c/JLshlN0LFqVX1GxhfZ",
"sync": false
},
{
"__type__": "cc.Node",
"_name": "lettters",
"_objFlags": 0,
"_parent": {
"__id__": 1
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 10
}
],
"_prefab": {
"__id__": 11
},
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 196.52,
"height": 100
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
-67.062,
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": ""
},
{
"__type__": "cc.Layout",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 9
},
"_enabled": true,
"_layoutSize": {
"__type__": "cc.Size",
"width": 196.52,
"height": 100
},
"_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": 0,
"_N$spacingY": 0,
"_N$verticalDirection": 1,
"_N$horizontalDirection": 0,
"_N$affectedByScale": false,
"_id": ""
},
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 1
},
"asset": {
"__uuid__": "08949af0-f133-4990-8a03-95403eb67c2d"
},
"fileId": "eb5FjSmjtPYoJic5tsedLK",
"sync": false
},
{
"__type__": "cc.Node",
"_name": "wrong",
"_objFlags": 0,
"_parent": {
"__id__": 1
},
"_children": [
{
"__id__": 13
},
{
"__id__": 16
}
],
"_active": true,
"_components": [],
"_prefab": {
"__id__": 22
},
"_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,
0,
0,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": ""
},
{
"__type__": "cc.Node",
"_name": "combined-shape",
"_objFlags": 0,
"_parent": {
"__id__": 12
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 14
}
],
"_prefab": {
"__id__": 15
},
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 179,
"height": 179
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
74.357,
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": ""
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 13
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "477b31e1-2f92-4ef6-965a-4a8e7e2f7991"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": ""
},
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 1
},
"asset": {
"__uuid__": "08949af0-f133-4990-8a03-95403eb67c2d"
},
"fileId": "6bh5TmB0NMdrZ+vNxpm6Yo",
"sync": false
},
{
"__type__": "cc.Node",
"_name": "rightLetters",
"_objFlags": 0,
"_parent": {
"__id__": 12
},
"_children": [
{
"__id__": 17
}
],
"_active": true,
"_components": [
{
"__id__": 20
}
],
"_prefab": {
"__id__": 21
},
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 209,
"height": 131
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
-160.545,
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": ""
},
{
"__type__": "cc.Node",
"_name": "layout",
"_objFlags": 0,
"_parent": {
"__id__": 16
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 18
}
],
"_prefab": {
"__id__": 19
},
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 0,
"height": 80
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
-28.18,
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": ""
},
{
"__type__": "cc.Layout",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 17
},
"_enabled": true,
"_layoutSize": {
"__type__": "cc.Size",
"width": 0,
"height": 80
},
"_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": 0,
"_N$spacingY": 0,
"_N$verticalDirection": 1,
"_N$horizontalDirection": 0,
"_N$affectedByScale": false,
"_id": ""
},
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 1
},
"asset": {
"__uuid__": "08949af0-f133-4990-8a03-95403eb67c2d"
},
"fileId": "d3j7sRqlFBRLLRwoMFksKC",
"sync": false
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 16
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "e4497b56-6ddf-4bcc-a012-c4b99aa3ac1d"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": ""
},
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 1
},
"asset": {
"__uuid__": "08949af0-f133-4990-8a03-95403eb67c2d"
},
"fileId": "daenbIrzBKxrxIfSDYOZOu",
"sync": false
},
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 1
},
"asset": {
"__uuid__": "08949af0-f133-4990-8a03-95403eb67c2d"
},
"fileId": "87lIjrXuVKPYviqlIuUFIy",
"sync": false
},
{
"__type__": "1a39fg8yKJA15ndKSiBXqsN",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
},
"_enabled": true,
"pfbLetter": {
"__uuid__": "b4cceb6a-30d5-400a-ac0f-9fb6961a728b"
},
"dragonBone": {
"__id__": 7
},
"_id": ""
},
{
"__type__": "cc.Animation",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
},
"_enabled": true,
"_defaultClip": null,
"_clips": [
{
"__uuid__": "15ba7314-ae90-4f24-82d2-41fafddb7553"
},
{
"__uuid__": "380b1c1a-7cb2-484d-88ea-a56bdb59cb4a"
}
],
"playOnLoad": false,
"_id": ""
},
{
"__type__": "cc.BlockInputEvents",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
},
"_enabled": true,
"_id": ""
},
{
"__type__": "e22e11e0CVGPajfhd4ljXke",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
},
"_enabled": true,
"FitType": 1,
"_id": ""
},
{
"__type__": "cc.PrefabInfo",
"root": {
"__id__": 1
},
"asset": {
"__uuid__": "08949af0-f133-4990-8a03-95403eb67c2d"
},
"fileId": "7clMl2GbFKqphcx/dFidIz",
"sync": false
}
]
\ No newline at end of file
play/assets/tmpGame/prefabs/LayerResult.prefab.meta
0 → 100644
View file @
fde501d7
{
"ver": "1.2.7",
"uuid": "08949af0-f133-4990-8a03-95403eb67c2d",
"optimizationPolicy": "AUTO",
"asyncLoadAssets": false,
"readonly": false,
"subMetas": {}
}
\ No newline at end of file
play/assets/tmpGame/prefabs/coach1.prefab
View file @
fde501d7
...
@@ -217,7 +217,7 @@
...
@@ -217,7 +217,7 @@
},
},
"_contentSize": {
"_contentSize": {
"__type__": "cc.Size",
"__type__": "cc.Size",
"width": 1
07.44999999999999
,
"width": 1
5.35
,
"height": 37.8
"height": 37.8
},
},
"_anchorPoint": {
"_anchorPoint": {
...
@@ -264,7 +264,7 @@
...
@@ -264,7 +264,7 @@
"_enabled": true,
"_enabled": true,
"_layoutSize": {
"_layoutSize": {
"__type__": "cc.Size",
"__type__": "cc.Size",
"width": 1
07.44999999999999
,
"width": 1
5.35
,
"height": 37.8
"height": 37.8
},
},
"_resize": 1,
"_resize": 1,
...
...
play/assets/tmpGame/scene/Scene.fire
View file @
fde501d7
...
@@ -78,19 +78,22 @@
...
@@ -78,19 +78,22 @@
"__id__": 7
"__id__": 7
},
},
{
{
"__id__": 5
0
"__id__": 5
6
}
}
],
],
"_active": true,
"_active": true,
"_components": [
"_components": [
{
{
"__id__":
59
"__id__":
65
},
},
{
{
"__id__": 6
0
"__id__": 6
6
},
},
{
{
"__id__": 61
"__id__": 67
},
{
"__id__": 68
}
}
],
],
"_prefab": null,
"_prefab": null,
...
@@ -180,7 +183,7 @@
...
@@ -180,7 +183,7 @@
"array": [
"array": [
0,
0,
0,
0,
4
17.467561751687
4,
4
03.611155291136
4,
0,
0,
0,
0,
0,
0,
...
@@ -247,7 +250,7 @@
...
@@ -247,7 +250,7 @@
"__id__": 2
"__id__": 2
},
},
"_children": [],
"_children": [],
"_active":
fals
e,
"_active":
tru
e,
"_components": [
"_components": [
{
{
"__id__": 6
"__id__": 6
...
@@ -370,12 +373,15 @@
...
@@ -370,12 +373,15 @@
},
},
{
{
"__id__": 39
"__id__": 39
},
{
"__id__": 49
}
}
],
],
"_active": true,
"_active": true,
"_components": [
"_components": [
{
{
"__id__":
49
"__id__":
55
}
}
],
],
"_prefab": null,
"_prefab": null,
...
@@ -2200,6 +2206,292 @@
...
@@ -2200,6 +2206,292 @@
"_originalHeight": 0,
"_originalHeight": 0,
"_id": "682q42JzxCM6NpInrzcGi2"
"_id": "682q42JzxCM6NpInrzcGi2"
},
},
{
"__type__": "cc.Node",
"_name": "btnRestartt",
"_objFlags": 0,
"_parent": {
"__id__": 7
},
"_children": [
{
"__id__": 50
}
],
"_active": true,
"_components": [
{
"__id__": 52
},
{
"__id__": 54
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 50,
"height": 57
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
570.127,
-320.775,
0,
0,
0,
0,
1,
1,
1,
0
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "da24qH3NRPDq8SLMZDX9kH"
},
{
"__type__": "cc.Node",
"_name": "invalid-name_8",
"_objFlags": 0,
"_parent": {
"__id__": 49
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 51
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 47,
"height": 57
},
"_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": "54sXFIbxVGm6MnqdYEC4N2"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 50
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "98eb65c4-d3b8-4dda-b527-e422827b5225"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "e6bYB8SS9OSLzjeecSTuOd"
},
{
"__type__": "cc.Button",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 49
},
"_enabled": true,
"_normalMaterial": null,
"_grayMaterial": null,
"duration": 0.1,
"zoomScale": 1.2,
"clickEvents": [
{
"__id__": 53
}
],
"_N$interactable": true,
"_N$enableAutoGrayEffect": false,
"_N$transition": 3,
"transition": 3,
"_N$normalColor": {
"__type__": "cc.Color",
"r": 230,
"g": 230,
"b": 230,
"a": 255
},
"_N$pressedColor": {
"__type__": "cc.Color",
"r": 200,
"g": 200,
"b": 200,
"a": 255
},
"pressedColor": {
"__type__": "cc.Color",
"r": 200,
"g": 200,
"b": 200,
"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": 120,
"g": 120,
"b": 120,
"a": 200
},
"_N$normalSprite": {
"__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952"
},
"_N$pressedSprite": {
"__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a"
},
"pressedSprite": {
"__uuid__": "e9ec654c-97a2-4787-9325-e6a10375219a"
},
"_N$hoverSprite": {
"__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952"
},
"hoverSprite": {
"__uuid__": "f0048c10-f03e-4c97-b9d3-3506e1d58952"
},
"_N$disabledSprite": {
"__uuid__": "29158224-f8dd-4661-a796-1ffab537140e"
},
"_N$target": {
"__id__": 49
},
"_id": "c4/0LlKOhNGYxw9Qf+RGtc"
},
{
"__type__": "cc.ClickEvent",
"target": {
"__id__": 2
},
"component": "",
"_componentId": "f4edeRi+NdAabqAkVYRwFjK",
"handler": "startRunTrain",
"customEventData": ""
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 49
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 36,
"_left": 0,
"_right": 44.87300000000005,
"_top": 0,
"_bottom": 10.725000000000023,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 0,
"_originalHeight": 0,
"_id": "f09+2Nb4VHkJP4XueVoe1+"
},
{
{
"__type__": "e22e11e0CVGPajfhd4ljXke",
"__type__": "e22e11e0CVGPajfhd4ljXke",
"_name": "",
"_name": "",
...
@@ -2220,19 +2512,19 @@
...
@@ -2220,19 +2512,19 @@
},
},
"_children": [
"_children": [
{
{
"__id__": 5
1
"__id__": 5
7
},
},
{
{
"__id__": 5
3
"__id__": 5
9
},
},
{
{
"__id__":
56
"__id__":
62
}
}
],
],
"_active": true,
"_active": true,
"_components": [
"_components": [
{
{
"__id__":
58
"__id__":
64
}
}
],
],
"_prefab": null,
"_prefab": null,
...
@@ -2258,7 +2550,7 @@
...
@@ -2258,7 +2550,7 @@
"__type__": "TypedArray",
"__type__": "TypedArray",
"ctor": "Float64Array",
"ctor": "Float64Array",
"array": [
"array": [
1165.378
,
640
,
0,
0,
0,
0,
0,
0,
...
@@ -2288,13 +2580,13 @@
...
@@ -2288,13 +2580,13 @@
"_name": "layerCoach",
"_name": "layerCoach",
"_objFlags": 0,
"_objFlags": 0,
"_parent": {
"_parent": {
"__id__": 5
0
"__id__": 5
6
},
},
"_children": [],
"_children": [],
"_active": true,
"_active": true,
"_components": [
"_components": [
{
{
"__id__": 5
2
"__id__": 5
8
}
}
],
],
"_prefab": null,
"_prefab": null,
...
@@ -2320,7 +2612,7 @@
...
@@ -2320,7 +2612,7 @@
"__type__": "TypedArray",
"__type__": "TypedArray",
"ctor": "Float64Array",
"ctor": "Float64Array",
"array": [
"array": [
632.764
,
528.736
,
0,
0,
0,
0,
0,
0,
...
@@ -2350,7 +2642,7 @@
...
@@ -2350,7 +2642,7 @@
"_name": "",
"_name": "",
"_objFlags": 0,
"_objFlags": 0,
"node": {
"node": {
"__id__": 5
1
"__id__": 5
7
},
},
"_enabled": true,
"_enabled": true,
"_layoutSize": {
"_layoutSize": {
...
@@ -2382,11 +2674,11 @@
...
@@ -2382,11 +2674,11 @@
"_name": "train",
"_name": "train",
"_objFlags": 0,
"_objFlags": 0,
"_parent": {
"_parent": {
"__id__": 5
0
"__id__": 5
6
},
},
"_children": [
"_children": [
{
{
"__id__":
54
"__id__":
60
}
}
],
],
"_active": true,
"_active": true,
...
@@ -2414,7 +2706,7 @@
...
@@ -2414,7 +2706,7 @@
"__type__": "TypedArray",
"__type__": "TypedArray",
"ctor": "Float64Array",
"ctor": "Float64Array",
"array": [
"array": [
263.124
,
159.096
,
0,
0,
0,
0,
0,
0,
...
@@ -2444,13 +2736,13 @@
...
@@ -2444,13 +2736,13 @@
"_name": "train copy",
"_name": "train copy",
"_objFlags": 0,
"_objFlags": 0,
"_parent": {
"_parent": {
"__id__": 5
3
"__id__": 5
9
},
},
"_children": [],
"_children": [],
"_active": true,
"_active": true,
"_components": [
"_components": [
{
{
"__id__":
55
"__id__":
61
}
}
],
],
"_prefab": null,
"_prefab": null,
...
@@ -2506,7 +2798,7 @@
...
@@ -2506,7 +2798,7 @@
"_name": "",
"_name": "",
"_objFlags": 0,
"_objFlags": 0,
"node": {
"node": {
"__id__":
54
"__id__":
60
},
},
"_enabled": true,
"_enabled": true,
"_materials": [
"_materials": [
...
@@ -2546,13 +2838,13 @@
...
@@ -2546,13 +2838,13 @@
"_name": "finger",
"_name": "finger",
"_objFlags": 0,
"_objFlags": 0,
"_parent": {
"_parent": {
"__id__": 5
0
"__id__": 5
6
},
},
"_children": [],
"_children": [],
"_active": false,
"_active": false,
"_components": [
"_components": [
{
{
"__id__":
57
"__id__":
63
}
}
],
],
"_prefab": null,
"_prefab": null,
...
@@ -2578,7 +2870,7 @@
...
@@ -2578,7 +2870,7 @@
"__type__": "TypedArray",
"__type__": "TypedArray",
"ctor": "Float64Array",
"ctor": "Float64Array",
"array": [
"array": [
674.524
,
570.496
,
-194.258,
-194.258,
0,
0,
0,
0,
...
@@ -2608,7 +2900,7 @@
...
@@ -2608,7 +2900,7 @@
"_name": "",
"_name": "",
"_objFlags": 0,
"_objFlags": 0,
"node": {
"node": {
"__id__":
56
"__id__":
62
},
},
"_enabled": true,
"_enabled": true,
"_materials": [
"_materials": [
...
@@ -2648,7 +2940,7 @@
...
@@ -2648,7 +2940,7 @@
"_name": "",
"_name": "",
"_objFlags": 0,
"_objFlags": 0,
"node": {
"node": {
"__id__": 5
0
"__id__": 5
6
},
},
"_enabled": true,
"_enabled": true,
"_defaultClip": null,
"_defaultClip": null,
...
@@ -2686,16 +2978,19 @@
...
@@ -2686,16 +2978,19 @@
},
},
"_enabled": true,
"_enabled": true,
"dragonBone": {
"dragonBone": {
"__id__":
55
"__id__":
61
},
},
"audEnter": {
"audEnter": {
"__uuid__": "
3b4d792e-6e1e-4a06-9f07-8368268755b7
"
"__uuid__": "
dcd876c9-19be-4007-8074-069e28524108
"
},
},
"audTrain": {
"audTrain": {
"__uuid__": "
a7e0fc53-293f-4b46-81ca-8e1c62a84a9
c"
"__uuid__": "
97bbdd40-339a-4483-8495-cad59f594c4
c"
},
},
"layerCoach": {
"layerCoach": {
"__id__": 51
"__id__": 57
},
"pfbLayerResult": {
"__uuid__": "08949af0-f133-4990-8a03-95403eb67c2d"
},
},
"pfbItemCoaches": [
"pfbItemCoaches": [
{
{
...
@@ -2722,6 +3017,33 @@
...
@@ -2722,6 +3017,33 @@
},
},
"_enabled": true,
"_enabled": true,
"FitType": 2,
"FitType": 2,
"_id": "19I7u27pdHvrow1q9oRKpe"
"_id": "0bxk3IyrNEPqYSJiFsqdX3"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 2
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 18,
"_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": 0,
"_originalHeight": 0,
"_id": "d8oKEvhO9LT4T0A9yfsl+M"
}
}
]
]
\ No newline at end of file
play/assets/tmpGame/script/ItemCoach1.js
View file @
fde501d7
...
@@ -34,34 +34,39 @@ cc.Class({
...
@@ -34,34 +34,39 @@ cc.Class({
color
=
'
blue
'
;
color
=
'
blue
'
;
}
}
let
letter
=
this
.
data
.
text
.
charAt
(
i
);
let
letter
=
this
.
data
.
text
.
charAt
(
i
);
if
(
this
.
data
.
letter
s
[
i
]
==
1
)
{
if
(
this
.
data
.
letter
Index
==
i
)
{
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
color
,
letter
);
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
color
,
letter
);
}
else
{
}
else
{
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
'
normal
'
,
letter
);
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
'
normal
'
,
letter
);
}
}
}
}
this
.
layerLetters
.
getComponent
(
cc
.
Layout
).
updateLayout
();
this
.
layerLetters
.
getComponent
(
cc
.
Layout
).
updateLayout
();
if
(
this
.
data
.
text
.
length
<=
7
)
{
if
(
this
.
data
.
text
.
length
<=
7
)
{
return
;
return
;
}
}
let
maxWidth
=
107.45
;
let
maxWidth
=
107.45
;
let
scale
=
maxWidth
/
this
.
layerLetters
.
width
;
let
scale
=
maxWidth
/
this
.
layerLetters
.
width
;
if
(
!
window
.
minWordScale
)
{
if
(
!
window
.
minWordScale
)
{
window
.
minWordScale
=
scale
;
window
.
minWordScale
=
scale
;
}
else
if
(
scale
<
window
.
minWordScale
)
{
}
else
if
(
scale
<
window
.
minWordScale
)
{
window
.
minWordScale
=
scale
;
window
.
minWordScale
=
scale
;
}
}
},
},
initLayerLettersScale
()
{
initLayerLettersScale
()
{
this
.
scheduleOnce
(()
=>
{
this
.
scheduleOnce
(()
=>
{
this
.
layerLetters
.
scale
=
window
.
minWordScale
;
this
.
layerLetters
.
scale
=
window
.
minWordScale
;
})
})
},
},
onClick
()
{
onClick
()
{
console
.
log
(
this
.
data
.
text
);
if
(
window
.
isPlayEnter
)
{
return
}
let
event
=
new
cc
.
Event
.
EventCustom
(
'
showResult
'
,
true
);
event
.
setUserData
(
this
.
index
);
this
.
node
.
dispatchEvent
(
event
);
},
},
// update (dt) {},
// update (dt) {},
});
});
play/assets/tmpGame/script/ItemCoach2.js
View file @
fde501d7
...
@@ -34,34 +34,39 @@ cc.Class({
...
@@ -34,34 +34,39 @@ cc.Class({
color
=
'
blue
'
;
color
=
'
blue
'
;
}
}
let
letter
=
this
.
data
.
text
.
charAt
(
i
);
let
letter
=
this
.
data
.
text
.
charAt
(
i
);
if
(
this
.
data
.
letter
s
[
i
]
==
1
)
{
if
(
this
.
data
.
letter
Index
==
i
)
{
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
color
,
letter
);
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
color
,
letter
);
}
else
{
}
else
{
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
'
normal
'
,
letter
);
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
'
normal
'
,
letter
);
}
}
}
}
this
.
layerLetters
.
getComponent
(
cc
.
Layout
).
updateLayout
();
this
.
layerLetters
.
getComponent
(
cc
.
Layout
).
updateLayout
();
if
(
this
.
data
.
text
.
length
<=
7
)
{
if
(
this
.
data
.
text
.
length
<=
7
)
{
return
;
return
;
}
}
let
maxWidth
=
107.45
;
let
maxWidth
=
107.45
;
let
scale
=
maxWidth
/
this
.
layerLetters
.
width
;
let
scale
=
maxWidth
/
this
.
layerLetters
.
width
;
if
(
!
window
.
minWordScale
)
{
if
(
!
window
.
minWordScale
)
{
window
.
minWordScale
=
scale
;
window
.
minWordScale
=
scale
;
}
else
if
(
scale
<
window
.
minWordScale
)
{
}
else
if
(
scale
<
window
.
minWordScale
)
{
window
.
minWordScale
=
scale
;
window
.
minWordScale
=
scale
;
}
}
},
},
initLayerLettersScale
()
{
initLayerLettersScale
()
{
this
.
scheduleOnce
(()
=>
{
this
.
scheduleOnce
(()
=>
{
this
.
layerLetters
.
scale
=
window
.
minWordScale
;
this
.
layerLetters
.
scale
=
window
.
minWordScale
;
})
})
},
},
onClick
()
{
onClick
()
{
console
.
log
(
this
.
data
.
text
);
if
(
window
.
isPlayEnter
)
{
return
}
let
event
=
new
cc
.
Event
.
EventCustom
(
'
showResult
'
,
true
);
event
.
setUserData
(
this
.
index
);
this
.
node
.
dispatchEvent
(
event
);
},
},
// update (dt) {},
// update (dt) {},
});
});
play/assets/tmpGame/script/ItemCoach3.js
View file @
fde501d7
...
@@ -34,34 +34,39 @@ cc.Class({
...
@@ -34,34 +34,39 @@ cc.Class({
color
=
'
blue
'
;
color
=
'
blue
'
;
}
}
let
letter
=
this
.
data
.
text
.
charAt
(
i
);
let
letter
=
this
.
data
.
text
.
charAt
(
i
);
if
(
this
.
data
.
letter
s
[
i
]
==
1
)
{
if
(
this
.
data
.
letter
Index
==
i
)
{
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
color
,
letter
);
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
color
,
letter
);
}
else
{
}
else
{
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
'
normal
'
,
letter
);
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
'
normal
'
,
letter
);
}
}
}
}
this
.
layerLetters
.
getComponent
(
cc
.
Layout
).
updateLayout
();
this
.
layerLetters
.
getComponent
(
cc
.
Layout
).
updateLayout
();
if
(
this
.
data
.
text
.
length
<=
7
)
{
if
(
this
.
data
.
text
.
length
<=
7
)
{
return
;
return
;
}
}
let
maxWidth
=
107.45
;
let
maxWidth
=
107.45
;
let
scale
=
maxWidth
/
this
.
layerLetters
.
width
;
let
scale
=
maxWidth
/
this
.
layerLetters
.
width
;
if
(
!
window
.
minWordScale
)
{
if
(
!
window
.
minWordScale
)
{
window
.
minWordScale
=
scale
;
window
.
minWordScale
=
scale
;
}
else
if
(
scale
<
window
.
minWordScale
)
{
}
else
if
(
scale
<
window
.
minWordScale
)
{
window
.
minWordScale
=
scale
;
window
.
minWordScale
=
scale
;
}
}
},
},
initLayerLettersScale
()
{
initLayerLettersScale
()
{
this
.
scheduleOnce
(()
=>
{
this
.
scheduleOnce
(()
=>
{
this
.
layerLetters
.
scale
=
window
.
minWordScale
;
this
.
layerLetters
.
scale
=
window
.
minWordScale
;
})
})
},
},
onClick
()
{
onClick
()
{
console
.
log
(
this
.
data
.
text
);
if
(
window
.
isPlayEnter
)
{
return
}
let
event
=
new
cc
.
Event
.
EventCustom
(
'
showResult
'
,
true
);
event
.
setUserData
(
this
.
index
);
this
.
node
.
dispatchEvent
(
event
);
},
},
// update (dt) {},
// update (dt) {},
});
});
play/assets/tmpGame/script/ItemCoach4.js
View file @
fde501d7
...
@@ -34,34 +34,39 @@ cc.Class({
...
@@ -34,34 +34,39 @@ cc.Class({
color
=
'
blue
'
;
color
=
'
blue
'
;
}
}
let
letter
=
this
.
data
.
text
.
charAt
(
i
);
let
letter
=
this
.
data
.
text
.
charAt
(
i
);
if
(
this
.
data
.
letter
s
[
i
]
==
1
)
{
if
(
this
.
data
.
letter
Index
==
i
)
{
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
color
,
letter
);
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
color
,
letter
);
}
else
{
}
else
{
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
'
normal
'
,
letter
);
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
'
normal
'
,
letter
);
}
}
}
}
this
.
layerLetters
.
getComponent
(
cc
.
Layout
).
updateLayout
();
this
.
layerLetters
.
getComponent
(
cc
.
Layout
).
updateLayout
();
if
(
this
.
data
.
text
.
length
<=
7
)
{
if
(
this
.
data
.
text
.
length
<=
7
)
{
return
;
return
;
}
}
let
maxWidth
=
107.45
;
let
maxWidth
=
107.45
;
let
scale
=
maxWidth
/
this
.
layerLetters
.
width
;
let
scale
=
maxWidth
/
this
.
layerLetters
.
width
;
if
(
!
window
.
minWordScale
)
{
if
(
!
window
.
minWordScale
)
{
window
.
minWordScale
=
scale
;
window
.
minWordScale
=
scale
;
}
else
if
(
scale
<
window
.
minWordScale
)
{
}
else
if
(
scale
<
window
.
minWordScale
)
{
window
.
minWordScale
=
scale
;
window
.
minWordScale
=
scale
;
}
}
},
},
initLayerLettersScale
()
{
initLayerLettersScale
()
{
this
.
scheduleOnce
(()
=>
{
this
.
scheduleOnce
(()
=>
{
this
.
layerLetters
.
scale
=
window
.
minWordScale
;
this
.
layerLetters
.
scale
=
window
.
minWordScale
;
})
})
},
},
onClick
()
{
onClick
()
{
console
.
log
(
this
.
data
.
text
);
if
(
window
.
isPlayEnter
)
{
return
}
let
event
=
new
cc
.
Event
.
EventCustom
(
'
showResult
'
,
true
);
event
.
setUserData
(
this
.
index
);
this
.
node
.
dispatchEvent
(
event
);
},
},
// update (dt) {},
// update (dt) {},
});
});
play/assets/tmpGame/script/ItemLetter.js
View file @
fde501d7
...
@@ -7,13 +7,16 @@ cc.Class({
...
@@ -7,13 +7,16 @@ cc.Class({
colorRed
:
'
#E11C24
'
,
colorRed
:
'
#E11C24
'
,
colorBlue
:
'
#0093CD
'
,
colorBlue
:
'
#0093CD
'
,
colorNormal
:
'
#3C3048
'
,
colorNormal
:
'
#3C3048
'
,
colorRed2
:
'
#ff1200
'
,
},
},
onLoad
()
{
onLoad
()
{
this
.
label
=
this
.
getComponent
(
cc
.
Label
);
this
.
label
=
this
.
getComponent
(
cc
.
Label
);
},
},
setData
(
strColor
,
letter
)
{
setData
(
strColor
,
letter
,
fontSize
=
30
)
{
this
.
label
.
fontSize
=
fontSize
;
this
.
label
.
lineHeight
=
fontSize
;
this
.
label
.
string
=
letter
;
this
.
label
.
string
=
letter
;
let
color
=
this
.
colorNormal
;
let
color
=
this
.
colorNormal
;
if
(
strColor
==
'
yellow
'
)
{
if
(
strColor
==
'
yellow
'
)
{
...
@@ -26,6 +29,8 @@ cc.Class({
...
@@ -26,6 +29,8 @@ cc.Class({
color
=
this
.
colorBlue
;
color
=
this
.
colorBlue
;
}
else
if
(
strColor
==
'
normal
'
)
{
}
else
if
(
strColor
==
'
normal
'
)
{
color
=
this
.
colorNormal
;
color
=
this
.
colorNormal
;
}
else
if
(
strColor
==
'
red2
'
)
{
color
=
this
.
colorRed2
;
}
}
this
.
scheduleOnce
(()
=>
{
this
.
scheduleOnce
(()
=>
{
this
.
node
.
color
=
new
cc
.
Color
().
fromHEX
(
color
);
this
.
node
.
color
=
new
cc
.
Color
().
fromHEX
(
color
);
...
...
play/assets/tmpGame/script/LayerResult.js
0 → 100644
View file @
fde501d7
cc
.
Class
({
extends
:
cc
.
Component
,
properties
:
{
pfbLetter
:
cc
.
Prefab
,
dragonBone
:
dragonBones
.
ArmatureDisplay
,
},
onLoad
()
{
this
.
layerLetters
=
this
.
node
.
getChildByName
(
'
lettters
'
);
this
.
layerRightLetters
=
cc
.
find
(
'
wrong/rightLetters/layout
'
,
this
.
node
);
},
setData
(
data
,
index
)
{
this
.
data
=
data
;
this
.
index
=
index
;
this
.
item
=
this
.
data
.
dataArray
[
this
.
index
];
this
.
loadDragonBone
();
this
.
initLetters
();
this
.
initRightLetters
();
this
.
setRightLettersX
();
this
.
playerResult
();
},
loadDragonBone
()
{
this
.
dragonBone
.
dragonAtlasAsset
=
null
;
this
.
dragonBone
.
dragonAsset
=
null
;
this
.
dragonBone
.
armatureName
=
''
;
var
imageUrl
=
this
.
item
.
tex_png
;
var
skeUrl
=
this
.
item
.
ske_json
;
var
atlasUrl
=
this
.
item
.
tex_json
;
imageUrl
=
'
http://127.0.0.1/walkingfish_tex.png
'
;
skeUrl
=
'
http://127.0.0.1/walkingfish_ske.json
'
;
atlasUrl
=
'
http://127.0.0.1/walkingfish_tex.json
'
;
cc
.
assetManager
.
loadAny
([{
url
:
atlasUrl
,
ext
:
'
.txt
'
},
{
url
:
skeUrl
,
ext
:
'
.txt
'
}],
(
error
,
assets
)
=>
{
if
(
error
)
{
console
.
log
(
error
)
}
else
{
cc
.
assetManager
.
loadRemote
(
imageUrl
,
(
error
,
texture
)
=>
{
if
(
error
)
{
console
.
log
(
error
)
}
else
{
var
atlas
=
new
dragonBones
.
DragonBonesAtlasAsset
();
atlas
.
_uuid
=
atlasUrl
;
atlas
.
atlasJson
=
assets
[
0
];
atlas
.
texture
=
texture
;
var
asset
=
new
dragonBones
.
DragonBonesAsset
();
asset
.
_uuid
=
skeUrl
;
asset
.
dragonBonesJson
=
assets
[
1
];
this
.
dragonBone
.
dragonAtlasAsset
=
atlas
;
this
.
dragonBone
.
dragonAsset
=
asset
;
let
data
=
asset
.
_dragonBonesJsonData
.
armature
[
0
];
if
(
!
data
){
return
;
}
this
.
dragonBone
.
armatureName
=
data
.
name
;
this
.
animationName
=
data
.
animation
[
0
].
name
;
}
});
}
});
},
initLetters
()
{
let
text
=
this
.
item
.
text
;
for
(
let
i
=
0
;
i
<
text
.
length
;
i
++
)
{
let
node
=
cc
.
instantiate
(
this
.
pfbLetter
);
node
.
parent
=
this
.
layerLetters
;
let
colorType
=
this
.
index
%
4
;
let
color
=
'
normal
'
;
if
(
colorType
==
0
)
{
color
=
'
yellow
'
;
}
else
if
(
colorType
==
1
)
{
color
=
'
green
'
;
}
else
if
(
colorType
==
2
)
{
color
=
'
red
'
;
}
else
if
(
colorType
==
3
)
{
color
=
'
blue
'
;
}
let
letter
=
text
.
charAt
(
i
);
if
(
this
.
item
.
letterIndex
==
i
)
{
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
color
,
letter
,
96
);
}
else
{
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
'
normal
'
,
letter
,
96
);
}
}
this
.
layerLetters
.
getComponent
(
cc
.
Layout
).
updateLayout
();
},
initRightLetters
()
{
if
(
/
[
a-z
]
/
.
test
(
this
.
data
.
letter1
)
||
/
[
A-Z
]
/
.
test
(
this
.
data
.
letter1
))
{
let
letter
=
this
.
data
.
letter1
.
toLowerCase
();
let
node1
=
cc
.
instantiate
(
this
.
pfbLetter
);
node1
.
parent
=
this
.
layerRightLetters
;
let
node2
=
cc
.
instantiate
(
this
.
pfbLetter
);
node2
.
parent
=
this
.
layerRightLetters
;
node1
.
getComponent
(
'
ItemLetter
'
).
setData
(
'
red2
'
,
letter
,
48
);
node2
.
getComponent
(
'
ItemLetter
'
).
setData
(
'
red2
'
,
letter
.
toUpperCase
(),
48
);
if
(
/
[
a-z
]
/
.
test
(
this
.
data
.
letter2
)
||
/
[
A-Z
]
/
.
test
(
this
.
data
.
letter2
))
{
let
node
=
cc
.
instantiate
(
this
.
pfbLetter
);
node
.
parent
=
this
.
layerRightLetters
;
node
.
getComponent
(
'
ItemLetter
'
).
setData
(
'
red2
'
,
'
,
'
,
48
);
}
}
if
(
/
[
a-z
]
/
.
test
(
this
.
data
.
letter2
)
||
/
[
A-Z
]
/
.
test
(
this
.
data
.
letter2
))
{
let
letter
=
this
.
data
.
letter2
.
toLowerCase
();
let
node1
=
cc
.
instantiate
(
this
.
pfbLetter
);
node1
.
parent
=
this
.
layerRightLetters
;
let
node2
=
cc
.
instantiate
(
this
.
pfbLetter
);
node2
.
parent
=
this
.
layerRightLetters
;
node1
.
getComponent
(
'
ItemLetter
'
).
setData
(
'
red2
'
,
letter
,
48
);
node2
.
getComponent
(
'
ItemLetter
'
).
setData
(
'
red2
'
,
letter
.
toUpperCase
(),
48
);
}
this
.
layerRightLetters
.
getComponent
(
cc
.
Layout
).
updateLayout
();
},
setRightLettersX
()
{
let
x
=
this
.
layerLetters
.
children
[
0
].
x
;
let
x2
=
x
-
3
;
this
.
layerRightLetters
.
parent
.
x
=
x2
;
},
playerResult
()
{
let
isRight
=
this
.
item
.
isRight
;
if
(
isRight
){
this
.
playRightResult
();
}
else
{
this
.
playWrongResult
();
}
},
playRightResult
(){
this
.
playAudMove
();
this
.
getComponent
(
cc
.
Animation
).
play
(
'
result1
'
);
this
.
scheduleOnce
(()
=>
{
this
.
playAudWord
(()
=>
{
this
.
playDragonBone
();
this
.
playAudRight
();
this
.
onPlayResultDone
();
});
},
0.5
)
},
playWrongResult
(){
this
.
playAudMove
();
this
.
getComponent
(
cc
.
Animation
).
play
(
'
result1
'
);
this
.
scheduleOnce
(()
=>
{
this
.
playAudWord
(()
=>
{
this
.
playDragonBone
();
this
.
playAudWrong
();
this
.
getComponent
(
cc
.
Animation
).
play
(
'
result2
'
);
this
.
onPlayResultDone
();
});
},
0.5
)
},
playDragonBone
(){
this
.
dragonBone
.
playAnimation
(
this
.
animationName
,
1
);
},
playAudMove
()
{
},
playAudWord
(
cb
)
{
this
.
item
.
shortAudio_url
=
'
http://127.0.0.1/imdrivingmycar.mp3
'
cc
.
assetManager
.
loadRemote
(
this
.
item
.
shortAudio_url
,
null
,
(
err
,
clip
)
=>
{
if
(
err
)
{
console
.
log
(
err
)
return
;
}
let
id
=
cc
.
audioEngine
.
play
(
clip
,
false
,
1
);
let
duration
=
cc
.
audioEngine
.
getDuration
(
id
);
this
.
scheduleOnce
(()
=>
{
cb
&&
cb
();
},
duration
)
});
},
playAudRight
(){
},
playAudWrong
(){
},
onPlayResultDone
(){
cc
.
tween
(
this
.
node
)
.
to
(
0.3
,{
opacity
:
0
})
.
call
(()
=>
{
this
.
node
.
destroy
();
})
.
start
()
},
// node.getComponent('ItemLetter').setData('red2', letter,48);
// update (dt) {},
});
play/assets/tmpGame/script/LayerResult.js.meta
0 → 100644
View file @
fde501d7
{
"ver": "1.0.8",
"uuid": "1a39f83c-c8a2-40d7-99dd-2928815eab0d",
"isPlugin": false,
"loadPluginInWeb": true,
"loadPluginInNative": true,
"loadPluginInEditor": false,
"subMetas": {}
}
\ No newline at end of file
play/assets/tmpGame/script/Scene.js
View file @
fde501d7
...
@@ -8,12 +8,14 @@ cc.Class({
...
@@ -8,12 +8,14 @@ cc.Class({
audEnter
:
cc
.
AudioClip
,
audEnter
:
cc
.
AudioClip
,
audTrain
:
cc
.
AudioClip
,
audTrain
:
cc
.
AudioClip
,
layerCoach
:
cc
.
Node
,
layerCoach
:
cc
.
Node
,
pfbLayerResult
:
cc
.
Prefab
,
pfbItemCoaches
:
[
cc
.
Prefab
],
pfbItemCoaches
:
[
cc
.
Prefab
],
},
},
// 生命周期 onLoad
// 生命周期 onLoad
onLoad
()
{
onLoad
()
{
this
.
initNodes
();
this
.
initNodes
();
this
.
initData
();
this
.
initSceneData
();
this
.
initSceneData
();
this
.
initSize
();
this
.
initSize
();
},
},
...
@@ -27,21 +29,49 @@ cc.Class({
...
@@ -27,21 +29,49 @@ cc.Class({
},
},
onEnable
()
{
onEnable
()
{
this
.
speedLevels
.
on
(
'
touchend
'
,
this
.
onSpeedTouchend
,
this
);
this
.
speedLevels
.
on
(
'
touchend
'
,
this
.
onSpeedTouchend
,
this
);
this
.
node
.
on
(
'
showResult
'
,
this
.
onShowResult
,
this
);
},
},
onDisable
()
{
onDisable
()
{
this
.
speedLevels
.
off
(
'
touchend
'
,
this
.
onSpeedTouchend
,
this
);
this
.
speedLevels
.
off
(
'
touchend
'
,
this
.
onSpeedTouchend
,
this
);
this
.
node
.
off
(
'
showResult
'
,
this
.
onShowResult
,
this
);
},
initData
()
{
// 所有全局变量 默认都是null
this
.
speedLevel
=
1
;
window
.
minWordScale
=
1
;
},
},
onSpeedTouchend
(
e
){
onSpeedTouchend
(
e
)
{
console
.
log
(
'
onToggleTouchend
'
)
if
(
window
.
isPlayEnter
)
{
return
}
let
pos
=
e
.
getLocation
();
let
pos
=
e
.
getLocation
();
console
.
log
(
pos
.
x
,
pos
.
y
)
pos
=
this
.
speedLevels
.
convertToNodeSpaceAR
(
pos
);
pos
=
this
.
speedLevels
.
convertToNodeSpaceAR
(
pos
);
console
.
log
(
pos
.
x
,
pos
.
y
)
if
(
pos
.
x
<
-
this
.
speedLevels
.
width
/
6
)
{
this
.
level1
.
active
=
true
;
this
.
level2
.
active
=
false
;
this
.
level3
.
active
=
false
;
this
.
speedLevel
=
1
;
this
.
restartRunTrain
();
}
else
if
(
pos
.
x
<
this
.
speedLevels
.
width
/
6
)
{
this
.
level1
.
active
=
false
;
this
.
level2
.
active
=
true
;
this
.
level3
.
active
=
false
;
this
.
speedLevel
=
2
;
this
.
restartRunTrain
();
}
else
{
this
.
level1
.
active
=
false
;
this
.
level2
.
active
=
false
;
this
.
level3
.
active
=
true
;
this
.
speedLevel
=
3
;
this
.
restartRunTrain
();
}
},
},
_imageResList
:
null
,
_imageResList
:
null
,
_audioResList
:
null
,
_audioResList
:
null
,
_animaResList
:
null
,
_animaResList
:
null
,
...
@@ -108,7 +138,7 @@ cc.Class({
...
@@ -108,7 +138,7 @@ cc.Class({
getDefaultData
()
{
getDefaultData
()
{
let
dataJson
=
'
{"contentObj":{"version":"1.1","key":"DataKey_Cocos_Test","haveCover":true,"dataArray":[{"type":"Image","text":"没 有 数 据","image_url":""},{"type":"Spine","text":"没 有 数 据","image_url":""}]}}
'
let
dataJson
=
'
{"contentObj":{"version":"1.1","key":"DataKey_Cocos_Test","haveCover":true,"dataArray":[{"type":"Image","text":"没 有 数 据","image_url":""},{"type":"Spine","text":"没 有 数 据","image_url":""}]}}
'
dataJson
=
'
{"contentObj":{"version":"1.1","key":"DataKey_Cocos_Test","dataArray":[{"text":"
computer","isRight":false,"shortAudio_url":"","image_url":"","letters":{"0":1,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0}},{"text":"apple","isRight":true,"shortAudio_url":"","image_url":"","letters":{"0":1,"1":0,"2":0,"3":0,"4":0}},{"text":"cat","isRight":false,"shortAudio_url":"","image_url":"","letters":{"0":1,"1":0,"2":0}},{"text":"bear","isRight":true,"shortAudio_url":"","image_url":"","letters":{"0":1,"1":0,"2":0,"3":0}},{"text":"banana","isRight":true,"shortAudio_url":"","image_url":"","letters":{"0":0,"1":1,"2":0,"3":1,"4":0,"5":1}}]
}}
'
;
dataJson
=
'
{"contentObj":{"version":"1.1","key":"DataKey_Cocos_Test","dataArray":[{"text":"
apple","isRight":true,"shortAudio_url":"","image_url":"","letterIndex":0},{"text":"banana","isRight":true,"shortAudio_url":"","image_url":"","letterIndex":0},{"text":"cat","isRight":false,"shortAudio_url":"","image_url":"","letterIndex":0},{"text":"test","isRight":false,"shortAudio_url":"","image_url":"","letterIndex":0}],"letter1":"a","letter2":"b"
}}
'
;
let
data
=
JSON
.
parse
(
dataJson
);
let
data
=
JSON
.
parse
(
dataJson
);
return
data
;
return
data
;
},
},
...
@@ -156,11 +186,12 @@ cc.Class({
...
@@ -156,11 +186,12 @@ cc.Class({
},
},
initLayerTrainPosition
()
{
initLayerTrainPosition
()
{
this
.
layerTrain
.
x
=
cc
.
view
.
getFrameSize
().
width
/
2
-
1
3
20
;
this
.
layerTrain
.
x
=
cc
.
view
.
getFrameSize
().
width
/
2
-
1
2
20
;
this
.
dragonBone
.
playAnimation
(
'
normal
'
,
-
1
);
this
.
dragonBone
.
playAnimation
(
'
normal
'
,
-
1
);
},
},
playAudioEntrer
()
{
playAudioEntrer
()
{
window
.
isPlayEnter
=
true
;
let
id
=
cc
.
audioEngine
.
play
(
this
.
audEnter
,
false
,
1
);
let
id
=
cc
.
audioEngine
.
play
(
this
.
audEnter
,
false
,
1
);
let
duration
=
cc
.
audioEngine
.
getDuration
(
id
);
let
duration
=
cc
.
audioEngine
.
getDuration
(
id
);
this
.
scheduleOnce
(()
=>
{
this
.
scheduleOnce
(()
=>
{
...
@@ -186,6 +217,7 @@ cc.Class({
...
@@ -186,6 +217,7 @@ cc.Class({
},
},
playAudioTrain
()
{
playAudioTrain
()
{
window
.
isPlayEnter
=
false
;
cc
.
tween
(
this
.
layerTrain
)
cc
.
tween
(
this
.
layerTrain
)
.
to
(
0.2
,
{
opacity
:
0
})
.
to
(
0.2
,
{
opacity
:
0
})
.
call
(()
=>
{
.
call
(()
=>
{
...
@@ -217,13 +249,21 @@ cc.Class({
...
@@ -217,13 +249,21 @@ cc.Class({
},
},
startRunTrain
()
{
startRunTrain
()
{
if
(
window
.
isPlayEnter
)
{
return
}
this
.
layerTrain
.
x
=
cc
.
view
.
getFrameSize
().
width
/
2
;
this
.
layerTrain
.
x
=
cc
.
view
.
getFrameSize
().
width
/
2
;
this
.
isTrainMove
=
true
;
this
.
isTrainMove
=
true
;
this
.
dragonBone
.
playAnimation
(
'
move
'
,
-
1
);
this
.
dragonBone
.
playAnimation
(
'
move
'
,
-
1
);
},
},
restartRunTrain
()
{
this
.
stopAudioTrain
();
this
.
playAudioTrain
();
},
checkTrainMoveDone
()
{
checkTrainMoveDone
()
{
let
width
=
this
.
layerCoach
.
width
+
77
0
;
let
width
=
this
.
layerCoach
.
width
+
68
0
;
let
width2
=
cc
.
view
.
getFrameSize
().
width
;
let
width2
=
cc
.
view
.
getFrameSize
().
width
;
if
(
this
.
layerTrain
.
x
<
-
width2
/
2
-
width
)
{
if
(
this
.
layerTrain
.
x
<
-
width2
/
2
-
width
)
{
console
.
log
(
'
结束
'
);
console
.
log
(
'
结束
'
);
...
@@ -232,18 +272,25 @@ cc.Class({
...
@@ -232,18 +272,25 @@ cc.Class({
}
}
},
},
getSpeed
()
{
if
(
this
.
speedLevel
==
1
)
{
return
50
;
}
else
if
(
this
.
speedLevel
==
2
)
{
return
120
;
}
else
if
(
this
.
speedLevel
==
3
)
{
return
200
;
}
},
update
(
dt
)
{
update
(
dt
)
{
if
(
!
this
.
isTrainMove
)
{
if
(
!
this
.
isTrainMove
)
{
return
;
return
;
}
}
this
.
layerTrain
.
x
-=
dt
*
50
;
this
.
layerTrain
.
x
-=
dt
*
this
.
getSpeed
()
;
this
.
checkTrainMoveDone
();
this
.
checkTrainMoveDone
();
},
},
initData
()
{
// 所有全局变量 默认都是null
},
initCoaches
()
{
initCoaches
()
{
let
l
=
this
.
data
.
contentObj
.
dataArray
.
length
;
let
l
=
this
.
data
.
contentObj
.
dataArray
.
length
;
...
@@ -257,7 +304,12 @@ cc.Class({
...
@@ -257,7 +304,12 @@ cc.Class({
}
}
},
},
onShowResult
(
event
){
let
index
=
event
.
getUserData
();
let
node
=
cc
.
instantiate
(
this
.
pfbLayerResult
);
node
.
parent
=
this
.
node
;
node
.
getComponent
(
'
LayerResult
'
).
setData
(
this
.
data
.
contentObj
,
index
);
},
...
...
play/settings/project.json
View file @
fde501d7
{
{
"last-module-event-record-time"
:
160
5580932326
,
"last-module-event-record-time"
:
160
6577997127
,
"migrate-history"
:
[
"migrate-history"
:
[
"cloud-function"
"cloud-function"
],
],
...
...
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