diff options
author | Travis Howell | 2003-09-06 08:46:36 +0000 |
---|---|---|
committer | Travis Howell | 2003-09-06 08:46:36 +0000 |
commit | 52a59049c793b63e52485330adfcfde749391ffd (patch) | |
tree | e483a9eb1ea1ba48c03ad46190462f11699f5090 | |
parent | d1c325a8c72d3b92fdee4d606a40fd320a82dc7e (diff) | |
download | scummvm-rg350-52a59049c793b63e52485330adfcfde749391ffd.tar.gz scummvm-rg350-52a59049c793b63e52485330adfcfde749391ffd.tar.bz2 scummvm-rg350-52a59049c793b63e52485330adfcfde749391ffd.zip |
Other v1/v2 resources are invalid, checked again v1 maniac and v1/v2 zak.
svn-id: r10040
-rw-r--r-- | scumm/script_v2.cpp | 24 |
1 files changed, 8 insertions, 16 deletions
diff --git a/scumm/script_v2.cpp b/scumm/script_v2.cpp index 244fc03dab..1ac7dc1b14 100644 --- a/scumm/script_v2.cpp +++ b/scumm/script_v2.cpp @@ -767,11 +767,11 @@ void Scumm_v2::o2_drawObject() { void Scumm_v2::o2_resourceRoutines() { const ResTypes resTypes[] = { - rtNumTypes, // Unknown / invalid - rtNumTypes, // Unknown / invalid + rtNumTypes, // Invalid + rtNumTypes, // Invalid rtCostume, rtRoom, - rtNumTypes, // Unknown / invalid + rtNumTypes, // Invalid rtScript, rtSound }; @@ -782,24 +782,16 @@ void Scumm_v2::o2_resourceRoutines() { if (0 <= (opcode >> 4) && (opcode >> 4) < (int)ARRAYSIZE(resTypes)) type = resTypes[opcode >> 4]; - if (type == rtNumTypes) { - warning("o2_resourceRoutines: unknown restype %d", (opcode >> 4)); + if (type == rtNumTypes) return; - } - if (((opcode & 0x0f) == 0) || ((opcode & 0x0f) == 1)) { - if (opcode & 1) { - ensureResourceLoaded(type, resid); - } else { - // Seems the nuke opcodes do nothing? - warning("o2_resourceRoutines: nuking resType %d, id %d does nothing", type, resid); - } + if ((opcode & 0x0f) == 1) { + ensureResourceLoaded(type, resid); } else { - if (opcode & 1) { + if (opcode & 1) lock(type, resid); - } else { + else unlock(type, resid); - } } } |