equal
deleted
inserted
replaced
376 DrawString(x, y, STR_PURCHASE_INFO_WEIGHT_CWEIGHT, 0); |
376 DrawString(x, y, STR_PURCHASE_INFO_WEIGHT_CWEIGHT, 0); |
377 y += 10; |
377 y += 10; |
378 |
378 |
379 /* Wagon speed limit, displayed if above zero */ |
379 /* Wagon speed limit, displayed if above zero */ |
380 if (rvi->max_speed > 0 && _patches.wagon_speed_limits) { |
380 if (rvi->max_speed > 0 && _patches.wagon_speed_limits) { |
381 SetDParam(0, rvi->max_speed); |
381 SetDParam(0, rvi->max_speed * 10 / 16); |
382 DrawString(x,y, STR_PURCHASE_INFO_SPEED, 0); |
382 DrawString(x,y, STR_PURCHASE_INFO_SPEED, 0); |
383 y += 10; |
383 y += 10; |
384 } |
384 } |
385 return y; |
385 return y; |
386 } |
386 } |
395 SetDParam(1, rvi->weight << multihead); |
395 SetDParam(1, rvi->weight << multihead); |
396 DrawString(x,y, STR_PURCHASE_INFO_COST_WEIGHT, 0); |
396 DrawString(x,y, STR_PURCHASE_INFO_COST_WEIGHT, 0); |
397 y += 10; |
397 y += 10; |
398 |
398 |
399 /* Max speed - Engine power */ |
399 /* Max speed - Engine power */ |
400 SetDParam(0, rvi->max_speed); |
400 SetDParam(0, rvi->max_speed * 10 / 16); |
401 SetDParam(1, rvi->power << multihead); |
401 SetDParam(1, rvi->power << multihead); |
402 DrawString(x,y, STR_PURCHASE_INFO_SPEED_POWER, 0); |
402 DrawString(x,y, STR_PURCHASE_INFO_SPEED_POWER, 0); |
403 y += 10; |
403 y += 10; |
404 |
404 |
405 /* Max tractive effort - not applicable if old acceleration or maglev */ |
405 /* Max tractive effort - not applicable if old acceleration or maglev */ |
430 { |
430 { |
431 bool refittable = (_engine_info[engine_number].refit_mask != 0); |
431 bool refittable = (_engine_info[engine_number].refit_mask != 0); |
432 |
432 |
433 /* Purchase cost - Max speed */ |
433 /* Purchase cost - Max speed */ |
434 SetDParam(0, rvi->base_cost * (_price.roadveh_base>>3)>>5); |
434 SetDParam(0, rvi->base_cost * (_price.roadveh_base>>3)>>5); |
435 SetDParam(1, rvi->max_speed / 2); |
435 SetDParam(1, rvi->max_speed * 10 / 32); |
436 DrawString(x, y, STR_PURCHASE_INFO_COST_SPEED, 0); |
436 DrawString(x, y, STR_PURCHASE_INFO_COST_SPEED, 0); |
437 y += 10; |
437 y += 10; |
438 |
438 |
439 /* Running cost */ |
439 /* Running cost */ |
440 SetDParam(0, rvi->running_cost * _price.roadveh_running >> 8); |
440 SetDParam(0, rvi->running_cost * _price.roadveh_running >> 8); |
454 /* Draw ship specific details */ |
454 /* Draw ship specific details */ |
455 static int DrawShipPurchaseInfo(int x, int y, EngineID engine_number, const ShipVehicleInfo *svi) |
455 static int DrawShipPurchaseInfo(int x, int y, EngineID engine_number, const ShipVehicleInfo *svi) |
456 { |
456 { |
457 /* Purchase cost - Max speed */ |
457 /* Purchase cost - Max speed */ |
458 SetDParam(0, svi->base_cost * (_price.ship_base>>3)>>5); |
458 SetDParam(0, svi->base_cost * (_price.ship_base>>3)>>5); |
459 SetDParam(1, svi->max_speed / 2); |
459 SetDParam(1, svi->max_speed * 10 / 32); |
460 DrawString(x,y, STR_PURCHASE_INFO_COST_SPEED, 0); |
460 DrawString(x,y, STR_PURCHASE_INFO_COST_SPEED, 0); |
461 y += 10; |
461 y += 10; |
462 |
462 |
463 /* Cargo type + capacity */ |
463 /* Cargo type + capacity */ |
464 SetDParam(0, svi->cargo_type); |
464 SetDParam(0, svi->cargo_type); |
480 { |
480 { |
481 CargoID cargo; |
481 CargoID cargo; |
482 |
482 |
483 /* Purchase cost - Max speed */ |
483 /* Purchase cost - Max speed */ |
484 SetDParam(0, avi->base_cost * (_price.aircraft_base>>3)>>5); |
484 SetDParam(0, avi->base_cost * (_price.aircraft_base>>3)>>5); |
485 SetDParam(1, avi->max_speed * 128 / 10); |
485 SetDParam(1, avi->max_speed * 8); |
486 DrawString(x, y, STR_PURCHASE_INFO_COST_SPEED, 0); |
486 DrawString(x, y, STR_PURCHASE_INFO_COST_SPEED, 0); |
487 y += 10; |
487 y += 10; |
488 |
488 |
489 /* Cargo capacity */ |
489 /* Cargo capacity */ |
490 cargo = FindFirstRefittableCargo(engine_number); |
490 cargo = FindFirstRefittableCargo(engine_number); |