aboutsummaryrefslogtreecommitdiff
path: root/engines/supernova/supernova2
diff options
context:
space:
mode:
authorD G Turner2019-12-01 00:31:33 +0000
committerD G Turner2019-12-01 00:31:33 +0000
commit719decda5545af100defe6faadaa919004d3c8af (patch)
treebb5a0c905d11097c915d10505fa9d51ec9a38e3f /engines/supernova/supernova2
parentf80947183c16e4be5f651f0ba2202446faf1ba8b (diff)
downloadscummvm-rg350-719decda5545af100defe6faadaa919004d3c8af.tar.gz
scummvm-rg350-719decda5545af100defe6faadaa919004d3c8af.tar.bz2
scummvm-rg350-719decda5545af100defe6faadaa919004d3c8af.zip
SUPERNOVA: Fix Missing Default Switch Cases
These are flagged by GCC if -Wswitch-default is enabled.
Diffstat (limited to 'engines/supernova/supernova2')
-rw-r--r--engines/supernova/supernova2/rooms.cpp14
-rw-r--r--engines/supernova/supernova2/state.cpp10
2 files changed, 24 insertions, 0 deletions
diff --git a/engines/supernova/supernova2/rooms.cpp b/engines/supernova/supernova2/rooms.cpp
index 4e8c428fb9..db60a48c35 100644
--- a/engines/supernova/supernova2/rooms.cpp
+++ b/engines/supernova/supernova2/rooms.cpp
@@ -459,6 +459,8 @@ void Street::animation() {
setSectionVisible(4, kShownTrue);
setSectionVisible(5, kShownTrue);
break;
+ default:
+ break;
}
banks++;
if (banks == 10) banks = 0;
@@ -779,6 +781,8 @@ bool Kiosk::interact(Action verb, Object &obj1, Object &obj2) {
case 2:
_gm->reply(kStringImSorry, 1, 1 + kSectionInvert);
break;
+ default:
+ break;
}
_gm->drawGUI();
} else
@@ -894,6 +898,8 @@ bool CulturePalace::interact(Action verb, Object &obj1, Object &obj2) {
_shown[kMaxSection - 2] = true;
}
break;
+ default:
+ break;
}
}
_vm->renderImage(1 + kSectionInvert);
@@ -1135,6 +1141,8 @@ bool Checkout::interact(Action verb, Object &obj1, Object &obj2) {
case 2:
_gm->reply(kStringCheckout47, 1, 1 + kSectionInvert);
break;
+ default:
+ break;
}
_gm->drawGUI();
break;
@@ -1144,6 +1152,8 @@ bool Checkout::interact(Action verb, Object &obj1, Object &obj2) {
case 2:
_gm->reply(kStringCheckout49, 1, 1 + kSectionInvert);
break;
+ default:
+ break;
}
}
} else
@@ -1661,6 +1671,8 @@ bool Elevator2::interact(Action verb, Object &obj1, Object &obj2) {
setSectionVisible(2, kShownFalse);
_vm->renderImage(1 + kSectionInvert);
break;
+ default:
+ break;
}
_gm->drawGUI();
} else
@@ -1757,6 +1769,8 @@ void Elevator2::jobDescription() {
case 2:
_gm->reply(kStringElevator52, 1, 1 + kSectionInvert);
break;
+ default:
+ break;
}
if (e == 1 || e == 2)
_gm->reply(kStringElevator53, 1, 1 + kSectionInvert);
diff --git a/engines/supernova/supernova2/state.cpp b/engines/supernova/supernova2/state.cpp
index 28a2c0a710..e61d4e1779 100644
--- a/engines/supernova/supernova2/state.cpp
+++ b/engines/supernova/supernova2/state.cpp
@@ -824,6 +824,8 @@ void GameManager2::taxiPayment(int price, int destination) {
case 11:
changeRoom(CITY2);
break;
+ default:
+ break;
}
}
}
@@ -1065,6 +1067,8 @@ void GameManager2::passageConstruction() {
_rooms[PYR_ENTRANCE]->setSectionVisible(21, kShownTrue);
_rooms[PYR_ENTRANCE]->getObject(0)->_click = 9;
break;
+ default:
+ break;
}
}
_rooms[PYR_ENTRANCE]->setSectionVisible(9,
@@ -1158,6 +1162,8 @@ byte GameManager2::wall(int s, int z, int direction, int stepsForward, int steps
return wall(s + stepsForward, z, newR, stepsRight, 0);
case 3:
return wall(s - stepsForward, z, newR, stepsRight, 0);
+ default:
+ break;
}
}
switch (direction) {
@@ -1169,6 +1175,8 @@ byte GameManager2::wall(int s, int z, int direction, int stepsForward, int steps
return horizontal[_state._pyraE][z][s + stepsForward] == 0;
case 3:
return horizontal[_state._pyraE][z][s + 1 - stepsForward] == 0;
+ default:
+ break;
}
return 0;
}
@@ -1188,6 +1196,8 @@ bool GameManager2::move(Action verb, Object &obj) {
case 3:
_state._pyraS--;
break;
+ default:
+ break;
}
} else if (verb == ACTION_WALK && obj._id == G_RIGHT) {
_state._pyraDirection++;