summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--bin/data/openttdd.grfbin420772 -> 423160 bytes
-rw-r--r--bin/data/openttdw.grfbin420944 -> 423347 bytes
-rw-r--r--src/newgrf.cpp44
-rw-r--r--src/rail.h1
-rw-r--r--src/table/files.h4
-rw-r--r--src/table/railtypes.h4
-rw-r--r--src/table/sprites.h8
7 files changed, 36 insertions, 25 deletions
diff --git a/bin/data/openttdd.grf b/bin/data/openttdd.grf
index 003ed9947..63afdefc7 100644
--- a/bin/data/openttdd.grf
+++ b/bin/data/openttdd.grf
Binary files differ
diff --git a/bin/data/openttdw.grf b/bin/data/openttdw.grf
index ee5694b74..4dd781ac9 100644
--- a/bin/data/openttdw.grf
+++ b/bin/data/openttdw.grf
Binary files differ
diff --git a/src/newgrf.cpp b/src/newgrf.cpp
index cb5d5cf53..353034423 100644
--- a/src/newgrf.cpp
+++ b/src/newgrf.cpp
@@ -3433,28 +3433,28 @@ static void GraphicsNew(byte *buf, size_t len)
static const Action5Type action5_types[] = {
/* Note: min_sprites should not be changed. Therefore these constants are directly here and not in sprites.h */
- /* 0x00 */ { A5BLOCK_INVALID, 0, 0, 0, "Type 0x00" },
- /* 0x01 */ { A5BLOCK_INVALID, 0, 0, 0, "Type 0x01" },
- /* 0x02 */ { A5BLOCK_INVALID, 0, 0, 0, "Type 0x02" },
- /* 0x03 */ { A5BLOCK_INVALID, 0, 0, 0, "Type 0x03" },
- /* 0x04 */ { A5BLOCK_FIXED, SPR_SIGNALS_BASE, 48, PRESIGNAL_SEMAPHORE_AND_PBS_SPRITE_COUNT, "Signal graphics" },
- /* 0x05 */ { A5BLOCK_FIXED, SPR_ELRAIL_BASE, 48, ELRAIL_SPRITE_COUNT, "Catenary graphics" },
- /* 0x06 */ { A5BLOCK_FIXED, SPR_SLOPES_BASE, 74, NORMAL_AND_HALFTILE_FOUNDATION_SPRITE_COUNT, "Foundation graphics" },
- /* 0x07 */ { A5BLOCK_INVALID, 0, 75, 0, "TTDP GUI graphics" }, // Not used by OTTD.
- /* 0x08 */ { A5BLOCK_FIXED, SPR_CANALS_BASE, 65, CANALS_SPRITE_COUNT, "Canal graphics" },
- /* 0x09 */ { A5BLOCK_FIXED, SPR_ONEWAY_BASE, 6, ONEWAY_SPRITE_COUNT, "One way road graphics" },
- /* 0x0A */ { A5BLOCK_FIXED, SPR_2CCMAP_BASE, 256, TWOCCMAP_SPRITE_COUNT, "2CC colour maps" },
- /* 0x0B */ { A5BLOCK_FIXED, SPR_TRAMWAY_BASE, 113, TRAMWAY_SPRITE_COUNT, "Tramway graphics" },
- /* 0x0C */ { A5BLOCK_INVALID, 0, 133, 0, "Snowy temperate tree" }, // Not yet used by OTTD.
- /* 0x0D */ { A5BLOCK_FIXED, SPR_SHORE_BASE, 16, SPR_SHORE_SPRITE_COUNT, "Shore graphics" },
- /* 0x0E */ { A5BLOCK_INVALID, 0, 0, 0, "New Signals graphics" }, // Not yet used by OTTD.
- /* 0x0F */ { A5BLOCK_INVALID, 0, 12, 0, "Sloped rail track" }, // Not yet used by OTTD.
- /* 0x10 */ { A5BLOCK_FIXED, SPR_AIRPORTX_BASE, 15, AIRPORTX_SPRITE_COUNT, "Airport graphics" },
- /* 0x11 */ { A5BLOCK_FIXED, SPR_ROADSTOP_BASE, 8, ROADSTOP_SPRITE_COUNT, "Road stop graphics" },
- /* 0x12 */ { A5BLOCK_FIXED, SPR_AQUEDUCT_BASE, 8, AQUEDUCT_SPRITE_COUNT, "Aqueduct graphics" },
- /* 0x13 */ { A5BLOCK_FIXED, SPR_AUTORAIL_BASE, 55, AUTORAIL_SPRITE_COUNT, "Autorail graphics" },
- /* 0x14 */ { A5BLOCK_ALLOW_OFFSET, SPR_FLAGS_BASE, 1, FLAGS_SPRITE_COUNT, "Flag graphics" },
- /* 0x15 */ { A5BLOCK_ALLOW_OFFSET, SPR_OPENTTD_BASE, 1, OPENTTD_SPRITE_COUNT, "OpenTTD GUI graphics" },
+ /* 0x00 */ { A5BLOCK_INVALID, 0, 0, 0, "Type 0x00" },
+ /* 0x01 */ { A5BLOCK_INVALID, 0, 0, 0, "Type 0x01" },
+ /* 0x02 */ { A5BLOCK_INVALID, 0, 0, 0, "Type 0x02" },
+ /* 0x03 */ { A5BLOCK_INVALID, 0, 0, 0, "Type 0x03" },
+ /* 0x04 */ { A5BLOCK_FIXED, SPR_SIGNALS_BASE, 48, PRESIGNAL_SEMAPHORE_AND_PBS_SPRITE_COUNT, "Signal graphics" },
+ /* 0x05 */ { A5BLOCK_FIXED, SPR_ELRAIL_BASE, 48, ELRAIL_SPRITE_COUNT, "Catenary graphics" },
+ /* 0x06 */ { A5BLOCK_FIXED, SPR_SLOPES_BASE, 74, NORMAL_AND_HALFTILE_FOUNDATION_SPRITE_COUNT, "Foundation graphics" },
+ /* 0x07 */ { A5BLOCK_INVALID, 0, 75, 0, "TTDP GUI graphics" }, // Not used by OTTD.
+ /* 0x08 */ { A5BLOCK_FIXED, SPR_CANALS_BASE, 65, CANALS_SPRITE_COUNT, "Canal graphics" },
+ /* 0x09 */ { A5BLOCK_FIXED, SPR_ONEWAY_BASE, 6, ONEWAY_SPRITE_COUNT, "One way road graphics" },
+ /* 0x0A */ { A5BLOCK_FIXED, SPR_2CCMAP_BASE, 256, TWOCCMAP_SPRITE_COUNT, "2CC colour maps" },
+ /* 0x0B */ { A5BLOCK_FIXED, SPR_TRAMWAY_BASE, 113, TRAMWAY_SPRITE_COUNT, "Tramway graphics" },
+ /* 0x0C */ { A5BLOCK_INVALID, 0, 133, 0, "Snowy temperate tree" }, // Not yet used by OTTD.
+ /* 0x0D */ { A5BLOCK_FIXED, SPR_SHORE_BASE, 16, SPR_SHORE_SPRITE_COUNT, "Shore graphics" },
+ /* 0x0E */ { A5BLOCK_INVALID, 0, 0, 0, "New Signals graphics" }, // Not yet used by OTTD.
+ /* 0x0F */ { A5BLOCK_FIXED, SPR_TRACKS_FOR_SLOPES_BASE, 12, TRACKS_FOR_SLOPES_SPRITE_COUNT, "Sloped rail track" },
+ /* 0x10 */ { A5BLOCK_FIXED, SPR_AIRPORTX_BASE, 15, AIRPORTX_SPRITE_COUNT, "Airport graphics" },
+ /* 0x11 */ { A5BLOCK_FIXED, SPR_ROADSTOP_BASE, 8, ROADSTOP_SPRITE_COUNT, "Road stop graphics" },
+ /* 0x12 */ { A5BLOCK_FIXED, SPR_AQUEDUCT_BASE, 8, AQUEDUCT_SPRITE_COUNT, "Aqueduct graphics" },
+ /* 0x13 */ { A5BLOCK_FIXED, SPR_AUTORAIL_BASE, 55, AUTORAIL_SPRITE_COUNT, "Autorail graphics" },
+ /* 0x14 */ { A5BLOCK_ALLOW_OFFSET, SPR_FLAGS_BASE, 1, FLAGS_SPRITE_COUNT, "Flag graphics" },
+ /* 0x15 */ { A5BLOCK_ALLOW_OFFSET, SPR_OPENTTD_BASE, 1, OPENTTD_SPRITE_COUNT, "OpenTTD GUI graphics" },
};
if (!check_length(len, 2, "GraphicsNew")) return;
diff --git a/src/rail.h b/src/rail.h
index 331674f30..894dd244b 100644
--- a/src/rail.h
+++ b/src/rail.h
@@ -38,6 +38,7 @@ struct RailtypeInfo {
SpriteID single_s; ///< single piece of rail in the southern corner
SpriteID single_e; ///< single piece of rail in the eastern corner
SpriteID single_w; ///< single piece of rail in the western corner
+ SpriteID single_sloped;///< single piecs of rail for slopes
SpriteID crossing; ///< level crossing, rail in X direction
SpriteID tunnel; ///< tunnel sprites base
} base_sprites;
diff --git a/src/table/files.h b/src/table/files.h
index 1174d7483..c49859196 100644
--- a/src/table/files.h
+++ b/src/table/files.h
@@ -35,7 +35,7 @@ static FileList files_dos = {
{ "TRGT.GRF", {0xfc, 0xde, 0x1d, 0x7e, 0x8a, 0x74, 0x19, 0x7d, 0x72, 0xa6, 0x26, 0x95, 0x88, 0x4b, 0x90, 0x9e} }
},
{ "SAMPLE.CAT", {0x42, 0x2e, 0xa3, 0xdd, 0x07, 0x4d, 0x28, 0x59, 0xbb, 0x51, 0x63, 0x9a, 0x6e, 0x0e, 0x85, 0xda} },
- { "OPENTTDD.GRF", {0x43, 0x3d, 0x38, 0xa9, 0x7a, 0xd7, 0x5a, 0xc2, 0x52, 0xf6, 0x52, 0x49, 0x38, 0x15, 0x0a, 0x71} }
+ { "OPENTTDD.GRF", {0x1e, 0x6c, 0x85, 0x87, 0xfa, 0x9c, 0x84, 0xed, 0x51, 0xc7, 0x96, 0x4c, 0x91, 0xcf, 0x61, 0xa4} }
};
@@ -49,5 +49,5 @@ static FileList files_win = {
{ "TRGTR.GRF", {0xde, 0x53, 0x65, 0x05, 0x17, 0xfe, 0x66, 0x1c, 0xea, 0xa3, 0x13, 0x8c, 0x6e, 0xdb, 0x0e, 0xb8} }
},
{ "SAMPLE.CAT", {0x92, 0x12, 0xe8, 0x1e, 0x72, 0xba, 0xdd, 0x4b, 0xbe, 0x1e, 0xae, 0xae, 0x66, 0x45, 0x8e, 0x10} },
- { "OPENTTDW.GRF", {0x40, 0xb4, 0x75, 0xe2, 0xd9, 0x55, 0x6e, 0x30, 0x5f, 0x3f, 0x8d, 0xb3, 0xbe, 0x10, 0x36, 0x17} }
+ { "OPENTTDW.GRF", {0x08, 0x2b, 0x0e, 0x53, 0x1a, 0x4e, 0x02, 0xb2, 0x1a, 0x87, 0x52, 0x08, 0x64, 0xab, 0xf8, 0xf4} }
};
diff --git a/src/table/railtypes.h b/src/table/railtypes.h
index e569fe408..0d86851f5 100644
--- a/src/table/railtypes.h
+++ b/src/table/railtypes.h
@@ -14,6 +14,7 @@ RailtypeInfo _railtypes[] = {
{ /* Main Sprites */
{ SPR_RAIL_TRACK_Y, SPR_RAIL_TRACK_N_S, SPR_RAIL_TRACK_BASE, SPR_RAIL_SINGLE_Y, SPR_RAIL_SINGLE_X,
SPR_RAIL_SINGLE_NORTH, SPR_RAIL_SINGLE_SOUTH, SPR_RAIL_SINGLE_EAST, SPR_RAIL_SINGLE_WEST,
+ SPR_TRACKS_FOR_SLOPES_RAIL_BASE,
SPR_CROSSING_OFF_X_RAIL,
SPR_TUNNEL_ENTRY_REAR_RAIL
},
@@ -69,6 +70,7 @@ RailtypeInfo _railtypes[] = {
{ /* Main Sprites */
{ SPR_RAIL_TRACK_Y, SPR_RAIL_TRACK_N_S, SPR_RAIL_TRACK_BASE, SPR_RAIL_SINGLE_Y, SPR_RAIL_SINGLE_X,
SPR_RAIL_SINGLE_NORTH, SPR_RAIL_SINGLE_SOUTH, SPR_RAIL_SINGLE_EAST, SPR_RAIL_SINGLE_WEST,
+ SPR_TRACKS_FOR_SLOPES_RAIL_BASE,
SPR_CROSSING_OFF_X_RAIL,
SPR_TUNNEL_ENTRY_REAR_RAIL
},
@@ -128,6 +130,7 @@ RailtypeInfo _railtypes[] = {
{ /* Main Sprites */
{ SPR_MONO_TRACK_Y, SPR_MONO_TRACK_N_S, SPR_MONO_TRACK_BASE, SPR_MONO_SINGLE_Y, SPR_MONO_SINGLE_X,
SPR_MONO_SINGLE_NORTH, SPR_MONO_SINGLE_SOUTH, SPR_MONO_SINGLE_EAST, SPR_MONO_SINGLE_WEST,
+ SPR_TRACKS_FOR_SLOPES_MONO_BASE,
SPR_CROSSING_OFF_X_MONO,
SPR_TUNNEL_ENTRY_REAR_MONO
},
@@ -183,6 +186,7 @@ RailtypeInfo _railtypes[] = {
{ /* Main sprites */
{ SPR_MGLV_TRACK_Y, SPR_MGLV_TRACK_N_S, SPR_MGLV_TRACK_BASE, SPR_MGLV_SINGLE_Y, SPR_MGLV_SINGLE_X,
SPR_MGLV_SINGLE_NORTH, SPR_MGLV_SINGLE_SOUTH, SPR_MGLV_SINGLE_EAST, SPR_MGLV_SINGLE_WEST,
+ SPR_TRACKS_FOR_SLOPES_MAGLEV_BASE,
SPR_CROSSING_OFF_X_MAGLEV,
SPR_TUNNEL_ENTRY_REAR_MAGLEV
},
diff --git a/src/table/sprites.h b/src/table/sprites.h
index c427be684..02b0997cc 100644
--- a/src/table/sprites.h
+++ b/src/table/sprites.h
@@ -143,7 +143,13 @@ enum Sprites {
SPR_AQUEDUCT_PILLAR_Y = SPR_AQUEDUCT_BASE + 7,
AQUEDUCT_SPRITE_COUNT = 8,
- SPR_SLOPES_BASE = SPR_AQUEDUCT_BASE + AQUEDUCT_SPRITE_COUNT,
+ SPR_TRACKS_FOR_SLOPES_BASE = SPR_AQUEDUCT_BASE + AQUEDUCT_SPRITE_COUNT,
+ SPR_TRACKS_FOR_SLOPES_RAIL_BASE = SPR_AQUEDUCT_BASE + 0,
+ SPR_TRACKS_FOR_SLOPES_MONO_BASE = SPR_AQUEDUCT_BASE + 4,
+ SPR_TRACKS_FOR_SLOPES_MAGLEV_BASE = SPR_AQUEDUCT_BASE + 8,
+ TRACKS_FOR_SLOPES_SPRITE_COUNT = 12,
+
+ SPR_SLOPES_BASE = SPR_TRACKS_FOR_SLOPES_BASE + TRACKS_FOR_SLOPES_SPRITE_COUNT,
SPR_SLOPES_INCLINED_OFFSET = 15,
SPR_SLOPES_VIRTUAL_BASE = SPR_SLOPES_BASE - SPR_SLOPES_INCLINED_OFFSET, // The original foundations (see SPR_FOUNDATION_BASE below) are mapped before the additional foundations.
SPR_TRKFOUND_BLOCK_SIZE = 22, // The normal track foundation sprites are organized in blocks of 22.