aboutsummaryrefslogtreecommitdiff
path: root/engines/sci/engine
diff options
context:
space:
mode:
authorMartin Kiewitz2010-05-31 09:31:05 +0000
committerMartin Kiewitz2010-05-31 09:31:05 +0000
commit9d50dac101b0d545b23397eef83f34b75a382303 (patch)
tree18d7da21944ef69b94f15cdbb000660ee32e0626 /engines/sci/engine
parent7001d3e6157dc9fe601a5f0e2195a367755a344b (diff)
downloadscummvm-rg350-9d50dac101b0d545b23397eef83f34b75a382303.tar.gz
scummvm-rg350-9d50dac101b0d545b23397eef83f34b75a382303.tar.bz2
scummvm-rg350-9d50dac101b0d545b23397eef83f34b75a382303.zip
SCI: skip spaces in kReadNumber - this happens in lsl3 intro
svn-id: r49345
Diffstat (limited to 'engines/sci/engine')
-rw-r--r--engines/sci/engine/kstring.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/engines/sci/engine/kstring.cpp b/engines/sci/engine/kstring.cpp
index 69090c4335..90096d5c17 100644
--- a/engines/sci/engine/kstring.cpp
+++ b/engines/sci/engine/kstring.cpp
@@ -151,6 +151,10 @@ reg_t kReadNumber(EngineState *s, int argc, reg_t *argv) {
source++;
}
while (*source) {
+ if (*source == ' ') {
+ source++; // skip spaces - happens in lsl3 intro
+ continue;
+ }
if ((*source < '0') || (*source > '9')) {
// TODO: this happens in lsl5 right in the intro -> we get '1' '3' 0xCD 0xCD 0xCD 0xCD 0xCD
// find out why this happens and fix it