The International Simutrans Forum

 

Author Topic: Extension request: export object guide search results to file  (Read 5124 times)

0 Members and 1 Guest are viewing this topic.

Offline vilvoh

  • One of the good guys
  • Administrator (Inactive)
  • *
  • Posts: 4504
  • I'm the constructor, the architect
    • Escala real
Extension request: export object guide search results to file
« on: February 18, 2009, 01:01:13 PM »
Related with this topic, I would like to make a request. Would be possible to export object's guide or vehicle's list search results to an external file (plain text, xls or ods, I don't mind the format).

This request is specially focused on getting vehicle's info in an easy way. The file would contain all avaliable attributes and if possible others that are not implicit (some examples from pak128 vehicle tables here)

Futhermore, I think it would be usefull for:
  • Pak maintainers: quick access to latest objects info for balancing paksets and objects and stablish a clear object's timeline.
  • Players: improve timeline experience providing more info about intro-retire dates. They could plan better strategies at long term.
  • Object developers: easy access to a lot of references, to create good and balanced objects.
  • The community: we may avoid those info requests

From my point of view it seems pretty easy to implement. You only have to redirect the database query to an external document instead of to screen. You output the file headers, gather the content and load it in the file...simple, isn't it?  ;)

What do you think? Would it be possible?
« Last Edit: February 18, 2009, 01:15:48 PM by vilvoh »

Offline Zeno

  • ENASSA Designer
  • Devotees (Inactive)
  • *
  • Posts: 1997
    • Zeno's Simutrans Creations
  • Languages: ES, EN, CAT
Re: Extension request: export object guide search results to file
« Reply #1 on: February 18, 2009, 03:06:25 PM »
Since some cleaning is needed after making C&P from the translator web, I'd also like some kind of external (i.e. csv) file format output for this.

Offline VS

  • Senior Plumber (Devotee)
  • Devotees (Inactive)
  • *
  • Posts: 4856
  • Vladimír Slávik
    • VS's Simutrans site
  • Languages: CS,EN
Re: Extension request: export object guide search results to file
« Reply #2 on: February 18, 2009, 03:57:02 PM »
With the framework I already have, such a tool would be relatively easy... but in Python :P

Offline vilvoh

  • One of the good guys
  • Administrator (Inactive)
  • *
  • Posts: 4504
  • I'm the constructor, the architect
    • Escala real
Re: Extension request: export object guide search results to file
« Reply #3 on: February 18, 2009, 04:07:34 PM »
Simutranslator is implemented with PHP, so I would say it's even easier than using Python... ::)

Offline VS

  • Senior Plumber (Devotee)
  • Devotees (Inactive)
  • *
  • Posts: 4856
  • Vladimír Slávik
    • VS's Simutrans site
  • Languages: CS,EN
Re: Extension request: export object guide search results to file
« Reply #4 on: February 18, 2009, 05:19:59 PM »
Yes. On the other hand, you can not run it on arbitrary set of data.

Offline Frank

  • Inactive/Retired
  • *
  • Posts: 1431
  • Languages: DE
Re: Extension request: export object guide search results to file
« Reply #5 on: February 25, 2009, 09:39:14 AM »
The main problem here could be that the data in the translator is not updated regularly. Imho pak maintainers do not upload every changed dat-file to the translator. This will happen mainly if the name of the object is changed (or a new object is uploaded).

The statistic is only implemented for vehicles. Any other request must be implemented. Only for vehicles a query on all objects with parameters is available yet.

Moreover, the vehicle statistic is unsorted if everything is displayed. Here, some sorting would make this more user-friendly.

Your request is realizable, preferably as CVS-export. However this relies essentially whether the data is up to date.

Thanks Dwachs for help translating

Offline vilvoh

  • One of the good guys
  • Administrator (Inactive)
  • *
  • Posts: 4504
  • I'm the constructor, the architect
    • Escala real
Re: Extension request: export object guide search results to file
« Reply #6 on: February 25, 2009, 10:53:46 AM »
The main problem here could be that the data in the translator is not updated regularly. Imho pak maintainers do not upload every changed dat-file to the translator. This will happen mainly if the name of the object is changed (or a new object is uploaded).

True, but keep data updated is a problem of pak mantainers not yours, you know. Indeed, is Translator supposed to host development dat files? imho, It wasn't implemented for that.

Your request is realizable, preferably as CVS-export. However this relies essentially whether the data is up to date.

The output format really doesn't matter whenever would be in a file, not only in screen.

Another thing. When you talk about statistics, you actually mean object attributes, don't you? Anyway, my request was only focused on vehicles mainly because this is the type of Simutrans object that interacts more with players, unlike city buildings or tourist attractions, so imho it's usual that pak maintainers and players want an place where they can get all info to improve their strategy, rebalance a set of vehicles or just draw a timeline diagram.

In any case, would be a good idea to leave the door open to new requests in a near future related with other types of objects, but this time vehicles are the priority.

« Last Edit: February 26, 2009, 11:02:03 AM by vilvoh »

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 10691
  • Languages: De,EN,JP
Re: Extension request: export object guide search results to file
« Reply #7 on: February 25, 2009, 11:24:55 AM »
No, translator is for translation. Frequent uploads should go the the SVN instead.

Offline Frank

  • Inactive/Retired
  • *
  • Posts: 1431
  • Languages: DE
Re: Extension request: export object guide search results to file
« Reply #8 on: February 25, 2009, 11:34:24 AM »
... Frequent uploads should go the the SVN instead.

or set doku

german wiki - paksets

for pak.german