diff options
author | hackykid <hackykid@openttd.org> | 2005-06-06 00:19:24 +0000 |
---|---|---|
committer | hackykid <hackykid@openttd.org> | 2005-06-06 00:19:24 +0000 |
commit | 1018d3b78670be09d0d6ffbb2633b715c0203146 (patch) | |
tree | 953354be89e9773360834c65363da6c96c051d79 /train_gui.c | |
parent | 09aadafda1dfb08780fade5a52289a0742f84674 (diff) | |
download | openttd-1018d3b78670be09d0d6ffbb2633b715c0203146.tar.xz |
(svn r2414) - Feature: [newgrf] Implement powered wagons, and the callback that goes with it.
Diffstat (limited to 'train_gui.c')
-rw-r--r-- | train_gui.c | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/train_gui.c b/train_gui.c index b3a9f52fb..969ba253b 100644 --- a/train_gui.c +++ b/train_gui.c @@ -47,6 +47,14 @@ void DrawTrainEnginePurchaseInfo(int x, int y, EngineID engine_number) DrawString(x,y, STR_PURCHASE_INFO_RUNNINGCOST, 0); y += 10; + /* Powered wagons power - Powered wagons extra weight */ + if (rvi->pow_wag_power != 0) { + SetDParam(0, rvi->pow_wag_power); + SetDParam(1, rvi->pow_wag_weight); + DrawString(x,y, STR_PURCHASE_INFO_PWAGPOWER_PWAGWEIGHT, 0); + y += 10; + }; + /* Cargo type + capacity, or N/A */ SetDParam(0, STR_8838_N_A); SetDParam(2, STR_EMPTY); @@ -280,15 +288,15 @@ static const Widget _new_rail_vehicle_widgets[] = { { WWT_CAPTION, RESIZE_NONE, 14, 11, 227, 0, 13, STR_JUST_STRING, STR_018C_WINDOW_TITLE_DRAG_THIS}, { WWT_MATRIX, RESIZE_BOTTOM, 14, 0, 215, 14, 125, 0x801, STR_8843_TRAIN_VEHICLE_SELECTION}, { WWT_SCROLLBAR, RESIZE_BOTTOM, 14, 216, 227, 14, 125, 0x0, STR_0190_SCROLL_BAR_SCROLLS_LIST}, -{ WWT_PANEL, RESIZE_TB, 14, 0, 227, 126, 187, 0x0, STR_NULL}, -{ WWT_PUSHTXTBTN, RESIZE_TB, 14, 0, 107, 188, 199, STR_881F_BUILD_VEHICLE, STR_8844_BUILD_THE_HIGHLIGHTED_TRAIN}, -{ WWT_PUSHTXTBTN, RESIZE_TB, 14, 108, 215, 188, 199, STR_8820_RENAME, STR_8845_RENAME_TRAIN_VEHICLE_TYPE}, -{ WWT_RESIZEBOX, RESIZE_TB, 14, 216, 227, 188, 199, 0x0, STR_RESIZE_BUTTON}, +{ WWT_PANEL, RESIZE_TB, 14, 0, 227, 126, 197, 0x0, STR_NULL}, +{ WWT_PUSHTXTBTN, RESIZE_TB, 14, 0, 107, 198, 209, STR_881F_BUILD_VEHICLE, STR_8844_BUILD_THE_HIGHLIGHTED_TRAIN}, +{ WWT_PUSHTXTBTN, RESIZE_TB, 14, 108, 215, 198, 209, STR_8820_RENAME, STR_8845_RENAME_TRAIN_VEHICLE_TYPE}, +{ WWT_RESIZEBOX, RESIZE_TB, 14, 216, 227, 198, 209, 0x0, STR_RESIZE_BUTTON}, { WIDGETS_END}, }; static const WindowDesc _new_rail_vehicle_desc = { - -1, -1, 228, 200, + -1, -1, 228, 210, WC_BUILD_VEHICLE,0, WDF_STD_TOOLTIPS | WDF_STD_BTN | WDF_DEF_WIDGET | WDF_UNCLICK_BUTTONS | WDF_RESIZABLE, _new_rail_vehicle_widgets, |