diff options
author | Eugene Sandulenko | 2016-07-17 23:26:04 +0300 |
---|---|---|
committer | Eugene Sandulenko | 2016-08-03 23:40:36 +0200 |
commit | 21730e9d7e4a7fbaa1bb437f3699e3a9e27a6e7d (patch) | |
tree | 25d783fbb6a55746434c6f29ec97a071a3901126 /engines | |
parent | 9172820158e9ac069a1bb9bf4472dc1e64e2a6e3 (diff) | |
download | scummvm-rg350-21730e9d7e4a7fbaa1bb437f3699e3a9e27a6e7d.tar.gz scummvm-rg350-21730e9d7e4a7fbaa1bb437f3699e3a9e27a6e7d.tar.bz2 scummvm-rg350-21730e9d7e4a7fbaa1bb437f3699e3a9e27a6e7d.zip |
DIRECTOR: Lingo: Cast references could be lowercase too
Diffstat (limited to 'engines')
-rw-r--r-- | engines/director/lingo/lingo-codegen.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/engines/director/lingo/lingo-codegen.cpp b/engines/director/lingo/lingo-codegen.cpp index b54953e9f3..21501bf2a3 100644 --- a/engines/director/lingo/lingo-codegen.cpp +++ b/engines/director/lingo/lingo-codegen.cpp @@ -70,14 +70,14 @@ Symbol *Lingo::lookupVar(const char *name, bool create, bool putInGlobalList) { // Looking for the cast member constants if (_vm->getVersion() < 4) { // TODO: There could be a flag 'Allow Outdated Lingo' in Movie Info in D4 if (strlen(name) == 3) { - if (name[0] >= 'A' && name[0] <= 'H' && + if (tolower(name[0]) >= 'a' && tolower(name[0]) <= 'h' && name[1] >= '1' && name[1] <= '8' && name[2] >= '1' && name[2] <= '8') { if (!create) error("Cast reference used in wrong context: %s", name); - int val = (name[0] - 'A') * 64 + (name[1] - '1') * 8 + (name[2] - '1') + 1; + int val = (tolower(name[0]) - 'a') * 64 + (name[1] - '1') * 8 + (name[2] - '1') + 1; sym = new Symbol; sym->type = CASTREF; |