Commit Graph

65 Commits

Author SHA1 Message Date
rubidium c03cb2c8db (svn r10704) -Codechange: provide an infrastructure to have resizable windows that are smaller than the default window size. 2007-07-27 12:49:04 +00:00
peter1138 306c21d6c9 (svn r10603) -Codechange: avoid direct access to _engine_info 2007-07-17 06:56:09 +00:00
rubidium 7aec26887c (svn r10567) -Add [FS#915]: a "group" with ungrouped vehicles. Patch by Matthias Wolf. 2007-07-14 23:10:27 +00:00
truelight a757ed52fd (svn r10552) -Fix [FS#1034, r10546]: opening Available Aircrafts segfaulted 2007-07-13 19:06:12 +00:00
truelight a84dcf7682 (svn r10546) -Fix [FS#1026]: you can now have both Available Train as Available Ship window open 2007-07-13 14:51:55 +00:00
peter1138 d69589b3c2 (svn r10324) -Codechange: reference engine names by index 2007-06-25 14:46:32 +00:00
truelight 6159f58948 (svn r10265) -Feature: allow double-clicking on certain places: build-vehicle and town-action 2007-06-22 10:57:53 +00:00
rubidium 9c0944aa09 (svn r10258) -Codechange: as we are now using int64 all over the place, it's better to use int64 variables in the string generating too instead of packing them into two int32s.
-Fix: some displays of money were wrong.
2007-06-21 17:25:17 +00:00
rubidium eb1472a82d (svn r10247) -Fix (r10210): *always* call SetDParamMoney when you want to place money in some string. 2007-06-21 14:54:51 +00:00
rubidium f806b46cc9 (svn r10246) -Fix (r10297): some forgotten money conversions and truncation issues. Thanks to benc for providing the patch. 2007-06-21 14:32:27 +00:00
bjarni 532391db12 (svn r10025) -Fix: [build windows] sorting planes for capacity didn't check mail capacity. Now mail capacity is used if passenger capacity is the same
The sort will still resort to EngineID if both mail and passenger capacities are the same
2007-06-02 15:47:38 +00:00
bjarni 81698422a2 (svn r10024) -Feature: [build windows] trains, road vehicles and ships can now be sorted by cargo capacity (planes already had this option) 2007-06-02 15:41:37 +00:00
maedhros ab8503f5a5 (svn r10008) -Codechange: Move a couple of functions related to articulated vehicles to a file of their own. 2007-06-01 11:41:02 +00:00
rubidium 0819f3a9a0 (svn r9917) -Codechange: prepare some more areas for more road types. 2007-05-25 08:13:01 +00:00
rubidium 7d4be11516 (svn r9874) -Feature: advanced vehicle lists a.k.a. group interface. Now you can make groups of vehicles and perform all kinds of tasks on that given group. Original code by nycom and graphics by skidd13. 2007-05-19 09:40:18 +00:00
rubidium ba24c34f85 (svn r9869) -Codechange: replace some bytes with VehicleType, i.e. more type strictness. 2007-05-18 17:31:41 +00:00
peter1138 1d5135830a (svn r9828) -Codechange: [NewGRF] Add support for changing cargo capacity with callback 36. This is set on construction for ships and roadvehicles, and whenever carriages are attached for trains. 2007-05-12 07:05:34 +00:00
peter1138 bc7d762196 (svn r9809) -Codechange: [NewGRF] Add callback 36 properties to purchase lists and add running cost changing for ships. 2007-05-07 16:38:21 +00:00
peter1138 4591fb5b0d (svn r9806) -Codechange: [NewGRF] Add callback 36 support for purchase cost, for all vehicle types. 2007-05-07 13:26:10 +00:00
peter1138 1052b0e8f1 (svn r9703) -Codechange: support callback 36 in vehicle purchase lists 2007-04-20 21:42:06 +00:00
rubidium 80c259f64f (svn r9672) -Cleanup: lots of coding style fixes around operands. 2007-04-18 22:10:36 +00:00
maedhros c25d539543 (svn r9476) -Codechange: Make build windows for all vehicle types the same width. 2007-03-26 12:28:44 +00:00
maedhros cdf74ca0c9 (svn r9475) -Codechange: Allow the purchase details widget to expand dynamically if there's still not enough room for the text. 2007-03-26 11:41:14 +00:00
maedhros d2bd12d52e (svn r9474) -Fix (r8378): Expand the details widget in the vehicle build windows again to make room for all the text. 2007-03-26 08:55:45 +00:00
rubidium ce919e8c71 (svn r9068) -Codechange: capitalize the VEH_Train etc. enums to match the coding style (and rest of the code). 2007-03-08 16:27:54 +00:00
bjarni f61f1962c5 (svn r9040) -Codechange: the build window and CmdBuildAircraft() now shares the code to figure out if an aircraft is buildable in the hangar in question
This should help ensuring that the build command and the list are consistent in what aircraft are buildable
2007-03-06 22:11:58 +00:00
celestar f621608f7d (svn r8973) -Feature/Codechange: Changed the internal unit for aircraft velocities to from 8mph to 1km/h (peter1138), also give aircraft realsitic velocities (so that 1km/h is 1km/h independent of vehicle type) (peter1138). Introduce a flag to reduce aircraft speed in holding patterns to some realistic velocity. Use this flag for the city airport for the time being and make use of the different entry points for this airport type. 2007-03-02 12:01:24 +00:00
belugas 6d199fcdb7 (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style. 2007-02-23 11:50:43 +00:00
peter1138 ef2daa5060 (svn r8826) -Codechange: Replace _cargoc's separate arrays with a regular struct array (with accessor) and implement new initialization method using cargo labels. 2007-02-20 22:09:21 +00:00
tron 41d526415c (svn r8822) -Fix
Variable scope, const
2007-02-20 06:39:09 +00:00
bjarni 853cc54ec6 (svn r8787) -Change r8771: allow fast aircraft in small airports
We should keep the list in sync with the build command as hacked clients can avoid a block in the GUI only
2007-02-17 18:38:35 +00:00
bjarni f731d7ffc4 (svn r8783) -Fix r8771: aircraft vehicle subtype and aircraft engine subtype aren't the same (even though they both tell if it's a plane or helicopter) 2007-02-17 16:07:45 +00:00
bjarni 222aebc5dd (svn r8771) -Fix r8343: build aircraft windows will no longer show aircraft that can't use the airport in question
Now it's even better than ever because unless the no jetcrash cheat is enabled, the small airports will not show fast aircraft
2007-02-17 12:45:15 +00:00
tron 87e03c7aa8 (svn r8755) -Fix
Abbreviate GetAirport(st->airport_type) to st->Airport()
2007-02-16 09:38:43 +00:00
bjarni 6460d5b441 (svn r8749) -Regression r8331: fixed signed/unsigned issue that could create too many lines in build vehicle windows and crash the game 2007-02-15 20:58:45 +00:00
tron 5231f5669d (svn r8747) -Fix
-Codechange: Make the encoding of accepted aircraft types of airports a bit more sensible and move the enum into struct AirportFTAClass
2007-02-15 20:16:33 +00:00
bjarni 8675b8ec7d (svn r8746) -Regression r8331: build train window could sort incorrectly by EngineID with certain newGRF sets 2007-02-15 17:51:39 +00:00
bjarni 037d636734 (svn r8621) -Codechange: assigned new numbers to the VEH_(type) enum so that VEH_Train is 0, VEH_Road is 1 and so on
This means that "v->type" can be used as array indexes instead of VehTypeToIndex() (or "v->type - VEH_Train/0x10 as the code still used in some places)
  Surprisingly this can be done without changing the savegame format
2007-02-07 19:10:19 +00:00
bjarni 80125fd934 (svn r8610) -Codechange/Feature: rewrote the list handling in the autoreplace window
-The user will notice the following changes:
      All vehicle types behaves in the same way
      Adding/removing an engine (new design and so on) can no longer result in the window selecting a new engine
      All valid replacements will be displayed since it looks at refitting options as well (this solves the missing ships with the newships GRF)
      Since you can't replace an engine into itself, the engine selected in the left list will no longer appear in the right list

   -The code changes:
      Instead of looping all engines all the time, each list generates a list like the build windows
        This ensures consistent list generation since only one function can loop all engines
      Unified code for all vehicle types
      It now use the lists to call the drawing code in the build vehicle window
      Works on selected EngineIDs instead of selected index in the list
2007-02-06 11:11:12 +00:00
rubidium c8882bd3d2 (svn r8511) -Codechange: make WindowClass an enumerated value. 2007-02-01 15:49:12 +00:00
peter1138 8933ffd9ac (svn r8464) -Revert (r4322): Change back to converting to mph in the GUI code, as 1 mph == 1.6 km/h is too far out for some people. 2007-01-30 21:10:04 +00:00
bjarni be19961f1e (svn r8460) -Fix (r8455): the build train window put locomotives and wagons in appeantly random order 2007-01-30 17:19:58 +00:00
belugas 0c45071bb0 (svn r8455) -Codechange: Give a more meaningful name (railveh_type)to member flags of RailVehInfo, as well as changing the code to reflect the fact that it was not a flag but rather a one value only variable. Doing so, some evaluations have been simplified.
-Codechange: Add and use RAILVEH_SINGLEHEAD when railveh_type is set to 0, which was implicit before.
-Cleanup: Remove some extraneous parenthesis.
2007-01-30 11:53:35 +00:00
bjarni 8c098db7a8 (svn r8390) -Codechange (r8384): Rewrote ResizeButtons()
Now it only works on first and last widget to resize
  It now works with offsets correctly (no longer assumes the left is 0)
  It's no longer needed to have a widget right of the ones you resize
  Can handle any number of widgets
2007-01-24 14:32:20 +00:00
tron 0996de79df (svn r8385) -Fix
-Regression (r8314): I only did half the necessary changes to move railtype from Engine to RailVehicleInfo. Now do the rest.
2007-01-24 07:14:09 +00:00
bjarni e2f72cbf1f (svn r8384) -Codechange: [GUI] instead of writing a resize button function for each window, a global ResizeButtons() is added 2007-01-24 02:36:55 +00:00
bjarni a73f67af40 (svn r8381) -Fix (r8377): [build vehicle window] cleaned up the train refitable detection. It had two variables doing the same thing, but not always set to the same (oops) 2007-01-23 21:24:26 +00:00
bjarni 9f31b897b6 (svn r8379) -Cleanup: [build vehicle window] removed overloading with DrawVehiclePurchaseInfo() and renamed them into type specific names 2007-01-23 20:55:04 +00:00
bjarni 9c6317a203 (svn r8378) -Fix (r8331): [build vehicle window] extended the widget with the details with one line since some newgrf trains needs it 2007-01-23 20:23:13 +00:00
bjarni 8d89ca48e1 (svn r8377) -Fix (r8331): [build vehicle window] train cargo capacity now only add "(refitable)" if the engine in question is refitable 2007-01-23 20:01:04 +00:00