diff options
author | Travis Howell | 2007-05-16 05:57:26 +0000 |
---|---|---|
committer | Travis Howell | 2007-05-16 05:57:26 +0000 |
commit | bdb18c60d8c582ac8bd555ac8d573a3f8de9e1a4 (patch) | |
tree | a33d9914dcc82d7fb072532bb2a81cad184b1190 /engines/agos/res_snd.cpp | |
parent | ada3424d8a88b905ab153d84a6f1de12cd4b8e59 (diff) | |
download | scummvm-rg350-bdb18c60d8c582ac8bd555ac8d573a3f8de9e1a4.tar.gz scummvm-rg350-bdb18c60d8c582ac8bd555ac8d573a3f8de9e1a4.tar.bz2 scummvm-rg350-bdb18c60d8c582ac8bd555ac8d573a3f8de9e1a4.zip |
Add idle code for DIMP.
svn-id: r26848
Diffstat (limited to 'engines/agos/res_snd.cpp')
-rw-r--r-- | engines/agos/res_snd.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/engines/agos/res_snd.cpp b/engines/agos/res_snd.cpp index 9dd869915d..41c3dce075 100644 --- a/engines/agos/res_snd.cpp +++ b/engines/agos/res_snd.cpp @@ -381,6 +381,22 @@ static const char *dimpSoundList[32] = { }; +void AGOSEngine::loadSoundFile(const char* filename) { + File in; + + in.open(filename); + if (in.isOpen() == false) + error("loadSound: Can't load %s", filename); + + uint32 dstSize = in.size(); + byte *dst = (byte *)malloc(dstSize); + if (in.read(dst, dstSize) != dstSize) + error("loadSound: Read failed"); + in.close(); + + _sound->playSfxData(dst, 0, 0, 0); +} + void AGOSEngine::loadSound(uint sound, int pan, int vol, uint type) { byte *dst; |