mirror of
https://github.com/doublespeakgames/adarkroom.git
synced 2026-05-28 00:01:54 +08:00
add full path to audio sources when fetching
This commit is contained in:
@@ -152,6 +152,9 @@ var AudioEngine = {
|
||||
});
|
||||
},
|
||||
loadAudioFile(src) {
|
||||
if (src.indexOf('http') === -1) {
|
||||
src = window.location + src;
|
||||
}
|
||||
if (AudioEngine.AUDIO_BUFFER_CACHE[src]) {
|
||||
return new Promise(function (resolve, reject) {
|
||||
resolve(AudioEngine.AUDIO_BUFFER_CACHE[src]);
|
||||
|
||||
Reference in New Issue
Block a user