OpenTTD

Login!
Register as a new userLost password?

for Project:

FS#342 — Vehicle-statistics for stations

Attached to Project— OpenTTD
Opened by Jens Kuttler (AsterixMG) - Sunday, 10 September 2006, 09:48PM
Last edited by Patric Stout (TrueLight) - Saturday, 18 August 2007, 01:13PM
Patch
User Interface
Waiting for user
Victor Fischer
All
Medium
Normal
Devel (specify rev)
Undecided
Undecided
0%
This patch allows the user to view statistics on how many vehicles have visited a station.

It adds a button at the bottom of the station-view-window for opening the statistics-window.
The statistics-window shows either statistics for this and last month or average, minimum, maximum statistics and the number of counted months. This can be toggled by a button in the window.

Further statistics might be added in later patches, as well as statistics for waypoints or if needed depots.
This patch should be ready to be included in trunk.
  station_stats_9.diff
This task depends upon

This task blocks these from closing
Comment by Jens Kuttler (AsterixMG) - Monday, 11 September 2006, 10:52PM

Attached is a version that includes saving/loading of the statistics, starting with savegame-version 34.
Note that the savegame-version is *not* increased to 34 by this patch, but it will start save/load whenever the savegame-version is set to 34 or above.

Other than that there is only a small change to how the GUI is drawn.

Waiting for some comments now (especially from the developers). Thanks in advance.

  station_stats_10.diff
Comment by Jens Kuttler (AsterixMG) - Thursday, 14 September 2006, 07:22PM

New version incorporating changes suggested by Darkvater.

There's one thing I would liek comments on:
STSVehicleType currently uses the same order as the finances-window, not the same order as the vehicle-types in the rest of the code.
Should I leave it as is?
Or change the order in the enum making them display in a different order than in the finances-window?
Or change enum an make a conversion of the order for the displaying?

  station_stats_11.diff
Comment by Patric Stout (TrueLight) - Saturday, 18 August 2007, 01:13PM

This idea for a patch is in fact rather nice. Too bad it is a bit outdated right now. Would it be possible for you to update it, so we can review it properly?


Comment by Jens Kuttler (AsterixMG) - Monday, 20 August 2007, 09:10AM

I will look at it after new computer arrived and is properly set up, as my current one doesn't work too stable anymore... (should come this or next week)