[Scummvm-git-logs] scummvm master -> e06bec1f15ae6fab39444ae601c06214480d8cf6
dreammaster
dreammaster at scummvm.org
Sun Aug 22 00:08:19 UTC 2021
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
e06bec1f15 AGS: Fix commentary speech in Strangeland
Commit: e06bec1f15ae6fab39444ae601c06214480d8cf6
https://github.com/scummvm/scummvm/commit/e06bec1f15ae6fab39444ae601c06214480d8cf6
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2021-08-21T17:08:10-07:00
Commit Message:
AGS: Fix commentary speech in Strangeland
Changed paths:
engines/ags/engine/ac/global_audio.cpp
diff --git a/engines/ags/engine/ac/global_audio.cpp b/engines/ags/engine/ac/global_audio.cpp
index 63983acf6b..38d9330e8a 100644
--- a/engines/ags/engine/ac/global_audio.cpp
+++ b/engines/ags/engine/ac/global_audio.cpp
@@ -538,21 +538,20 @@ static bool play_voice_clip_on_channel(const String &voice_name) {
speechmp3 = my_load_mp3(get_voice_over_assetpath(asset_name), _GP(play).speech_volume);
}
- if (speechmp3 != nullptr) {
- if (!speechmp3->play()) {
- // not assigned to a channel, so clean up manually.
- speechmp3->destroy();
- delete speechmp3;
- speechmp3 = nullptr;
- }
- }
-
if (speechmp3 == nullptr) {
debug_script_warn("Speech load failure: '%s'", voice_name.GetCStr());
return false;
}
set_clip_to_channel(SCHAN_SPEECH, speechmp3);
+
+ if (!speechmp3->play()) {
+ // Could not play, so clean up manually.
+ speechmp3->destroy();
+ delete speechmp3;
+ speechmp3 = nullptr;
+ }
+
return true;
}
More information about the Scummvm-git-logs
mailing list