summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2011-07-10 13:25:52 +0000
committerfrosch <frosch@openttd.org>2011-07-10 13:25:52 +0000
commit9afe1c1d20d3bc83ca5abc270cbd54dd39d66795 (patch)
treef4793ef73f55bc6696a7b06ca9e13457507608f7
parent3639456cc4ffce75469f1c523706d9abb311b266 (diff)
downloadopenttd-9afe1c1d20d3bc83ca5abc270cbd54dd39d66795.tar.xz
(svn r22648) -Fix (r22629): Missing 'break'. (thanks michi_cc)
-rw-r--r--src/newgrf_industries.cpp8
-rw-r--r--src/newgrf_industrytiles.cpp8
2 files changed, 8 insertions, 8 deletions
diff --git a/src/newgrf_industries.cpp b/src/newgrf_industries.cpp
index a99a58152..fa4fdf197 100644
--- a/src/newgrf_industries.cpp
+++ b/src/newgrf_industries.cpp
@@ -548,10 +548,10 @@ CommandCost CheckIfCallBackAllowsCreation(TileIndex tile, IndustryType type, uin
CommandCost res;
switch (result) {
- case 0x401: res = CommandCost(STR_ERROR_SITE_UNSUITABLE);
- case 0x402: res = CommandCost(STR_ERROR_CAN_ONLY_BE_BUILT_IN_RAINFOREST);
- case 0x403: res = CommandCost(STR_ERROR_CAN_ONLY_BE_BUILT_IN_DESERT);
- default: res = CommandCost(GetGRFStringID(indspec->grf_prop.grffile->grfid, 0xD000 + result));
+ case 0x401: res = CommandCost(STR_ERROR_SITE_UNSUITABLE); break;
+ case 0x402: res = CommandCost(STR_ERROR_CAN_ONLY_BE_BUILT_IN_RAINFOREST); break;
+ case 0x403: res = CommandCost(STR_ERROR_CAN_ONLY_BE_BUILT_IN_DESERT); break;
+ default: res = CommandCost(GetGRFStringID(indspec->grf_prop.grffile->grfid, 0xD000 + result)); break;
}
/* Copy some parameters from the registers to the error message text ref. stack */
diff --git a/src/newgrf_industrytiles.cpp b/src/newgrf_industrytiles.cpp
index 1191f3162..3315de46e 100644
--- a/src/newgrf_industrytiles.cpp
+++ b/src/newgrf_industrytiles.cpp
@@ -307,10 +307,10 @@ CommandCost PerformIndustryTileSlopeCheck(TileIndex ind_base_tile, TileIndex ind
CommandCost res;
switch (callback_res) {
- case 0x401: res = CommandCost(STR_ERROR_SITE_UNSUITABLE);
- case 0x402: res = CommandCost(STR_ERROR_CAN_ONLY_BE_BUILT_IN_RAINFOREST);
- case 0x403: res = CommandCost(STR_ERROR_CAN_ONLY_BE_BUILT_IN_DESERT);
- default: res = CommandCost(GetGRFStringID(its->grf_prop.grffile->grfid, 0xD000 + callback_res));
+ case 0x401: res = CommandCost(STR_ERROR_SITE_UNSUITABLE); break;
+ case 0x402: res = CommandCost(STR_ERROR_CAN_ONLY_BE_BUILT_IN_RAINFOREST); break;
+ case 0x403: res = CommandCost(STR_ERROR_CAN_ONLY_BE_BUILT_IN_DESERT); break;
+ default: res = CommandCost(GetGRFStringID(its->grf_prop.grffile->grfid, 0xD000 + callback_res)); break;
}
/* Copy some parameters from the registers to the error message text ref. stack */