summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2009-05-13 16:52:51 +0000
committerrubidium <rubidium@openttd.org>2009-05-13 16:52:51 +0000
commitd23f616e9f2a381c6431d8374d52fe13f5ad5052 (patch)
tree5ac9308cffd265676ddb867b6ad1c101f1f2982b
parent3d3b5256f027a58cbbc004057659f9e5ec38c284 (diff)
downloadopenttd-d23f616e9f2a381c6431d8374d52fe13f5ad5052.tar.xz
(svn r16296) -Codechange: silence some ICC warnings
-rw-r--r--src/aircraft_cmd.cpp2
-rw-r--r--src/depot_gui.cpp12
-rw-r--r--src/newgrf.cpp2
-rw-r--r--src/table/station_land.h10
-rw-r--r--src/table/track_land.h2
-rw-r--r--src/table/unmovable_land.h2
6 files changed, 15 insertions, 15 deletions
diff --git a/src/aircraft_cmd.cpp b/src/aircraft_cmd.cpp
index 5d1f9ca1e..a11592174 100644
--- a/src/aircraft_cmd.cpp
+++ b/src/aircraft_cmd.cpp
@@ -1576,7 +1576,7 @@ static void AircraftEventHandler_AtTerminal(Vehicle *v, const AirportFTAClass *a
static void AircraftEventHandler_General(Vehicle *v, const AirportFTAClass *apc)
{
- assert("OK, you shouldn't be here, check your Airport Scheme!" && 0);
+ error("OK, you shouldn't be here, check your Airport Scheme!");
}
static void AircraftEventHandler_TakeOff(Vehicle *v, const AirportFTAClass *apc)
diff --git a/src/depot_gui.cpp b/src/depot_gui.cpp
index 3525c1909..d47265987 100644
--- a/src/depot_gui.cpp
+++ b/src/depot_gui.cpp
@@ -556,7 +556,7 @@ struct DepotWindow : Window {
*/
void HandleCloneVehClick(const Vehicle *v, const Window *w)
{
- uint error_str;
+ StringID error_str;
if (v == NULL) return;
@@ -567,14 +567,14 @@ struct DepotWindow : Window {
}
switch (v->type) {
- case VEH_TRAIN: error_str = CMD_MSG(STR_ERROR_CAN_T_BUILD_RAILROAD_VEHICLE); break;
- case VEH_ROAD: error_str = CMD_MSG(STR_ERROR_CAN_T_BUILD_ROAD_VEHICLE); break;
- case VEH_SHIP: error_str = CMD_MSG(STR_ERROR_CAN_T_BUILD_SHIP); break;
- case VEH_AIRCRAFT: error_str = CMD_MSG(STR_ERROR_CAN_T_BUILD_AIRCRAFT); break;
+ case VEH_TRAIN: error_str = STR_ERROR_CAN_T_BUILD_RAILROAD_VEHICLE; break;
+ case VEH_ROAD: error_str = STR_ERROR_CAN_T_BUILD_ROAD_VEHICLE; break;
+ case VEH_SHIP: error_str = STR_ERROR_CAN_T_BUILD_SHIP; break;
+ case VEH_AIRCRAFT: error_str = STR_ERROR_CAN_T_BUILD_AIRCRAFT; break;
default: return;
}
- DoCommandP(this->window_number, v->index, _ctrl_pressed ? 1 : 0, CMD_CLONE_VEHICLE | error_str, CcCloneVehicle);
+ DoCommandP(this->window_number, v->index, _ctrl_pressed ? 1 : 0, CMD_CLONE_VEHICLE | CMD_MSG(error_str), CcCloneVehicle);
ResetObjectToPlace();
}
diff --git a/src/newgrf.cpp b/src/newgrf.cpp
index eb0aa5fba..08978f011 100644
--- a/src/newgrf.cpp
+++ b/src/newgrf.cpp
@@ -2976,7 +2976,7 @@ static void NewSpriteGroup(byte *buf, size_t len)
}
/* Set the terminator value. */
- ((DrawTileSeqStruct*)group->g.layout.dts->seq)[i].delta_x = (byte)0x80;
+ ((DrawTileSeqStruct*)group->g.layout.dts->seq)[i].delta_x = (int8)0x80;
break;
}
diff --git a/src/table/station_land.h b/src/table/station_land.h
index 5dfcddaf6..47e0bf512 100644
--- a/src/table/station_land.h
+++ b/src/table/station_land.h
@@ -26,7 +26,7 @@
*/
#define TILE_SEQ_LINE_PAL(dx, dy, dz, sx, sy, sz, img, pal) { dx, dy, dz, sx, sy, sz, {img, pal} },
/** Constructor macro for a terminating DrawTileSeqStruct entry in an array */
-#define TILE_SEQ_END() { (byte)0x80, 0, 0, 0, 0, 0, {0, 0} }
+#define TILE_SEQ_END() { (int8)0x80, 0, 0, 0, 0, 0, {0, 0} }
static const DrawTileSeqStruct _station_display_nothing[] = {
TILE_SEQ_END()
@@ -60,7 +60,7 @@ static const DrawTileSeqStruct _station_display_datas_4[] = {
TILE_SEQ_LINE( 0, 0, 0, 16, 5, 7, SPR_RAIL_PLATFORM_PILLARS_X_REAR | (1 << PALETTE_MODIFIER_COLOUR))
TILE_SEQ_LINE( 0, 11, 0, 16, 5, 2, SPR_RAIL_PLATFORM_X_FRONT | (1 << PALETTE_MODIFIER_COLOUR))
TILE_SEQ_LINE( 0, 0, 16, 16, 16, 10, SPR_RAIL_ROOF_STRUCTURE_X_TILE_A | (1 << PALETTE_MODIFIER_COLOUR))
- TILE_SEQ_LINE_PAL( 0, 0, (byte)0x80, 0, 0, 0, SPR_RAIL_ROOF_GLASS_X_TILE_A | (1 << PALETTE_MODIFIER_TRANSPARENT), PALETTE_TO_TRANSPARENT)
+ TILE_SEQ_LINE_PAL( 0, 0, (int8)0x80, 0, 0, 0, SPR_RAIL_ROOF_GLASS_X_TILE_A | (1 << PALETTE_MODIFIER_TRANSPARENT), PALETTE_TO_TRANSPARENT)
TILE_SEQ_END()
};
@@ -68,7 +68,7 @@ static const DrawTileSeqStruct _station_display_datas_5[] = {
TILE_SEQ_LINE( 0, 0, 0, 5, 16, 2, SPR_RAIL_PLATFORM_PILLARS_Y_REAR | (1 << PALETTE_MODIFIER_COLOUR))
TILE_SEQ_LINE(11, 0, 0, 5, 16, 2, SPR_RAIL_PLATFORM_Y_FRONT | (1 << PALETTE_MODIFIER_COLOUR))
TILE_SEQ_LINE( 0, 0, 16, 16, 16, 10, SPR_RAIL_ROOF_STRUCTURE_Y_TILE_A | (1 << PALETTE_MODIFIER_COLOUR))
- TILE_SEQ_LINE_PAL( 0, 0, (byte)0x80, 0, 0, 0, SPR_RAIL_ROOF_GLASS_Y_TILE_A | (1 << PALETTE_MODIFIER_TRANSPARENT), PALETTE_TO_TRANSPARENT)
+ TILE_SEQ_LINE_PAL( 0, 0, (int8)0x80, 0, 0, 0, SPR_RAIL_ROOF_GLASS_Y_TILE_A | (1 << PALETTE_MODIFIER_TRANSPARENT), PALETTE_TO_TRANSPARENT)
TILE_SEQ_END()
};
@@ -76,7 +76,7 @@ static const DrawTileSeqStruct _station_display_datas_6[] = {
TILE_SEQ_LINE( 0, 0, 0, 16, 5, 2, SPR_RAIL_PLATFORM_X_REAR | (1 << PALETTE_MODIFIER_COLOUR))
TILE_SEQ_LINE( 0, 11, 0, 16, 5, 2, SPR_RAIL_PLATFORM_PILLARS_X_FRONT | (1 << PALETTE_MODIFIER_COLOUR))
TILE_SEQ_LINE( 0, 0, 16, 16, 16, 10, SPR_RAIL_ROOF_STRUCTURE_X_TILE_B | (1 << PALETTE_MODIFIER_COLOUR))
- TILE_SEQ_LINE_PAL( 0, 0, (byte)0x80, 0, 0, 0, SPR_RAIL_ROOF_GLASS_X_TILE_B | (1 << PALETTE_MODIFIER_TRANSPARENT), PALETTE_TO_TRANSPARENT)
+ TILE_SEQ_LINE_PAL( 0, 0, (int8)0x80, 0, 0, 0, SPR_RAIL_ROOF_GLASS_X_TILE_B | (1 << PALETTE_MODIFIER_TRANSPARENT), PALETTE_TO_TRANSPARENT)
TILE_SEQ_END()
};
@@ -84,7 +84,7 @@ static const DrawTileSeqStruct _station_display_datas_7[] = {
TILE_SEQ_LINE( 0, 0, 0, 5, 16, 2, SPR_RAIL_PLATFORM_Y_REAR | (1 << PALETTE_MODIFIER_COLOUR))
TILE_SEQ_LINE(11, 0, 0, 5, 16, 2, SPR_RAIL_PLATFORM_PILLARS_Y_FRONT | (1 << PALETTE_MODIFIER_COLOUR))
TILE_SEQ_LINE( 0, 0, 16, 16, 16, 10, SPR_RAIL_ROOF_STRUCTURE_Y_TILE_B | (1 << PALETTE_MODIFIER_COLOUR))
- TILE_SEQ_LINE_PAL( 0, 0, (byte)0x80, 0, 0, 0, SPR_RAIL_ROOF_GLASS_Y_TILE_B | (1 << PALETTE_MODIFIER_TRANSPARENT), PALETTE_TO_TRANSPARENT)
+ TILE_SEQ_LINE_PAL( 0, 0, (int8)0x80, 0, 0, 0, SPR_RAIL_ROOF_GLASS_Y_TILE_B | (1 << PALETTE_MODIFIER_TRANSPARENT), PALETTE_TO_TRANSPARENT)
TILE_SEQ_END()
};
diff --git a/src/table/track_land.h b/src/table/track_land.h
index 39c4be828..7c2a94e3c 100644
--- a/src/table/track_land.h
+++ b/src/table/track_land.h
@@ -3,7 +3,7 @@
/** @file track_land.h Sprites to use and how to display them for train depot/waypoint tiles. */
#define TILE_SEQ_LINE(img, dx, dy, sx, sy) { dx, dy, 0, sx, sy, 23, {img, PAL_NONE} },
-#define TILE_SEQ_END() { (byte)0x80, 0, 0, 0, 0, 0, {0, 0} }
+#define TILE_SEQ_END() { (int8)0x80, 0, 0, 0, 0, 0, {0, 0} }
static const DrawTileSeqStruct _depot_gfx_NE[] = {
diff --git a/src/table/unmovable_land.h b/src/table/unmovable_land.h
index 05fd44546..32a28e926 100644
--- a/src/table/unmovable_land.h
+++ b/src/table/unmovable_land.h
@@ -8,7 +8,7 @@ static const DrawTileSeqStruct _draw_tile_transmitterlighthouse_data[] = {
};
#define TILE_SEQ_LINE(sz, img) { 0, 0, 0, 16, 16, sz, {img, PAL_NONE} },
-#define TILE_SEQ_END() { (byte)0x80, 0, 0, 0, 0, 0, {0, 0} }
+#define TILE_SEQ_END() { (int8)0x80, 0, 0, 0, 0, 0, {0, 0} }
static const DrawTileSeqStruct _unmovable_display_nothing[] = {
TILE_SEQ_END()