aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Gilbert2012-10-10 00:28:24 +1100
committerPaul Gilbert2012-10-10 00:28:24 +1100
commit22204ecc66e5da0f3432cc4f6c8748d9d3e3ee34 (patch)
treef234be4ecc2614eacb2547ffe5e8f5baf7baefd6
parent4e0738af23f2e83ee30777d22cf63a13ddf5f08e (diff)
downloadscummvm-rg350-22204ecc66e5da0f3432cc4f6c8748d9d3e3ee34.tar.gz
scummvm-rg350-22204ecc66e5da0f3432cc4f6c8748d9d3e3ee34.tar.bz2
scummvm-rg350-22204ecc66e5da0f3432cc4f6c8748d9d3e3ee34.zip
HOPKINS: Fixed loading in CHARGE_BANK_SPRITE1
-rw-r--r--engines/hopkins/anim.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/engines/hopkins/anim.cpp b/engines/hopkins/anim.cpp
index 3971300ff4..4b16811d65 100644
--- a/engines/hopkins/anim.cpp
+++ b/engines/hopkins/anim.cpp
@@ -844,8 +844,11 @@ int AnimationManager::CHARGE_BANK_SPRITE1(int idx, const Common::String &filenam
_vm->_globals.Bank[idx].field1A = v8;
Common::String ofsFilename = _vm->_globals.Bank[idx].filename1;
- while (ofsFilename.lastChar() != '.')
+ char ch;
+ do {
+ ch = ofsFilename.lastChar();
ofsFilename.deleteLastChar();
+ } while (ch != '.');
ofsFilename += ".OFS";
_vm->_fileManager.CONSTRUIT_FICHIER(_vm->_globals.HOPANIM, ofsFilename);