mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-07-19 18:35:48 +01:00
(svn r2969) -Newgrf: Show a wagon's speed limit in purchase list.
This commit is contained in:
parent
1195076373
commit
02c2de2a67
@ -2766,6 +2766,7 @@ STR_TINY_BLACK :{BLACK}{TINYFON
|
|||||||
|
|
||||||
STR_PURCHASE_INFO_COST_WEIGHT :{BLACK}Cost: {GOLD}{CURRENCY}{BLACK} Weight: {GOLD}{COMMA}t
|
STR_PURCHASE_INFO_COST_WEIGHT :{BLACK}Cost: {GOLD}{CURRENCY}{BLACK} Weight: {GOLD}{COMMA}t
|
||||||
STR_PURCHASE_INFO_SPEED_POWER :{BLACK}Speed: {GOLD}{VELOCITY}{BLACK} Power: {GOLD}{COMMA}hp
|
STR_PURCHASE_INFO_SPEED_POWER :{BLACK}Speed: {GOLD}{VELOCITY}{BLACK} Power: {GOLD}{COMMA}hp
|
||||||
|
STR_PURCHASE_INFO_SPEED :{BLACK}Speed: {GOLD}{VELOCITY}
|
||||||
STR_PURCHASE_INFO_RUNNINGCOST :{BLACK}Running Cost: {GOLD}{CURRENCY}/yr
|
STR_PURCHASE_INFO_RUNNINGCOST :{BLACK}Running Cost: {GOLD}{CURRENCY}/yr
|
||||||
STR_PURCHASE_INFO_CAPACITY :{BLACK}Capacity: {GOLD}{STRING1} {STRING}
|
STR_PURCHASE_INFO_CAPACITY :{BLACK}Capacity: {GOLD}{STRING1} {STRING}
|
||||||
STR_PURCHASE_INFO_DESIGNED_LIFE :{BLACK}Designed: {GOLD}{NUM}{BLACK} Life: {GOLD}{COMMA} years
|
STR_PURCHASE_INFO_DESIGNED_LIFE :{BLACK}Designed: {GOLD}{NUM}{BLACK} Life: {GOLD}{COMMA} years
|
||||||
|
@ -109,6 +109,13 @@ void DrawTrainWagonPurchaseInfo(int x, int y, EngineID engine_number)
|
|||||||
SetDParam(2, refittable ? STR_9842_REFITTABLE : STR_EMPTY);
|
SetDParam(2, refittable ? STR_9842_REFITTABLE : STR_EMPTY);
|
||||||
DrawString(x, y, STR_PURCHASE_INFO_CAPACITY, 0);
|
DrawString(x, y, STR_PURCHASE_INFO_CAPACITY, 0);
|
||||||
y += 10;
|
y += 10;
|
||||||
|
|
||||||
|
/* Wagon speed limit, displayed if above zero */
|
||||||
|
if (rvi->max_speed > 0) {
|
||||||
|
SetDParam(0, rvi->max_speed * 10 >> 4);
|
||||||
|
DrawString(x,y, STR_PURCHASE_INFO_SPEED, 0);
|
||||||
|
y += 10;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void CcBuildWagon(bool success, TileIndex tile, uint32 p1, uint32 p2)
|
void CcBuildWagon(bool success, TileIndex tile, uint32 p1, uint32 p2)
|
||||||
|
Loading…
Reference in New Issue
Block a user