aboutsummaryrefslogtreecommitdiff
path: root/engines/tsage/ringworld2/ringworld2_scenes1.cpp
diff options
context:
space:
mode:
authorStrangerke2013-11-09 15:05:56 +0100
committerStrangerke2013-11-09 15:05:56 +0100
commit2f9c2a937029abc0a9a4988b223b2832b433d6cb (patch)
treed88cb1aeac88230ec1e428560d40ad8816d722d0 /engines/tsage/ringworld2/ringworld2_scenes1.cpp
parente4387e754a5de39cf1407ca11777f49a6b5a9f99 (diff)
downloadscummvm-rg350-2f9c2a937029abc0a9a4988b223b2832b433d6cb.tar.gz
scummvm-rg350-2f9c2a937029abc0a9a4988b223b2832b433d6cb.tar.bz2
scummvm-rg350-2f9c2a937029abc0a9a4988b223b2832b433d6cb.zip
TSAGE: R2R - Add some CHECKMEs, remove some deadcode (CID 1004056)
Diffstat (limited to 'engines/tsage/ringworld2/ringworld2_scenes1.cpp')
-rw-r--r--engines/tsage/ringworld2/ringworld2_scenes1.cpp20
1 files changed, 7 insertions, 13 deletions
diff --git a/engines/tsage/ringworld2/ringworld2_scenes1.cpp b/engines/tsage/ringworld2/ringworld2_scenes1.cpp
index 298bff0d80..4bc82c7059 100644
--- a/engines/tsage/ringworld2/ringworld2_scenes1.cpp
+++ b/engines/tsage/ringworld2/ringworld2_scenes1.cpp
@@ -6018,7 +6018,7 @@ void Scene1337::subCF31D() {
count = rndVal;
break;
}
-
+ // CHECKME: inside the check on rndVal?
rndVal--;
if (rndVal < 0)
rndVal = 3;
@@ -6042,9 +6042,10 @@ void Scene1337::subCF31D() {
int rndVal = R2_GLOBALS._randomSource.getRandomNumber(3);
for (int j = 0; j <= 3; j++) {
+ //CHECKME: tmpVal or rndVal?
if (tmpVal != 1) {
for (int k = 0; k <= 7; k++) {
- // 'k' is not used in that loop.
+ // CHECKME: 'k' is not used in that loop.
// It looks suspicious.
if ((_arrunkObj1337[tmpVal]._arr3[0]._field34 == 0) && (subC32B1(tmpVal, _arrunkObj1337[1]._arr1[i]._field34))) {
count = tmpVal;
@@ -6068,12 +6069,9 @@ void Scene1337::subCF31D() {
}
}
- if (found) {
- if (count == -1)
- return;
-
+ if (found)
subC3456(&_arrunkObj1337[1]._arr1[i], &_arrunkObj1337[count]._arr3[0]);
- } else {
+ else {
int j;
for (j = 0; j <= 3; j++) {
if (subC27F9(_arrunkObj1337[1]._arr1[j]._field34) != -1) {
@@ -6103,14 +6101,10 @@ void Scene1337::subCF31D() {
}
}
- if (found) {
- if (count == -1)
- return;
-
+ if (found)
subC3456(&_arrunkObj1337[1]._arr1[j], &_arrunkObj1337[count]._arr3[0]);
- } else {
+ else
subC2835(1);
- }
}
}