(svn r4354) [Elrail][NewGRF] Codechange: Drawing of custom waypoints with custom ground sprites used the index of the rail type as an offset. With the introduction of elrails this offset is incorrect, so instead there is now a lookup table within the RailTypeInfo struct to explicitly list the offset.

This commit is contained in:
peter1138
2006-04-11 10:45:06 +00:00
parent f472ed0ecc
commit b87b68842a
5 changed files with 21 additions and 4 deletions

View File

@@ -51,6 +51,9 @@ const RailtypeInfo _railtypes[] = {
/* bridge offset */
0,
/* custom ground offset */
0,
},
/** Electrified railway */
@@ -100,7 +103,10 @@ const RailtypeInfo _railtypes[] = {
0,
/* bridge offset */
0
0,
/* custom ground offset */
0,
},
/** Monorail */
@@ -147,6 +153,9 @@ const RailtypeInfo _railtypes[] = {
/* bridge offset */
16,
/* custom ground offset */
1,
},
/** Maglev */
@@ -193,5 +202,8 @@ const RailtypeInfo _railtypes[] = {
/* bridge offset */
24,
/* custom ground offset */
2,
},
};