diff --git a/TODO b/TODO index 5a273487fda..7c48cd8cdfc 100644 --- a/TODO +++ b/TODO @@ -268,6 +268,7 @@ SCUMM - Add support for o80_unknownE0 type1 (For binoculars in pajama2) - Add support for o80_unknownE0 type2 (For black board in freddi2 and paper in spyfox) - Add support for o80_readConfigFile (For loading map.ini details in mustard) + - Add support for o90_unknown39 (For chase/soccer2004) - Add support for IMA ADPCM compression for speech files (For soccer2004) - Add support for U32 code, triggered by case 2001 of kernelGet/Set (For footdemo/soccer2004) The U32 code seems to control the players movements on field. diff --git a/scumm/intern.h b/scumm/intern.h index 5fd1fa00553..f68e1eb8d36 100644 --- a/scumm/intern.h +++ b/scumm/intern.h @@ -1084,6 +1084,7 @@ protected: void o90_cond(); void o90_dim2dim2Array(); void o90_redim2dimArray(); + void o90_unknown39(); void o90_sortArray(); void o90_getObjectData(); void o90_getPaletteData(); diff --git a/scumm/script_v100he.cpp b/scumm/script_v100he.cpp index cffc1f16e7f..eabe2f8ecae 100644 --- a/scumm/script_v100he.cpp +++ b/scumm/script_v100he.cpp @@ -263,7 +263,7 @@ void ScummEngine_v100he::setupOpcodes() { /* B0 */ OPCODE(o72_findObjectWithClassOf), OPCODE(o70_polygonHit), - OPCODE(o6_invalid), + OPCODE(o90_unknown39), OPCODE(o6_invalid), /* B4 */ OPCODE(o72_getNumFreeArrays), @@ -1377,7 +1377,7 @@ void ScummEngine_v100he::o100_wizImageOps() { default: error("o100_wizImageOps: Unknown case %d", subOp); } - debug(1,"o100_wizImageOps stub (%d)", subOp); + debug(1,"o100_wizImageOps (%d)", subOp); } void ScummEngine_v100he::o100_dim2dim2Array() { @@ -1513,7 +1513,7 @@ void ScummEngine_v100he::o100_paletteOps() { default: error("o100_paletteOps: Unknown case %d", subOp); } - debug(1, "o100_paletteOps stub (%d)", subOp); + debug(1, "o100_paletteOps (%d)", subOp); } void ScummEngine_v100he::o100_jumpToScriptUnk() { diff --git a/scumm/script_v90he.cpp b/scumm/script_v90he.cpp index 979458731e8..5f6bbea38d6 100644 --- a/scumm/script_v90he.cpp +++ b/scumm/script_v90he.cpp @@ -112,7 +112,7 @@ void ScummEngine_v90he::setupOpcodes() { OPCODE(o90_dim2dim2Array), /* 38 */ OPCODE(o90_redim2dimArray), - OPCODE(o6_invalid), + OPCODE(o90_unknown39), OPCODE(o90_sortArray), OPCODE(o6_invalid), /* 3C */ @@ -692,7 +692,7 @@ void ScummEngine_v90he::o90_wizImageOps() { error("o90_wizImageOps: unhandled case %d", subOp); } - debug(1,"o90_wizImageOps stub (%d)", subOp); + debug(1,"o90_wizImageOps (%d)", subOp); } void ScummEngine_v90he::o90_getDistanceBetweenPoints() { @@ -1962,6 +1962,24 @@ void ScummEngine_v90he::o90_redim2dimArray() { } } +void ScummEngine_v90he::o90_unknown39() { + // TODO: Array related + + int array1 = fetchScriptWord(); + int array2 = fetchScriptWord(); + int a2_dim1end = pop(); + int a2_dim1start = pop(); + int a2_dim2end = pop(); + int a2_dim2start = pop(); + int a1_dim1end = pop(); + int a1_dim1start = pop(); + int a1_dim2end = pop(); + int a1_dim2start = pop(); + + push(0); + debug(1,"o90_unknown39 stub array1 %d (%d, %d, %d, %d) array2 %d (%d, %d, %d, %d)", array1, a2_dim2start, a2_dim2end, a2_dim1start, a2_dim1end, array2, a1_dim2start, a1_dim2end, a1_dim1start, a1_dim1end); +} + void ScummEngine_v90he::getArrayDim(int array, int *dim2start, int *dim2end, int *dim1start, int *dim1end) { ArrayHeader *ah = (ArrayHeader *)getResourceAddress(rtString, readVar(array)); assert(ah); @@ -2129,7 +2147,7 @@ void ScummEngine_v90he::o90_getObjectData() { default: error("o90_getObjectData: Unknown case %d", subOp); } - debug(1,"o90_getObjectData stub (%d)", subOp); + debug(1,"o90_getObjectData (%d)", subOp); } void ScummEngine_v90he::o90_getPaletteData() { @@ -2245,7 +2263,7 @@ void ScummEngine_v90he::o90_paletteOps() { default: error("o90_paletteOps: Unknown case %d", subOp); } - debug(0,"o90_paletteOps stub (%d)", subOp); + debug(0,"o90_paletteOps (%d)", subOp); }