(svn r14182) -Fix: After applying NewGRF settings, all rail and road types were available as the engine availability check was performed too early.

pull/155/head
peter1138 16 years ago
parent 4071e36f36
commit 2e0d735f1f

@ -279,6 +279,13 @@ void StartupEngines()
e->player_avail = 0;
}
}
/* Update the bitmasks for the vehicle lists */
Player *p;
FOR_ALL_PLAYERS(p) {
p->avail_railtypes = GetPlayerRailtypes(p->index);
p->avail_roadtypes = GetPlayerRoadtypes(p->index);
}
}
static void AcceptEnginePreview(EngineID eid, PlayerID player)

@ -6002,13 +6002,6 @@ static void AfterLoadGRFs()
}
_grf_line_to_action6_sprite_override.clear();
/* Update the bitmasks for the vehicle lists */
Player *p;
FOR_ALL_PLAYERS(p) {
p->avail_railtypes = GetPlayerRailtypes(p->index);
p->avail_roadtypes = GetPlayerRoadtypes(p->index);
}
/* Pre-calculate all refit masks after loading GRF files. */
CalculateRefitMasks();

Loading…
Cancel
Save