diff options
author | Max Horn | 2005-01-06 18:38:11 +0000 |
---|---|---|
committer | Max Horn | 2005-01-06 18:38:11 +0000 |
commit | 9cfb8d3bb506f07b5373f4ba56a747a027778a47 (patch) | |
tree | 3977ca398978c481cda027afe9c9372dc4730fd6 | |
parent | aec5da9bbb1e8033ad211324ae9b97565c46464f (diff) | |
download | scummvm-rg350-9cfb8d3bb506f07b5373f4ba56a747a027778a47.tar.gz scummvm-rg350-9cfb8d3bb506f07b5373f4ba56a747a027778a47.tar.bz2 scummvm-rg350-9cfb8d3bb506f07b5373f4ba56a747a027778a47.zip |
Fix getStrings to use the ScummEngine::openFile method
svn-id: r16453
-rw-r--r-- | scumm/smush/smush_player.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/scumm/smush/smush_player.cpp b/scumm/smush/smush_player.cpp index f04d6cb0fa..794221ac6e 100644 --- a/scumm/smush/smush_player.cpp +++ b/scumm/smush/smush_player.cpp @@ -172,11 +172,11 @@ public: } }; -static StringResource *getStrings(const char *file, bool is_encoded) { +static StringResource *getStrings(ScummEngine *vm, const char *file, bool is_encoded) { debugC(DEBUG_SMUSH, "trying to read text ressources from %s", file); - File theFile; + ScummFile theFile; - theFile.open(file); + vm->openFile(theFile, file); if (!theFile.isOpen()) { return 0; } @@ -195,7 +195,7 @@ static StringResource *getStrings(const char *file, bool is_encoded) { if (type != TYPE_ETRS) { delete [] filebuffer; - return getStrings(file, false); + return getStrings(vm, file, false); } char *old = filebuffer; @@ -651,11 +651,11 @@ bool SmushPlayer::readString(const char *file) { char fname[260]; memcpy(fname, file, i - file); strcpy(fname + (i - file), ".trs"); - if ((_strings = getStrings(fname, false)) != 0) { + if ((_strings = getStrings(_vm, fname, false)) != 0) { return true; } - if ((_strings = getStrings("digtxt.trs", true)) != 0) { + if ((_strings = getStrings(_vm, "digtxt.trs", true)) != 0) { return true; } return false; |