Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro
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
List
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
YGOPRO-520DIY
ygopro
Commits
6e5cc16f
Commit
6e5cc16f
authored
Mar 28, 2025
by
mercury233
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
4adcf746
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
4 deletions
+6
-4
.github/workflows/build.yml
.github/workflows/build.yml
+1
-1
gframe/premake5.lua
gframe/premake5.lua
+1
-0
gframe/sound_manager.cpp
gframe/sound_manager.cpp
+4
-3
No files found.
.github/workflows/build.yml
View file @
6e5cc16f
...
@@ -224,7 +224,7 @@ jobs:
...
@@ -224,7 +224,7 @@ jobs:
-
name
:
Upload build artifacts
-
name
:
Upload build artifacts
uses
:
actions/upload-artifact@v4
uses
:
actions/upload-artifact@v4
with
:
with
:
name
:
YGOPro-${{ matrix.os }}
name
:
YGOPro-${{ matrix.os }}
-${{ matrix.audiolib }}
path
:
|
path
:
|
bin/release/YGOPro.exe
bin/release/YGOPro.exe
...
...
gframe/premake5.lua
View file @
6e5cc16f
...
@@ -97,4 +97,5 @@ project "YGOPro"
...
@@ -97,4 +97,5 @@ project "YGOPro"
links
{
"GL"
,
"X11"
,
"Xxf86vm"
}
links
{
"GL"
,
"X11"
,
"Xxf86vm"
}
if
USE_AUDIO
and
AUDIO_LIB
==
"irrklang"
then
if
USE_AUDIO
and
AUDIO_LIB
==
"irrklang"
then
links
{
"IrrKlang"
}
links
{
"IrrKlang"
}
linkoptions
{
IRRKLANG_LINK_RPATH
}
end
end
gframe/sound_manager.cpp
View file @
6e5cc16f
...
@@ -43,10 +43,9 @@ bool SoundManager::Init() {
...
@@ -43,10 +43,9 @@ bool SoundManager::Init() {
#ifdef YGOPRO_USE_IRRKLANG
#ifdef YGOPRO_USE_IRRKLANG
engineSound
=
irrklang
::
createIrrKlangDevice
();
engineSound
=
irrklang
::
createIrrKlangDevice
();
engineMusic
=
irrklang
::
createIrrKlangDevice
();
engineMusic
=
irrklang
::
createIrrKlangDevice
();
if
(
!
engineSound
||
!
engineMusic
)
{
if
(
!
engineSound
||
!
engineMusic
)
{
return
false
;
return
false
;
}
}
else
{
else
{
#ifdef IRRKLANG_STATIC
#ifdef IRRKLANG_STATIC
irrklang
::
ikpMP3Init
(
engineMusic
);
irrklang
::
ikpMP3Init
(
engineMusic
);
#endif
#endif
...
@@ -84,6 +83,7 @@ void SoundManager::RefershBGMDir(std::wstring path, int scene) {
...
@@ -84,6 +83,7 @@ void SoundManager::RefershBGMDir(std::wstring path, int scene) {
});
});
}
}
void
SoundManager
::
PlaySoundEffect
(
int
sound
)
{
void
SoundManager
::
PlaySoundEffect
(
int
sound
)
{
#ifdef YGOPRO_USE_AUDIO
if
(
!
mainGame
->
chkEnableSound
->
isChecked
())
if
(
!
mainGame
->
chkEnableSound
->
isChecked
())
return
;
return
;
char
soundName
[
32
];
char
soundName
[
32
];
...
@@ -221,6 +221,7 @@ void SoundManager::PlaySoundEffect(int sound) {
...
@@ -221,6 +221,7 @@ void SoundManager::PlaySoundEffect(int sound) {
engineSound
->
setSoundVolume
(
mainGame
->
gameConf
.
sound_volume
);
engineSound
->
setSoundVolume
(
mainGame
->
gameConf
.
sound_volume
);
engineSound
->
play2D
(
soundPath
);
engineSound
->
play2D
(
soundPath
);
#endif
#endif
#endif // YGOPRO_USE_AUDIO
}
}
void
SoundManager
::
PlayDialogSound
(
irr
::
gui
::
IGUIElement
*
element
)
{
void
SoundManager
::
PlayDialogSound
(
irr
::
gui
::
IGUIElement
*
element
)
{
if
(
element
==
mainGame
->
wMessage
)
{
if
(
element
==
mainGame
->
wMessage
)
{
...
...
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