|
@@ -129,13 +129,14 @@ static void DrawTrainEngineInfo(EngineID
|
|
|
{
|
|
|
const RailVehicleInfo *rvi = RailVehInfo(engine);
|
|
|
int multihead = (rvi->railveh_type == RAILVEH_MULTIHEAD) ? 1 : 0;
|
|
|
const Engine *e = GetEngine(engine);
|
|
|
|
|
|
SetDParam(0, (_price.build_railvehicle >> 3) * GetEngineProperty(engine, 0x17, rvi->cost_factor) >> 5);
|
|
|
SetDParam(0, e->GetCost());
|
|
|
SetDParam(2, GetEngineProperty(engine, 0x09, rvi->max_speed) * 10 / 16);
|
|
|
SetDParam(3, GetEngineProperty(engine, 0x0B, rvi->power));
|
|
|
SetDParam(1, GetEngineProperty(engine, 0x16, rvi->weight) << multihead);
|
|
|
|
|
|
SetDParam(4, GetEngine(engine)->GetRunningCost());
|
|
|
SetDParam(4, e->GetRunningCost());
|
|
|
|
|
|
uint capacity = GetTotalCapacityOfArticulatedParts(engine, VEH_TRAIN);
|
|
|
if (capacity != 0) {
|
|
@@ -150,11 +151,13 @@ static void DrawTrainEngineInfo(EngineID
|
|
|
static void DrawAircraftEngineInfo(EngineID engine, int x, int y, int maxw)
|
|
|
{
|
|
|
const AircraftVehicleInfo *avi = AircraftVehInfo(engine);
|
|
|
SetDParam(0, (_price.aircraft_base >> 3) * GetEngineProperty(engine, 0x0B, avi->cost_factor) >> 5);
|
|
|
const Engine *e = GetEngine(engine);
|
|
|
|
|
|
SetDParam(0, e->GetCost());
|
|
|
SetDParam(1, avi->max_speed * 10 / 16);
|
|
|
SetDParam(2, avi->passenger_capacity);
|
|
|
SetDParam(3, avi->mail_capacity);
|
|
|
SetDParam(4, GetEngine(engine)->GetRunningCost());
|
|
|
SetDParam(4, e->GetRunningCost());
|
|
|
|
|
|
DrawStringMultiCenter(x, y, STR_A02E_COST_MAX_SPEED_CAPACITY, maxw);
|
|
|
}
|
|
@@ -162,10 +165,11 @@ static void DrawAircraftEngineInfo(Engin
|
|
|
static void DrawRoadVehEngineInfo(EngineID engine, int x, int y, int maxw)
|
|
|
{
|
|
|
const RoadVehicleInfo *rvi = RoadVehInfo(engine);
|
|
|
const Engine *e = GetEngine(engine);
|
|
|
|
|
|
SetDParam(0, (_price.roadveh_base >> 3) * GetEngineProperty(engine, 0x11, rvi->cost_factor) >> 5);
|
|
|
SetDParam(0, e->GetCost());
|
|
|
SetDParam(1, rvi->max_speed * 10 / 32);
|
|
|
SetDParam(2, GetEngine(engine)->GetRunningCost());
|
|
|
SetDParam(2, e->GetRunningCost());
|
|
|
SetDParam(3, rvi->cargo_type);
|
|
|
SetDParam(4, GetTotalCapacityOfArticulatedParts(engine, VEH_ROAD));
|
|
|
|
|
@@ -175,11 +179,13 @@ static void DrawRoadVehEngineInfo(Engine
|
|
|
static void DrawShipEngineInfo(EngineID engine, int x, int y, int maxw)
|
|
|
{
|
|
|
const ShipVehicleInfo *svi = ShipVehInfo(engine);
|
|
|
SetDParam(0, GetEngineProperty(engine, 0x0A, svi->cost_factor) * (_price.ship_base >> 3) >> 5);
|
|
|
const Engine *e = GetEngine(engine);
|
|
|
|
|
|
SetDParam(0, e->GetCost());
|
|
|
SetDParam(1, GetEngineProperty(engine, 0x0B, svi->max_speed) * 10 / 32);
|
|
|
SetDParam(2, svi->cargo_type);
|
|
|
SetDParam(3, GetEngineProperty(engine, 0x0D, svi->capacity));
|
|
|
SetDParam(4, GetEngine(engine)->GetRunningCost());
|
|
|
SetDParam(4, e->GetRunningCost());
|
|
|
DrawStringMultiCenter(x, y, STR_982E_COST_MAX_SPEED_CAPACITY, maxw);
|
|
|
}
|
|
|
|