Make 32 instead of 16 rail types possible. by using one free bit of m1 in the map array.

(cherry picked from commit b44843800880cdc186f5183301ee0f42afbb5f84)

Also set non-rail type M3 bits to 0 where applicable.
Change savegame versioning to SLXI format.
This commit is contained in:
keldorkatarn
2016-04-01 21:27:19 +02:00
committed by Jonathan G Rennison
parent 59677d5c6f
commit 5cc56d6ad9
15 changed files with 90 additions and 59 deletions

View File

@@ -131,7 +131,13 @@ static inline void MakeBridgeRamp(TileIndex t, Owner o, BridgeType bridgetype, D
SetTileType(t, MP_TUNNELBRIDGE);
SetTileOwner(t, o);
_m[t].m2 = 0;
_m[t].m3 = rt;
if (tt == TRANSPORT_RAIL) {
SB(_m[t].m1, 7, 1, GB(rt, 4, 1));
SB(_m[t].m3, 0, 4, GB(rt, 0, 4));
SB(_m[t].m3, 4, 4, 0);
} else {
_m[t].m3 = rt;
}
_m[t].m4 = 0;
_m[t].m5 = 1 << 7 | tt << 2 | d;
SB(_me[t].m6, 2, 4, bridgetype);