aboutsummaryrefslogtreecommitdiff
path: root/engines/tsage
diff options
context:
space:
mode:
authorStrangerke2013-12-13 07:43:43 +0100
committerStrangerke2013-12-13 07:44:14 +0100
commite79022bf3428354c8c7bcde4fa0406636bc8ded4 (patch)
tree971a322604fb9d55210e6783f5e1eaf4b67709eb /engines/tsage
parentfbc0133ac0cbea90dabbe7333d4dcedc53f78ad7 (diff)
downloadscummvm-rg350-e79022bf3428354c8c7bcde4fa0406636bc8ded4.tar.gz
scummvm-rg350-e79022bf3428354c8c7bcde4fa0406636bc8ded4.tar.bz2
scummvm-rg350-e79022bf3428354c8c7bcde4fa0406636bc8ded4.zip
TSAGE: R2R - Fix CID 1004055 - Dead code due to incomplete hardcoded logic
Diffstat (limited to 'engines/tsage')
-rw-r--r--engines/tsage/ringworld2/ringworld2_scenes1.cpp25
-rw-r--r--engines/tsage/ringworld2/ringworld2_scenes1.h2
2 files changed, 18 insertions, 9 deletions
diff --git a/engines/tsage/ringworld2/ringworld2_scenes1.cpp b/engines/tsage/ringworld2/ringworld2_scenes1.cpp
index abef2061c0..39072f0329 100644
--- a/engines/tsage/ringworld2/ringworld2_scenes1.cpp
+++ b/engines/tsage/ringworld2/ringworld2_scenes1.cpp
@@ -5073,9 +5073,9 @@ void Scene1337::playDelayCard(Card *card, Card *dest) {
_item1.setAction(&_action9);
}
-void Scene1337::subC34A1(Card *subObj1, Card *subObj2) {
- _actionCard1 = subObj1;
- _actionCard2 = subObj2;
+void Scene1337::playAntiDelayCard(Card *card, Card *dest) {
+ _actionCard1 = card;
+ _actionCard2 = dest;
_item1.setAction(&_action8);
}
@@ -5800,7 +5800,7 @@ void Scene1337::handlePlayer0() {
if (found) {
found = false;
- subC34A1(&_gameBoardSide[0]._handCard[i], &_gameBoardSide[0]._delayCard);
+ playAntiDelayCard(&_gameBoardSide[0]._handCard[i], &_gameBoardSide[0]._delayCard);
}
break;
}
@@ -6054,7 +6054,7 @@ void Scene1337::handlePlayer1() {
if (found) {
tmpVal = 0;
- subC34A1(&_gameBoardSide[1]._handCard[i], &_gameBoardSide[1]._delayCard);
+ playAntiDelayCard(&_gameBoardSide[1]._handCard[i], &_gameBoardSide[1]._delayCard);
}
}
}
@@ -6264,7 +6264,7 @@ void Scene1337::handlePlayer3() {
if (found) {
found = false;
- subC34A1(&_gameBoardSide[3]._handCard[i], &_gameBoardSide[3]._delayCard);
+ playAntiDelayCard(&_gameBoardSide[3]._handCard[i], &_gameBoardSide[3]._delayCard);
}
break;
}
@@ -6585,11 +6585,20 @@ void Scene1337::subD02CA() {
}
}
if (foundVar4) {
+ // This station is already in place
actionDisplay(1330, 34, 159, 10, 1, 200, 0, 7, 0, 154, 154);
} else if (subC27B5(_gameBoardSide[2]._delayCard._cardId) != -1) {
+ // You must eliminate your delay before you can play a station
actionDisplay(1330, 35, 159, 10, 1, 200, 0, 7, 0, 154, 154);
} else {
- if (j == 7)
+ int tmpVal = 0;
+
+ for (int j = 0; j <= 7; j++) {
+ if ((_gameBoardSide[2]._outpostStation[j]._cardId > 1) && (_gameBoardSide[2]._outpostStation[j]._cardId <= 9))
+ ++tmpVal;
+ }
+
+ if (tmpVal == 7)
_winnerId = 2;
subC33C0(&_selectedCard, &_gameBoardSide[2]._outpostStation[i]);
@@ -6624,7 +6633,7 @@ void Scene1337::subD02CA() {
actionDisplay(1330, 41, 159, 10, 1, 200, 0, 7, 0, 154, 154);
}
} else {
- subC34A1(&_selectedCard, &_gameBoardSide[2]._delayCard);
+ playAntiDelayCard(&_selectedCard, &_gameBoardSide[2]._delayCard);
return;
}
} else {
diff --git a/engines/tsage/ringworld2/ringworld2_scenes1.h b/engines/tsage/ringworld2/ringworld2_scenes1.h
index a6de5400d2..6cbc617578 100644
--- a/engines/tsage/ringworld2/ringworld2_scenes1.h
+++ b/engines/tsage/ringworld2/ringworld2_scenes1.h
@@ -350,7 +350,7 @@ public:
void subC33C0(Card *subObj1, Card *subObj2);
void playDelayCard(Card *card, Card *dest);
void playCard(Card *card, Card *dest);
- void subC34A1(Card *subObj1, Card *subObj2);
+ void playAntiDelayCard(Card *card, Card *dest);
Card *subC34EC(int arg1);
void playCounterTrickCard(Card *card, int playerId);
int getFreeHandCard(int playerId);