Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sejong25
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Tear of Sejong
sejong25
Commits
f7900ccf
Commit
f7900ccf
authored
Jul 14, 2019
by
18김재민
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
함수 구조 변경, 한번 / 반복 재생 나눔
parent
9344bdc9
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
13 deletions
+13
-13
BGMsound.js
js/BGMsound.js
+11
-11
ScenesData.js
js/ScenesData.js
+2
-2
No files found.
js/BGMsound.js
View file @
f7900ccf
...
@@ -6,34 +6,34 @@ Audio.loadSound = function(scene)
...
@@ -6,34 +6,34 @@ Audio.loadSound = function(scene)
scene
.
load
.
audio
(
'
startGame
'
,
'
assets/sound/startGame.ogg
'
);
scene
.
load
.
audio
(
'
startGame
'
,
'
assets/sound/startGame.ogg
'
);
}
}
Audio
.
play
Login
=
function
(
scene
)
Audio
.
play
Sound
=
function
(
scene
,
title
)
// 한 번만 재생할 때 사용
{
{
var
bgm
=
scene
.
sound
.
add
(
'
login
'
);
var
bgm
=
scene
.
sound
.
add
(
title
);
bgm
.
setLoop
(
true
);
bgm
.
play
();
bgm
.
play
();
}
}
Audio
.
playStart
=
function
(
scene
)
Audio
.
loopSound
=
function
(
scene
,
title
)
// 반복재생할 때 사용
{
{
var
bgm
=
scene
.
sound
.
add
(
'
startGame
'
);
var
bgm
=
scene
.
sound
.
add
(
title
);
bgm
.
setLoop
(
true
);
bgm
.
play
();
bgm
.
play
();
}
}
Audio
.
pauseSound
=
function
(
scene
)
Audio
.
pauseSound
=
function
(
scene
,
title
)
{
{
var
bgm
=
scene
.
sound
.
add
(
'
BGM
'
);
var
bgm
=
scene
.
sound
.
add
(
title
);
bgm
.
pause
();
bgm
.
pause
();
}
}
Audio
.
resumeSound
=
function
(
scene
)
Audio
.
resumeSound
=
function
(
scene
,
title
)
{
{
var
bgm
=
scene
.
sound
.
add
(
'
BGM
'
);
var
bgm
=
scene
.
sound
.
add
(
title
);
bgm
=
scene
.
sound
.
resume
();
bgm
=
scene
.
sound
.
resume
();
}
}
Audio
.
stopSound
=
function
(
scene
)
Audio
.
stopSound
=
function
(
scene
,
title
)
{
{
var
bgm
=
scene
.
sound
.
add
(
'
login
'
);
var
bgm
=
scene
.
sound
.
add
(
title
);
bgm
.
setLoop
(
false
);
bgm
.
setLoop
(
false
);
bgm
.
stop
();
bgm
.
stop
();
}
}
...
...
js/ScenesData.js
View file @
f7900ccf
...
@@ -18,7 +18,7 @@ var menuScene = new Phaser.Class(
...
@@ -18,7 +18,7 @@ var menuScene = new Phaser.Class(
create
:
function
()
create
:
function
()
{
{
Audio
.
playLogin
(
this
);
Audio
.
loopSound
(
this
,
'
login
'
);
Input
.
inputField
.
generate
(
this
,
Input
.
menuSceneEnterReaction
);
Input
.
inputField
.
generate
(
this
,
Input
.
menuSceneEnterReaction
);
BackGround
.
drawMenu
(
this
);
BackGround
.
drawMenu
(
this
);
}
}
...
@@ -48,7 +48,7 @@ var gameScene = new Phaser.Class(
...
@@ -48,7 +48,7 @@ var gameScene = new Phaser.Class(
{
{
CSVParsing
.
CSVParse
(
this
);
CSVParsing
.
CSVParse
(
this
);
BackGround
.
drawBrain
(
this
);
BackGround
.
drawBrain
(
this
);
Audio
.
playS
tart
(
this
);
Audio
.
playS
ound
(
this
,
'
startGame
'
);
WordSpace
.
wordPhysicsGroup
=
this
.
physics
.
add
.
group
();
WordSpace
.
wordPhysicsGroup
=
this
.
physics
.
add
.
group
();
Input
.
inputField
.
generate
(
this
,
Input
.
gameSceneEnterReaction
);
Input
.
inputField
.
generate
(
this
,
Input
.
gameSceneEnterReaction
);
...
...
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