Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
E
et15_flipcard
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
et15_flipcard
Commits
5b24a2ff
Commit
5b24a2ff
authored
Mar 01, 2021
by
Guo Yuhang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
card taget tween add
Signed-off-by:
郭宇航
<
guoyuhang@iplayabc.com
>
parent
3f5abfa2
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
0 deletions
+14
-0
flipCard.js
play/assets/tmpGame/script/flipCard.js
+14
-0
No files found.
play/assets/tmpGame/script/flipCard.js
View file @
5b24a2ff
...
@@ -232,6 +232,20 @@ cc.Class({
...
@@ -232,6 +232,20 @@ cc.Class({
// 背景图添加按钮
// 背景图添加按钮
bgbackNode
.
addComponent
(
cc
.
Button
);
bgbackNode
.
addComponent
(
cc
.
Button
);
// img添加按钮
imgNode
.
addComponent
(
cc
.
Button
);
imgNode
.
on
(
'
click
'
,
()
=>
{
cc
.
tween
(
bgbackNode
)
.
call
(()
=>
{
bgbackNode
.
opacity
=
1000
;
// labelNode.opacity = 0;
var
playAudio
=
bgbackNode
.
getComponent
(
cc
.
AudioSource
);
var
flipButton
=
bgbackNode
.
getComponent
(
cc
.
Button
);
flipButton
.
enabled
=
true
;
playAudio
.
play
();
}).
to
(
0.3
,
{
scaleY
:
1
})
.
start
();
});
const
playAudioBtnNode
=
cardNode
.
getChildByName
(
'
playbtn
'
);
const
playAudioBtnNode
=
cardNode
.
getChildByName
(
'
playbtn
'
);
const
playAudioBtnImgNode
=
cardNode
.
getChildByName
(
'
btnimg
'
);
const
playAudioBtnImgNode
=
cardNode
.
getChildByName
(
'
btnimg
'
);
...
...
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