diff options
author | Travis Howell | 2005-04-27 14:47:10 +0000 |
---|---|---|
committer | Travis Howell | 2005-04-27 14:47:10 +0000 |
commit | 7c3cfae122bd41fd4aa4c5573bbc38d53f337c38 (patch) | |
tree | e667cd3bbfa226a1851f80af14b2832802a0eb66 /scumm | |
parent | 8545634aaa684847036e040401e4770dafd0c091 (diff) | |
download | scummvm-rg350-7c3cfae122bd41fd4aa4c5573bbc38d53f337c38.tar.gz scummvm-rg350-7c3cfae122bd41fd4aa4c5573bbc38d53f337c38.tar.bz2 scummvm-rg350-7c3cfae122bd41fd4aa4c5573bbc38d53f337c38.zip |
Minor cleanup.
svn-id: r17840
Diffstat (limited to 'scumm')
-rw-r--r-- | scumm/script_v100he.cpp | 24 | ||||
-rw-r--r-- | scumm/script_v72he.cpp | 13 | ||||
-rw-r--r-- | scumm/script_v80he.cpp | 11 |
3 files changed, 22 insertions, 26 deletions
diff --git a/scumm/script_v100he.cpp b/scumm/script_v100he.cpp index 507df92bab..3081f0f60b 100644 --- a/scumm/script_v100he.cpp +++ b/scumm/script_v100he.cpp @@ -589,7 +589,7 @@ void ScummEngine_v100he::o100_arrayOps() { debug(1,"o100_arrayOps: case %d", subOp); switch (subOp) { - case 35: // SO_ASSIGN_STRING + case 35: decodeScriptString(string); len = resStrLen(string) + 1; ah = defineArray(array, kStringArray, 0, 0, 0, len); @@ -737,8 +737,9 @@ void ScummEngine_v100he::o100_loadSBNG() { } void ScummEngine_v100he::o100_dim2dimArray() { - int a, b, data; - int type = fetchScriptByte(); + int data, dim1end, dim2end; + + byte type = fetchScriptByte(); switch (type) { case 41: // SO_BIT_ARRAY data = kBitArray; @@ -762,9 +763,9 @@ void ScummEngine_v100he::o100_dim2dimArray() { error("o100_dim2dimArray: default case %d", type); } - b = pop(); - a = pop(); - defineArray(fetchScriptWord(), data, 0, a, 0, b); + dim1end = pop(); + dim2end = pop(); + defineArray(fetchScriptWord(), data, 0, dim2end, 0, dim1end); } void ScummEngine_v100he::o100_dimArray() { @@ -801,7 +802,7 @@ void ScummEngine_v100he::o100_dimArray() { } void ScummEngine_v100he::o100_unknownE0() { - int id, unk1, unk2, x, x1, y1, type; + int id, unk1, unk2, x, x1, y1; unk2 = pop(); id = pop(); @@ -814,16 +815,13 @@ void ScummEngine_v100he::o100_unknownE0() { switch (subOp) { case 1: - type = 2; - unknownE0(x1, y1, x, unk1, unk2, type, id); + unknownE0(x1, y1, x, unk1, unk2, 2, id); break; case 20: - type = 1; - unknownE0(x1, y1, x, unk1, unk2, type, id); + unknownE0(x1, y1, x, unk1, unk2, 1, id); break; case 40: - type = 3; - unknownE0(x1, y1, x, unk1, unk2, type, id); + unknownE0(x1, y1, x, unk1, unk2, 3, id); break; default: error("o100_unknownE0: default case %d", subOp); diff --git a/scumm/script_v72he.cpp b/scumm/script_v72he.cpp index cd07a50965..3274280269 100644 --- a/scumm/script_v72he.cpp +++ b/scumm/script_v72he.cpp @@ -1534,7 +1534,7 @@ void ScummEngine_v72he::o72_arrayOps() { dim2start++; } break; - case 194: // SO_ASSIGN_STRING + case 194: decodeScriptString(string); len = resStrLen(string) + 1; ah = defineArray(array, kStringArray, 0, 0, 0, len); @@ -1619,8 +1619,9 @@ void ScummEngine_v72he::o72_dimArray() { void ScummEngine_v72he::o72_dim2dimArray() { - int a, b, data; - int type = fetchScriptByte(); + int data, dim1end, dim2end; + + byte type = fetchScriptByte(); switch (type) { case 2: // SO_BIT_ARRAY data = kBitArray; @@ -1644,9 +1645,9 @@ void ScummEngine_v72he::o72_dim2dimArray() { error("o72_dim2dimArray: default case %d", type); } - b = pop(); - a = pop(); - defineArray(fetchScriptWord(), data, 0, a, 0, b); + dim1end = pop(); + dim2end = pop(); + defineArray(fetchScriptWord(), data, 0, dim2end, 0, dim1end); } void ScummEngine_v72he::o72_traceStatus() { diff --git a/scumm/script_v80he.cpp b/scumm/script_v80he.cpp index e9d620358b..1385419222 100644 --- a/scumm/script_v80he.cpp +++ b/scumm/script_v80he.cpp @@ -745,7 +745,7 @@ void ScummEngine_v80he::unknownE0Helper(int x, int y, int flags) { } void ScummEngine_v80he::o80_unknownE0() { - int id, unk1, unk2, x, x1, y1, type; + int id, unk1, unk2, x, x1, y1; unk2 = pop(); id = pop(); @@ -758,16 +758,13 @@ void ScummEngine_v80he::o80_unknownE0() { switch (subOp) { case 55: - type = 2; - unknownE0(x1, y1, x, unk1, unk2, type, id); + unknownE0(x1, y1, x, unk1, unk2, 2, id); break; case 63: - type = 3; - unknownE0(x1, y1, x, unk1, unk2, type, id); + unknownE0(x1, y1, x, unk1, unk2, 3, id); break; case 66: - type = 1; - unknownE0(x1, y1, x, unk1, unk2, type, id); + unknownE0(x1, y1, x, unk1, unk2, 1, id); break; default: error("o80_unknownE0: default case %d", subOp); |