diff options
author | Kari Salminen | 2007-08-04 12:23:28 +0000 |
---|---|---|
committer | Kari Salminen | 2007-08-04 12:23:28 +0000 |
commit | 44279df48e3951fe58b325c36fae276eddcb1f94 (patch) | |
tree | 16ec0b9ad7218cf651702f1aeb690b337058b3c1 | |
parent | 44ddb2419b9d09c894bd3b2c8e1be39c87b30e67 (diff) | |
download | scummvm-rg350-44279df48e3951fe58b325c36fae276eddcb1f94.tar.gz scummvm-rg350-44279df48e3951fe58b325c36fae276eddcb1f94.tar.bz2 scummvm-rg350-44279df48e3951fe58b325c36fae276eddcb1f94.zip |
Fixes compilation error C2677: binary '&&' : no global operator found which takes type 'const Kyra::Opcode' (or there is no acceptable conversion) on Windows (VS2003), Xbox (VS2003) and Xbox 360 (VS2005).
For some reason the compilers didn't automatically use the operator bool() in the Kyra::Opcode so now doing it explicitly.
Thanks to Carch for reporting the compilation problems.
svn-id: r28447
-rw-r--r-- | engines/kyra/script.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/kyra/script.cpp b/engines/kyra/script.cpp index 739e92feda..5966fa2c25 100644 --- a/engines/kyra/script.cpp +++ b/engines/kyra/script.cpp @@ -386,7 +386,7 @@ void ScriptHelper::cmd_execOpcode(ScriptState* script) { assert(script->dataPtr->opcodes); assert(opcode < script->dataPtr->opcodes->size()); - if ((*script->dataPtr->opcodes)[opcode] && *(*script->dataPtr->opcodes)[opcode]) { + if ((*script->dataPtr->opcodes)[opcode] && (bool) *(*script->dataPtr->opcodes)[opcode]) { script->retValue = (*(*script->dataPtr->opcodes)[opcode])(script); } else { script->retValue = 0; |