Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jj15_zww
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
jj15_zww
Commits
f8ba5ef3
Commit
f8ba5ef3
authored
Apr 17, 2024
by
Tt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
音效添加完成
parent
afee7527
Changes
8
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
382 additions
and
54 deletions
+382
-54
background.mp3
assets/jj15_zww/audios/background.mp3
+0
-0
background.mp3.meta
assets/jj15_zww/audios/background.mp3.meta
+7
-0
move.mp3
assets/jj15_zww/audios/move.mp3
+0
-0
move.mp3.meta
assets/jj15_zww/audios/move.mp3.meta
+7
-0
touch.mp3
assets/jj15_zww/audios/touch.mp3
+0
-0
touch.mp3.meta
assets/jj15_zww/audios/touch.mp3.meta
+7
-0
jj15_zww.fire
assets/jj15_zww/scene/jj15_zww.fire
+307
-52
jj15_zww.ts
assets/jj15_zww/scene/jj15_zww.ts
+54
-2
No files found.
assets/jj15_zww/audios/background.mp3
0 → 100644
View file @
f8ba5ef3
File added
assets/jj15_zww/audios/background.mp3.meta
0 → 100644
View file @
f8ba5ef3
{
"ver": "2.0.1",
"uuid": "67e3f84a-468b-45cd-b563-afcfddc80aee",
"downloadMode": 0,
"duration": 48.039184,
"subMetas": {}
}
\ No newline at end of file
assets/jj15_zww/audios/move.mp3
0 → 100644
View file @
f8ba5ef3
File added
assets/jj15_zww/audios/move.mp3.meta
0 → 100644
View file @
f8ba5ef3
{
"ver": "2.0.1",
"uuid": "fb1b00f8-5a5f-4e14-8b4f-74086255de51",
"downloadMode": 0,
"duration": 1.28,
"subMetas": {}
}
\ No newline at end of file
assets/jj15_zww/audios/touch.mp3
0 → 100644
View file @
f8ba5ef3
File added
assets/jj15_zww/audios/touch.mp3.meta
0 → 100644
View file @
f8ba5ef3
{
"ver": "2.0.1",
"uuid": "1a0d674e-d9e2-43d5-bd71-baf85e7630fe",
"downloadMode": 0,
"duration": 0.219333,
"subMetas": {}
}
\ No newline at end of file
assets/jj15_zww/scene/jj15_zww.fire
View file @
f8ba5ef3
This diff is collapsed.
Click to expand it.
assets/jj15_zww/scene/jj15_zww.ts
View file @
f8ba5ef3
...
...
@@ -123,6 +123,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
private
voiceTouchForbid
:
boolean
;
private
count
:
number
;
initGame
()
{
cc
.
audioEngine
.
playMusic
(
this
.
bgmNode
.
getComponent
(
cc
.
AudioSource
).
clip
,
true
);
this
.
count
=
0
;
this
.
touchForbid
=
true
;
this
.
voiceTouchForbid
=
true
;
...
...
@@ -489,7 +490,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
let
posArray
=
posList
[
data
.
options
.
length
];
let
posY
=
this
.
card_pos
.
y
;
// 计算Y的值
// let img = pg.view.find(layer, 'title/img')
// pg.view.setNetImg(img, data.image, { w: 660, h: 320 })
...
...
@@ -537,6 +538,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
private
btn_start
:
cc
.
Node
=
null
;
onTouchStart
(
e
)
{
if
(
this
.
touchForbid
)
return
;
// 顶级禁止全部点击
this
.
playLocalAudio
(
"
touch
"
)
cc
.
Tween
.
stopAllByTarget
(
this
.
btn_start
)
this
.
btn_start
.
scale
=
1
;
this
.
touchForbid
=
true
;
...
...
@@ -563,6 +565,8 @@ export default class SceneComponent extends MyCocosSceneComponent {
this
.
currentDt
=
data
;
this
.
touchForbid
=
true
;
this
.
playLocalAudio
(
"
move
"
)
cc
.
tween
(
this
.
gou_node
)
// 移动钩子
.
to
(
0.5
,
{
x
:
item
.
x
})
...
...
@@ -606,9 +610,10 @@ export default class SceneComponent extends MyCocosSceneComponent {
private
btn_close
:
cc
.
Node
=
null
;
showRecord
(
item
)
{
let
startPos
=
cc
.
v2
(
item
);
cc
.
tween
(
item
).
to
(
0.3
,
{
y
:
startPos
.
y
+
50
}).
call
(()
=>
{
this
.
playBgmP10
();
item
.
active
=
false
;
item
.
y
=
startPos
.
y
;
...
...
@@ -680,6 +685,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
clearTimeout
(
this
.
btn_voice_time_id
)
this
.
btn_voice_time_id
=
null
;
}
this
.
pauseBgm
();
// 录音
let
btn_voice
=
e
.
target
;
let
normal
=
pg
.
view
.
find
(
btn_voice
,
'
normal
'
)
...
...
@@ -700,6 +706,8 @@ export default class SceneComponent extends MyCocosSceneComponent {
let
score
=
recordData
.
result
.
overall
this
.
updatePopAni
(
null
,
score
);
this
.
checkCardsTime
=
3
;
this
.
resumeBgm
();
this
.
playBgmP100
();
})
}
else
{
this
.
recording
=
true
;
...
...
@@ -911,6 +919,50 @@ export default class SceneComponent extends MyCocosSceneComponent {
});
})
}
@
property
(
cc
.
Node
)
bgmNode
:
cc
.
Node
=
null
;
playBgmP10
()
{
this
.
scheduleOnce
(()
=>
{
cc
.
audioEngine
.
setMusicVolume
(
0.8
);
this
.
scheduleOnce
(()
=>
{
cc
.
audioEngine
.
setMusicVolume
(
0.6
);
this
.
scheduleOnce
(()
=>
{
cc
.
audioEngine
.
setMusicVolume
(
0.4
);
this
.
scheduleOnce
(()
=>
{
cc
.
audioEngine
.
setMusicVolume
(
0.2
);
this
.
scheduleOnce
(()
=>
{
cc
.
audioEngine
.
setMusicVolume
(
0.1
);
},
0.4
)
},
0.4
)
},
0.4
)
},
0.4
)
},
0.4
)
}
pauseBgm
()
{
cc
.
audioEngine
.
pauseMusic
();
}
resumeBgm
()
{
cc
.
audioEngine
.
resumeMusic
();
}
playBgmP100
()
{
this
.
scheduleOnce
(()
=>
{
cc
.
audioEngine
.
setMusicVolume
(
0.2
);
this
.
scheduleOnce
(()
=>
{
cc
.
audioEngine
.
setMusicVolume
(
0.4
);
this
.
scheduleOnce
(()
=>
{
cc
.
audioEngine
.
setMusicVolume
(
0.6
);
this
.
scheduleOnce
(()
=>
{
cc
.
audioEngine
.
setMusicVolume
(
0.8
);
this
.
scheduleOnce
(()
=>
{
cc
.
audioEngine
.
setMusicVolume
(
1
);
},
0.4
)
},
0.4
)
},
0.4
)
},
0.4
)
},
0.4
)
}
}
...
...
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