Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nanahira
ygopro2
Commits
9e36fb05
Commit
9e36fb05
authored
Jan 16, 2019
by
Szefo09
Committed by
mercury233
Jan 16, 2019
1
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed an issue that caused the audio to not play in folders with specific characters.
parent
2a44ac64
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
11 deletions
+13
-11
Assets/SibylSystem/MonoHelpers/UIHelper.cs
Assets/SibylSystem/MonoHelpers/UIHelper.cs
+1
-1
Assets/old/Ocgcore/animation_scripts/audio_helper.cs
Assets/old/Ocgcore/animation_scripts/audio_helper.cs
+12
-10
No files found.
Assets/SibylSystem/MonoHelpers/UIHelper.cs
View file @
9e36fb05
...
@@ -963,7 +963,7 @@ public static class UIHelper
...
@@ -963,7 +963,7 @@ public static class UIHelper
return
;
return
;
}
}
path
=
Environment
.
CurrentDirectory
.
Replace
(
"\\"
,
"/"
)
+
"/"
+
path
;
path
=
Environment
.
CurrentDirectory
.
Replace
(
"\\"
,
"/"
)
+
"/"
+
path
;
path
=
"file:///"
+
p
ath
;
path
=
new
Uri
(
new
Uri
(
"file:///"
),
path
).
AbsoluteP
ath
;
GameObject
audio_helper
=
Program
.
I
().
ocgcore
.
create_s
(
Program
.
I
().
mod_audio_effect
);
GameObject
audio_helper
=
Program
.
I
().
ocgcore
.
create_s
(
Program
.
I
().
mod_audio_effect
);
audio_helper
.
GetComponent
<
audio_helper
>().
play
(
path
,
Program
.
I
().
setting
.
soundValue
());
audio_helper
.
GetComponent
<
audio_helper
>().
play
(
path
,
Program
.
I
().
setting
.
soundValue
());
Program
.
I
().
destroy
(
audio_helper
,
5f
);
Program
.
I
().
destroy
(
audio_helper
,
5f
);
...
...
Assets/old/Ocgcore/animation_scripts/audio_helper.cs
View file @
9e36fb05
...
@@ -17,23 +17,25 @@ public class audio_helper : MonoBehaviour {
...
@@ -17,23 +17,25 @@ public class audio_helper : MonoBehaviour {
}
}
}
}
bool
played
=
false
;
bool
played
=
false
;
p
ublic
void
play
(
string
u
,
float
vol
)
p
rivate
IEnumerator
playSound
(
string
u
,
float
vol
)
{
{
played
=
false
;
played
=
false
;
WWW
www
=
new
WWW
(
u
);
using
(
WWW
www
=
new
WWW
(
u
))
{
yield
return
www
;
AudioClip
ac
=
www
.
GetAudioClip
(
true
,
true
);
AudioClip
ac
=
www
.
GetAudioClip
(
true
,
true
);
audioMgr
.
clip
=
ac
;
audioMgr
.
clip
=
ac
;
}
audioMgr
.
volume
=
vol
;
audioMgr
.
volume
=
vol
;
}
}
public
void
play
(
string
u
,
float
vol
)
{
StartCoroutine
(
playSound
(
u
,
vol
));
}
public
void
change_bgm
(
string
str
)
public
void
change_bgm
(
string
str
)
{
{
played
=
false
;
StartCoroutine
(
playSound
(
str
,
100f
));
WWW
www
=
new
WWW
(
str
);
AudioClip
ac
=
www
.
GetAudioClip
(
true
,
true
);
audioMgr
.
clip
=
ac
;
audioMgr
.
loop
=
true
;
audioMgr
.
loop
=
true
;
}
}
...
...
mercury233
@mercury233
mentioned in commit
eb93066b
·
Jun 08, 2020
mentioned in commit
eb93066b
mentioned in commit eb93066b460e8805cedc7b22b32a5273907494a4
Toggle commit list
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