Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
Sbox_FT_08
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
Sbox_FT_08
Commits
04ee877a
Commit
04ee877a
authored
Nov 25, 2020
by
李维
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dev commit
parent
96c2aee5
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
439 additions
and
62 deletions
+439
-62
Scene.fire
play/assets/tmpGame/scene/Scene.fire
+274
-22
Cartoon.js
play/assets/tmpGame/script/Cartoon.js
+2
-0
GameLogic.js
play/assets/tmpGame/script/GameLogic.js
+125
-39
Scene.js
play/assets/tmpGame/script/Scene.js
+2
-1
btn_restart.png
play/assets/tmpGame/textures/btn_restart.png
+0
-0
btn_restart.png.meta
play/assets/tmpGame/textures/btn_restart.png.meta
+36
-0
No files found.
play/assets/tmpGame/scene/Scene.fire
View file @
04ee877a
...
...
@@ -114,19 +114,22 @@
"__id__": 179
},
{
"__id__": 180
"__id__": 182
},
{
"__id__": 183
}
],
"_active": true,
"_components": [
{
"__id__": 19
0
"__id__": 19
5
},
{
"__id__": 19
1
"__id__": 19
6
},
{
"__id__": 19
2
"__id__": 19
7
}
],
"_prefab": null,
...
...
@@ -8906,6 +8909,162 @@
"_atlas": null,
"_id": "63pCec93BEkpAqHho7leib"
},
{
"__type__": "cc.Node",
"_name": "bottomButtons",
"_objFlags": 0,
"_parent": {
"__id__": 2
},
"_children": [
{
"__id__": 180
}
],
"_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": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
509.947,
-325.202,
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": "2e692LFYZDk6UBiSgScZ5P"
},
{
"__type__": "cc.Node",
"_name": "restart",
"_objFlags": 0,
"_parent": {
"__id__": 179
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 181
}
],
"_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": [
-5,
7,
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": "00TYfHicZFSJPBfFzy95b+"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 180
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "607a2f52-a26c-434f-b331-afa9335ca6e6"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "ee6Xcxm+FBtZe7cQHxudAu"
},
{
"__type__": "cc.Node",
"_name": "MaskLayer",
...
...
@@ -8972,14 +9131,14 @@
"__id__": 2
},
"_children": [
{
"__id__": 181
},
{
"__id__": 184
},
{
"__id__": 187
},
{
"__id__": 192
}
],
"_active": false,
...
...
@@ -9037,11 +9196,11 @@
"_name": "font",
"_objFlags": 0,
"_parent": {
"__id__": 18
0
"__id__": 18
3
},
"_children": [
{
"__id__": 18
2
"__id__": 18
5
}
],
"_active": true,
...
...
@@ -9099,13 +9258,13 @@
"_name": "Comic Sans MS",
"_objFlags": 0,
"_parent": {
"__id__": 18
1
"__id__": 18
4
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 18
3
"__id__": 18
6
}
],
"_prefab": null,
...
...
@@ -9161,7 +9320,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 18
2
"__id__": 18
5
},
"_enabled": true,
"_materials": [],
...
...
@@ -9193,11 +9352,14 @@
"_name": "img",
"_objFlags": 0,
"_parent": {
"__id__": 18
0
"__id__": 18
3
},
"_children": [
{
"__id__": 185
"__id__": 188
},
{
"__id__": 190
}
],
"_active": true,
...
...
@@ -9255,13 +9417,13 @@
"_name": "card_demo",
"_objFlags": 0,
"_parent": {
"__id__": 18
4
"__id__": 18
7
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 18
6
"__id__": 18
9
}
],
"_prefab": null,
...
...
@@ -9317,7 +9479,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 18
5
"__id__": 18
8
},
"_enabled": true,
"_materials": [],
...
...
@@ -9340,16 +9502,106 @@
"_atlas": null,
"_id": "12k+fbxEVAxKNoPu5dURjd"
},
{
"__type__": "cc.Node",
"_name": "black",
"_objFlags": 0,
"_parent": {
"__id__": 187
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 191
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 100,
"height": 100
},
"_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": "dbn85feHFExo1q+nsQtN4n"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 190
},
"_enabled": true,
"_materials": [],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "7a2d99d6-2009-4341-83f8-f18980e6405d"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "86147ZoQBOpKg5wejgeXRf"
},
{
"__type__": "cc.Node",
"_name": "audio",
"_objFlags": 0,
"_parent": {
"__id__": 18
0
"__id__": 18
3
},
"_children": [
{
"__id__": 1
88
"__id__": 1
93
}
],
"_active": true,
...
...
@@ -9407,13 +9659,13 @@
"_name": "test_audio",
"_objFlags": 0,
"_parent": {
"__id__": 1
87
"__id__": 1
92
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 1
89
"__id__": 1
94
}
],
"_prefab": null,
...
...
@@ -9469,7 +9721,7 @@
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
88
"__id__": 1
93
},
"_enabled": true,
"_clip": {
...
...
play/assets/tmpGame/script/Cartoon.js
View file @
04ee877a
...
...
@@ -105,6 +105,8 @@ export default class Cartoon {
subscribeTouchEvent
(
key
,
callBack
)
{
if
(
!
this
.
touchEventCallback
[
key
])
{
this
.
touchEventCallback
[
key
]
=
callBack
this
.
elements
[
key
].
node
.
off
(
cc
.
Node
.
EventType
.
TOUCH_START
)
this
.
elements
[
key
].
node
.
on
(
cc
.
Node
.
EventType
.
TOUCH_START
,
()
=>
{
if
(
this
.
touchEventCallback
[
key
])
{
this
.
touchEventCallback
[
key
]()
...
...
play/assets/tmpGame/script/GameLogic.js
View file @
04ee877a
...
...
@@ -15,6 +15,7 @@ export default class GameLogic {
m_currentQuestion
=
-
1
;
m_questionDone
=
false
;
m_currentQuestionArray
=
[]
m_gameEnd
=
false
;
constructor
(
formData
,
systemOption
)
{
this
.
g_systemOption
=
systemOption
;
this
.
g_canvas
=
cc
.
find
(
'
Canvas
'
);
...
...
@@ -39,6 +40,8 @@ export default class GameLogic {
this
.
initImageCards
();
this
.
initTitle
();
this
.
loadQuestion
();
this
.
initBottomButtons
();
this
.
initMaskLayer
();
// this.initQuestionPannel();
// this.initButtons();
// this.initMaskLayer();
...
...
@@ -58,10 +61,14 @@ export default class GameLogic {
}
initNodes
()
{
let
dataLength
=
this
.
g_formData
.
dataArray
.
length
;
this
.
g_cartoon
.
initCartoonElement
(
"
title_text
"
,
this
.
g_cartoon
.
getNodeByPath
(
`Canvas/title/text`
))
for
(
let
index
=
0
;
index
<
10
;
index
++
)
{
const
card
=
this
.
g_cartoon
.
initCartoonElement
(
`card_
${
index
+
1
}
`
,
this
.
g_cartoon
.
getNodeByPath
(
`Canvas/card_
${
index
+
1
}
`
))
card
.
node
.
zIndex
=
1
if
(
index
>=
dataLength
)
{
card
.
node
.
active
=
false
;
}
this
.
g_cartoon
.
initCartoonElement
(
`card_
${
index
+
1
}
_normal`
,
this
.
g_cartoon
.
getNodeByPath
(
`Canvas/card_
${
index
+
1
}
/normal`
));
this
.
g_cartoon
.
initCartoonElement
(
`card_
${
index
+
1
}
_selected`
,
this
.
g_cartoon
.
getNodeByPath
(
`Canvas/card_
${
index
+
1
}
/selected`
));
this
.
g_cartoon
.
initCartoonElement
(
`card_
${
index
+
1
}
_bell`
,
this
.
g_cartoon
.
getNodeByPath
(
`Canvas/card_
${
index
+
1
}
/bell`
))
...
...
@@ -69,6 +76,16 @@ export default class GameLogic {
this
.
g_cartoon
.
initCartoonElement
(
`card_
${
index
+
1
}
_bell_outline`
,
this
.
g_cartoon
.
getNodeByPath
(
`Canvas/card_
${
index
+
1
}
/bell/bell_outline`
));
this
.
g_cartoon
.
initCartoonElement
(
`card_
${
index
+
1
}
_image_container`
,
this
.
g_cartoon
.
getNodeByPath
(
`Canvas/card_
${
index
+
1
}
/container/image`
));
}
if
(
dataLength
==
0
)
{
this
.
g_cartoon
.
getNodeByPath
(
`Canvas/shengzi/line_1`
).
active
=
false
;
this
.
g_cartoon
.
getNodeByPath
(
`Canvas/shengzi/line_2`
).
active
=
false
;
}
else
if
(
dataLength
<=
5
)
{
this
.
g_cartoon
.
getNodeByPath
(
`Canvas/shengzi/line_2`
).
active
=
false
;
}
this
.
g_cartoon
.
initCartoonElement
(
`bottomButtons`
,
this
.
g_cartoon
.
getNodeByPath
(
`Canvas/bottomButtons`
));
this
.
g_cartoon
.
initCartoonElement
(
`restart_button`
,
this
.
g_cartoon
.
getNodeByPath
(
`Canvas/bottomButtons/restart`
));
}
initBg
()
{
...
...
@@ -92,13 +109,27 @@ export default class GameLogic {
bgNodeTitle
.
y
=
cc
.
winSize
.
height
/
2
-
bgNodeTitle
.
height
/
2
-
50
bgNodeSnow
.
y
=
-
cc
.
winSize
.
height
/
2
+
bgNodeSnow
.
height
/
2
bgNodeShuicao
.
y
=
-
cc
.
winSize
.
height
/
2
+
bgNodeShuicao
.
height
/
2
const
cardPos
=
[
{
x
:
-
500
,
y
:
128
},
{
x
:
-
250
,
y
:
128
},
{
x
:
0
,
y
:
128
},
{
x
:
250
,
y
:
128
},
{
x
:
500
,
y
:
128
},
{
x
:
-
500
,
y
:
-
128
},
{
x
:
-
250
,
y
:
-
128
},
{
x
:
0
,
y
:
-
128
},
{
x
:
250
,
y
:
-
128
},
{
x
:
500
,
y
:
-
128
}
]
for
(
let
index
=
0
;
index
<
10
;
index
++
)
{
const
card
=
this
.
g_cartoon
.
getCartoonElement
(
`card_
${
index
+
1
}
`
)
card
.
node
.
setPosition
(
cardPos
[
index
].
x
,
cardPos
[
index
].
y
)
}
}
initImageCards
()
{
let
newIndex
=
this
.
getRandomArray
(
10
)
console
.
log
(
"
正确序号:
"
,
newIndex
)
this
.
m_currentQuestionArray
=
[
0
,
1
,
2
,
3
,
4
,
5
,
6
,
7
,
8
,
9
]
for
(
let
index
=
0
;
index
<
10
;
index
++
)
{
let
dataLength
=
this
.
g_formData
.
dataArray
.
length
;
let
newIndex
=
this
.
getRandomArray
(
dataLength
)
this
.
m_currentQuestionArray
=
[]
for
(
let
index
=
0
;
index
<
dataLength
;
index
++
)
{
this
.
m_currentQuestionArray
.
push
(
index
)
}
for
(
let
index
=
0
;
index
<
dataLength
;
index
++
)
{
let
dataItem
=
this
.
g_formData
.
dataArray
[
newIndex
[
index
]];
let
card
=
this
.
g_cartoon
.
getCartoonElement
(
`card_
${
index
+
1
}
`
)
card
.
open
=
false
;
...
...
@@ -132,20 +163,10 @@ export default class GameLogic {
bellOutline
.
node
.
setScale
(
0
);
this
.
g_cartoon
.
subscribeTouchEvent
(
`card_
${
index
+
1
}
_image_container`
,
()
=>
{
if
(
card
.
open
)
{
if
(
card
.
open
||
this
.
m_gameEnd
)
{
return
;
}
// for(let i=0; i<10; i++) {
// if(i!=index && i != this.m_currentQuestion) {
// this.g_cartoon.getCartoonElement(`card_${i+1}_normal`).node.opacity = 255;
// this.g_cartoon.getCartoonElement(`card_${i+1}_selected`).node.opacity = 0;
// } else {
// this.g_cartoon.getCartoonElement(`card_${i+1}_normal`).node.opacity = 0;
// this.g_cartoon.getCartoonElement(`card_${i+1}_selected`).node.opacity = 255;
// }
// }
if
(
this
.
m_currentQuestion
==
imageContainer
.
correctIndex
)
{
card
.
open
=
true
;
this
.
g_cartoon
.
getCartoonElement
(
`card_
${
imageContainer
.
cardIndex
+
1
}
_normal`
).
node
.
opacity
=
0
;
...
...
@@ -195,8 +216,8 @@ export default class GameLogic {
let
x_2
=
card_2
.
node
.
x
let
y_2
=
card_2
.
node
.
y
card_1
.
node
.
setSiblingIndex
(
10
0
);
card_2
.
node
.
setSiblingIndex
(
10
0
);
card_1
.
node
.
setSiblingIndex
(
10
);
card_2
.
node
.
setSiblingIndex
(
10
);
let
bell1
=
this
.
g_cartoon
.
getCartoonElement
(
`card_
${
i1
}
_bell`
)
let
bell2
=
this
.
g_cartoon
.
getCartoonElement
(
`card_
${
toIndex
+
1
}
_bell`
)
...
...
@@ -231,30 +252,12 @@ export default class GameLogic {
return
this
.
m_currentQuestionArray
.
indexOf
(
index
)
}
initCenterImage
()
{
let
imageContainer
=
this
.
g_cartoon
.
getCartoonElement
(
"
center_image_container
"
)
if
(
!
this
.
g_formData
.
dataArray
[
this
.
m_currentQuestion
].
question
.
centerImage_url
)
{
let
fr
=
this
.
getSpriteFrimeByResName
(
"
default_stage
"
)
imageContainer
.
node
.
setScale
(
1
)
imageContainer
.
node
.
getComponent
(
cc
.
Sprite
).
spriteFrame
=
fr
}
else
{
let
parentWidth
=
imageContainer
.
node
.
parent
.
width
let
parentHeight
=
imageContainer
.
node
.
parent
.
height
this
.
getSpriteFrimeByUrl
(
this
.
g_formData
.
dataArray
[
this
.
m_currentQuestion
].
question
.
centerImage_url
,
(
fr
)
=>
{
imageContainer
.
node
.
getComponent
(
cc
.
Sprite
).
spriteFrame
=
fr
imageContainer
.
node
.
scaleX
=
parentWidth
/
imageContainer
.
node
.
width
imageContainer
.
node
.
scaleY
=
parentHeight
/
imageContainer
.
node
.
height
})
}
}
initTitle
()
{
this
.
g_cartoon
.
getCartoonElement
(
"
title_text
"
).
node
.
getComponent
(
cc
.
Label
).
string
=
"
It's My Day
"
this
.
g_cartoon
.
getCartoonElement
(
"
title_text
"
).
node
.
getComponent
(
cc
.
Label
).
font
=
this
.
g_cartoon
.
getFontFamily
(
"
Comic Sans MS
"
)
this
.
g_cartoon
.
getCartoonElement
(
"
title_text
"
).
node
.
getComponent
(
cc
.
Label
).
fontSize
=
32
}
getRandomArray
(
length
)
{
Array
.
prototype
.
shuffle
=
function
()
{
let
m
=
this
.
length
,
i
;
...
...
@@ -322,15 +325,97 @@ export default class GameLogic {
loadQuestion
()
{
let
index
=
null
;
let
dataLength
=
this
.
g_formData
.
dataArray
.
length
;
for
(
let
i
=
0
;
i
<
10
;
i
++
)
{
this
.
g_cartoon
.
getCartoonElement
(
`card_
${
i
+
1
}
_normal`
).
node
.
opacity
=
255
;
this
.
g_cartoon
.
getCartoonElement
(
`card_
${
i
+
1
}
_selected`
).
node
.
opacity
=
0
;
}
this
.
m_currentQuestion
++
;
if
((
this
.
m_currentQuestion
+
1
)
==
dataLength
)
{
this
.
endGame
()
}
else
{
index
=
this
.
m_currentQuestionArray
[
this
.
m_currentQuestion
]
this
.
g_cartoon
.
getCartoonElement
(
`card_
${
index
+
1
}
_normal`
).
node
.
opacity
=
0
;
this
.
g_cartoon
.
getCartoonElement
(
`card_
${
index
+
1
}
_selected`
).
node
.
opacity
=
255
;
}
}
endGame
()
{
this
.
m_gameEnd
=
true
;
let
resetBtn
=
this
.
g_cartoon
.
getCartoonElement
(
"
restart_button
"
)
resetBtn
.
node
.
active
=
true
;
}
restartGame
(
callback
)
{
this
.
m_questionAudioPlayed
=
false
;
this
.
m_currentQuestion
=
-
1
;
this
.
m_questionDone
=
false
;
this
.
m_currentQuestionArray
=
[]
this
.
m_gameEnd
=
false
;
for
(
let
index
=
0
;
index
<
10
;
index
++
)
{
const
card
=
this
.
g_cartoon
.
getCartoonElement
(
`card_
${
index
+
1
}
`
)
}
this
.
g_cartoon
.
stopAllAudio
()
this
.
showMaskLayer
(()
=>
{
this
.
resetPosition
();
this
.
initImageCards
();
this
.
initTitle
();
this
.
loadQuestion
();
this
.
hideMaskLayer
(()
=>
{
if
(
callback
)
{
callback
()
}
})
})
}
initBottomButtons
()
{
let
bottomButtons
=
this
.
g_cartoon
.
getCartoonElement
(
"
bottomButtons
"
)
bottomButtons
.
node
.
x
=
cc
.
winSize
.
width
/
2
-
100
bottomButtons
.
node
.
y
=
-
cc
.
winSize
.
height
/
2
+
50
let
resetBtn
=
this
.
g_cartoon
.
getCartoonElement
(
"
restart_button
"
)
resetBtn
.
node
.
active
=
false
;
this
.
g_cartoon
.
subscribeTouchEvent
(
resetBtn
.
key
,
()
=>
{
jelly
(
resetBtn
.
node
).
then
(()
=>
{
resetBtn
.
node
.
active
=
false
;
})
this
.
restartGame
()
})
}
initCenterImage
()
{
let
imageContainer
=
this
.
g_cartoon
.
getCartoonElement
(
"
center_image_container
"
)
if
(
!
this
.
g_formData
.
dataArray
[
this
.
m_currentQuestion
].
question
.
centerImage_url
)
{
let
fr
=
this
.
getSpriteFrimeByResName
(
"
default_stage
"
)
imageContainer
.
node
.
setScale
(
1
)
imageContainer
.
node
.
getComponent
(
cc
.
Sprite
).
spriteFrame
=
fr
}
else
{
let
parentWidth
=
imageContainer
.
node
.
parent
.
width
let
parentHeight
=
imageContainer
.
node
.
parent
.
height
this
.
getSpriteFrimeByUrl
(
this
.
g_formData
.
dataArray
[
this
.
m_currentQuestion
].
question
.
centerImage_url
,
(
fr
)
=>
{
imageContainer
.
node
.
getComponent
(
cc
.
Sprite
).
spriteFrame
=
fr
imageContainer
.
node
.
scaleX
=
parentWidth
/
imageContainer
.
node
.
width
imageContainer
.
node
.
scaleY
=
parentHeight
/
imageContainer
.
node
.
height
})
}
}
initQuestionPannel
()
{
let
title
=
this
.
g_cartoon
.
getCartoonElement
(
"
question_title_pannel
"
)
...
...
@@ -786,6 +871,7 @@ export default class GameLogic {
bNode
.
scaleY
=
cc
.
winSize
.
height
/
bNode
.
height
;
bNode
.
x
=
0
bNode
.
y
=
0
parentNode
.
setSiblingIndex
(
255
)
bNode
.
parent
=
cc
.
find
(
'
Canvas
'
);
bNode
.
active
=
false
;
this
.
maskLayer
=
bNode
;
...
...
play/assets/tmpGame/script/Scene.js
View file @
04ee877a
...
...
@@ -87,7 +87,8 @@ cc.Class({
},
getDefaultData
()
{
const
dataJson
=
'
{"contentObj":{"version":"1.0","key":"DataKey_Sbox_FT_08","bgMusic":"","titleText":"TEstd","questionAudio_url":"","dataArray":[{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/06cc843598a912921f6ca3acfde6220b.png","audio_url":"http://staging-teach.cdn.ireadabc.com/3b5540cc95a006dff8c41dba7537075a.mp3"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/571974922f6678111348a5643dba7e20.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/78579114773af12a7aec6723e3b9d475.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/c99e82e1c3f087c6dc0469e30c624f70.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/5b45c89ac9e899d76522767219b1346b.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/2e28eae8f0e0f01193da6f3677379ed3.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/fad2dac4f8b59a185dc30d42617c2ca8.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/6c3fca11052464102407f173e4a83db9.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/ec82c796af801486548ae98623f614d2.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/ac4b9422df1556f80ac5c3058cd3d670.png"}]}}
'
// const dataJson = '{"contentObj":{"version":"1.0","key":"DataKey_Sbox_FT_08","bgMusic":"","titleText":"TEstd","questionAudio_url":"","dataArray":[{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/06cc843598a912921f6ca3acfde6220b.png","audio_url":"http://staging-teach.cdn.ireadabc.com/3b5540cc95a006dff8c41dba7537075a.mp3"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/571974922f6678111348a5643dba7e20.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/78579114773af12a7aec6723e3b9d475.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/c99e82e1c3f087c6dc0469e30c624f70.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/5b45c89ac9e899d76522767219b1346b.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/2e28eae8f0e0f01193da6f3677379ed3.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/fad2dac4f8b59a185dc30d42617c2ca8.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/6c3fca11052464102407f173e4a83db9.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/ec82c796af801486548ae98623f614d2.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/ac4b9422df1556f80ac5c3058cd3d670.png"}]}}'
const
dataJson
=
'
{"contentObj":{"version":"1.0","key":"DataKey_Sbox_FT_08","bgMusic":"","titleText":"TEstd","questionAudio_url":"","dataArray":[{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/06cc843598a912921f6ca3acfde6220b.png","audio_url":"http://staging-teach.cdn.ireadabc.com/3b5540cc95a006dff8c41dba7537075a.mp3"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/571974922f6678111348a5643dba7e20.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/78579114773af12a7aec6723e3b9d475.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/c99e82e1c3f087c6dc0469e30c624f70.png"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/5b45c89ac9e899d76522767219b1346b.png"}]}}
'
const
data
=
JSON
.
parse
(
dataJson
);
return
data
;
},
...
...
play/assets/tmpGame/textures/btn_restart.png
0 → 100644
View file @
04ee877a
5.1 KB
play/assets/tmpGame/textures/btn_restart.png.meta
0 → 100644
View file @
04ee877a
{
"ver": "2.3.5",
"uuid": "2415e777-ac95-43f5-a9e9-14a21908331e",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 47,
"height": 57,
"platformSettings": {},
"subMetas": {
"btn_restart": {
"ver": "1.0.4",
"uuid": "607a2f52-a26c-434f-b331-afa9335ca6e6",
"rawTextureUuid": "2415e777-ac95-43f5-a9e9-14a21908331e",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 47,
"height": 57,
"rawWidth": 47,
"rawHeight": 57,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
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