AutoTTD - OpenTTD Updater - 0.2.0.13

OpenTTD is a fully open-sourced reimplementation of TTD, written in C++, boasting improved gameplay and many new features.

Moderator: OpenTTD Developers

Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

AutoTTD - OpenTTD Updater - 0.2.0.13

Post by Xaroth »

Right,

First of all I want to thank dihedral and Zuu for their support as I started on this project, it's what made me do it and what got this first release to be.. released.

What is AutoTTD

AutoTTD is, somewhat similar to OpenTTD AU, an Updater for OpenTTD to be used with numerous servers. It is built in C# allowing for a somewhat portability to unix (which somebody can pick up as I do not use unix).

AutoTTD takes a different approach, as it's main functionality is based upon the Master Server list, allowing you to browse that list and update your client accordingly. It will also let you know if there are any mismatches between NewGRFs so you can install those. Due to the touchy subject NewGRFs can get from time to time, AutoTTD will NOT installl those for you, however, it can (in the future) point you to places where you can look to get them.

What does it support

Currently, AutoTTD is aware of the following servers:
  • Releases (0.6.3, 0.7.0 etc)
  • Nightlies
  • IS2 Branch
  • More as I add them (doesn't require updating anymore)
NewGRFs

AutoTTD, in it's current way, can identify a large amount of GRFs by their GRF ID's and their hash, identical to how the client identifies them. This allows AutoTTD to identify which NewGRFs you have installed, and if they match what the server wants... this will allow you to see whether you are missing some NewGRFs or not.

In addition, AutoTTD queries the Content Server for the list of content currently in the database.. as said before, AutoTTD will NOT download any NewGRFs, but it CAN tell you if the NewGRFs the server uses are available for download for you.

Limitations

Seeing this is the first release, the app will come with some restrictions.
  • I've added -some- idiot-proofing of the app, it will generate errors in some cases, but far from everywhere.. this means that if you want to, you can crash it.
Usage:

Requirements:

.net 2.0, and an OS that can run it

First Run

AutoTTD will ask users for two directories if they are running on an unix-like system.. the first being the executable directory .. this allows them to use intermediate scripts (to set drivers etc). AutoTTD will use the executable directory for finding/executing the main 'openttd' executable

For Windows (and Unix), AutoTTD will ask for the OpenTTD directory.. this is the directory that holds the main executable for OpenTTD, and the data folders gm, lang and data (it will check for the existance of those directories, not for the executable)

Once the data loading has been completed you will see the main display of AutoTTD.. the interface should be mostly self-explaining .. but for those running Win64 (or for the unix people, the non-generic linux builds) you can change the build it should download from the Tools -> Options menu.

Features
  • More Info link, showing detailed (including company info) information for the selected server
  • Ability to join a company directly (rather than just spectating) from the More Info tabs.
  • Version graphs showing detailed information on versions, maps and map sizes for all shown servers (more of a gimmick, really, but it can tell you which versions are popular and which not)
  • Checksum verification of downloaded builds, for added security
  • Separate tab to check out currently downloaded builds and currently installed NewGRFs together with a list of available NewGRFs.. and the option to delete downloaded builds from that same tab.
  • Favourites system now in an easier to navigate tab rather than several windows.
  • Localisation support, but not yet active.. allowing for a (soon, at least) multi-lingual interface for ye non-english speaking lot
  • Dynamic build-support, allowing the system to add support for new builds without having to update the application
___________________________________________________________

And for those interested in the source: http://sourceforge.net/projects/autottd/
Attachments
AutoTTD.Browser.zip
AutoTTD 0.2.0.13
(202.76 KiB) Downloaded 1030 times
Last edited by Xaroth on 07 Jun 2009 10:42, edited 9 times in total.
Lead Manager of OpenDUNE
Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

Re: AutoTTD - OpenTTD Updater - 0.1.0.4

Post by Xaroth »

(reserved)
Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

Re: AutoTTD - OpenTTD Updater - 0.1.0.4

Post by Xaroth »

(reserved)
Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

Re: AutoTTD - OpenTTD Updater - 0.1.0.4

Post by Xaroth »

New release: 0.1.1.6

Binary in origional post changed to new version.

Added:

Favourite Lists work, both local and remote Favourite Lists are functional
Added interfaces for Favourite Lists, added some validation to those while I was at it.

Changed

Favourite Lists core : Changed the way it behaved to allow for defines for urls/grf lists so that 1 grf list can be applied to multiple favourite servers in the local/remote favourite list. (See dev topic for more info)


ToDo:
Add default GRF Link
Re-do version-check system.
Lead Manager of OpenDUNE
Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

Re: AutoTTD - OpenTTD Updater - 0.1.1.6

Post by Xaroth »

0.1.1.9 Released and uploaded.

Re-did the favourite list as I noticed some flaws in it's design, it should be better now, also added some more cosmetic features..

The To-Do list:

- Add Filtering for servers
- Add more columns for the listing and make visibilty of columns a user-choice (partially done, hiding/showing them is already in, but needs to be turned into configuration setting.)

- Re-Do patch/download system to allow for more different server builds (OTTDC IS, cargodist etc)
Lead Manager of OpenDUNE
Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

Re: AutoTTD - OpenTTD Updater - 0.1.1.11

Post by Xaroth »

Released and uploaded AutoTTD 0.1.1.11
This now includes an update feature for AutoTTD itself. I've tried to keep this as unintrusive without being hidden away.

I would like to hear from people who use AutoTTD what they think of it, what you want added/changed/improved.. this will help me a great deal in improving this application.
Lead Manager of OpenDUNE
User avatar
cmoiromain
Chief Executive
Chief Executive
Posts: 655
Joined: 15 Jan 2007 21:45
Location: FRANCE
Contact:

Re: AutoTTD - OpenTTD Updater - 0.1.1.11

Post by cmoiromain »

I have just had a go with the application, I must say it is really going to help! Every time I want to play MP games, nearly all servers have an incompatible version.

Only one little request: could you add support for the infrastructure sharing build?

EDIT: also a question: what is the use of having three separate buttons for update, update/play and play? IMO you could drop the middle one, or drop the other two and keep the middle one and make it update when the version is not the right one and play when it is.
I am little, ugly, and nasty. How do you do?
Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

Re: AutoTTD - OpenTTD Updater - 0.1.1.11

Post by Xaroth »

The third button is actually added per request, though i was thinking of moving this to an option.. double clicking a server in the list works just as good anyhow :)

I at first had a fixed list built in to support the different releases, but during testing (and nagging from Ammler :lol: ) i noticed that there's a lot of 'custom builds' .. so I'm still planning on how to replace this to a more 'flexible' sollution... by having a central-ish repository for those things (like it's now using the self-update notification thingie).
long things short, it's on my to-do list :)
Lead Manager of OpenDUNE
Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

Re: AutoTTD - OpenTTD Updater - 0.1.1.11

Post by Xaroth »

I've decided to do some re-designing the app's internals.... to explain a bit of the mess I made:

The library has classes for most functions, all of which are wrapped somehow in the ServerManager class.
The app does most of it's actions by calling functions on that single ServerManager class.. as such a hefty (read: bloated as fook) object is constantly passed around back and forth to the various other forms so they can do their job... it works, but I never found it pretty.

I'm currently re-writing it all (taking special care on the installation subsystems to allow for more different server types), and adding some basic unix support (currently only environment paths are 'done'), and support for having this app as a portable application (as most of it's data was stored on the user profile, which can now be turned off, saving all configurations/favourites/downloads to the application directories instead)

If people are interested in helping me test, let me know in a PM or just post here with your suggestions.
Lead Manager of OpenDUNE
User avatar
cmoiromain
Chief Executive
Chief Executive
Posts: 655
Joined: 15 Jan 2007 21:45
Location: FRANCE
Contact:

Re: AutoTTD - OpenTTD Updater - 0.1.1.11

Post by cmoiromain »

The program just crashed today: I tried downloading the latest nightly with it (using dihedral's server), and the program crashed at about half the progress bar. I tried with the second most recent on the list, on the [TO]Random21 server, the same thing happened. Unfortunately I am unable to send the crash log, since windows (XP, if that may help) refuses to let me copy the text and paste it. I am using v0.1.1.11.

Also a little suggestion: could you add a button to stop the refreshing? Once you have what you wanted, it would be good to be able to stop the list from continuing to update.
I am little, ugly, and nasty. How do you do?
Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

Re: AutoTTD - OpenTTD Updater - 0.1.1.11

Post by Xaroth »

I will add that to the to-do list, granted it doesn't mean I have to rewrite even more of the code. I am currently re-writing the backend of it, so hopefully the crash should be fixed with that.
Lead Manager of OpenDUNE
Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

Re: AutoTTD - OpenTTD Updater - 0.1.1.11

Post by Xaroth »

To give an update on this matter, as it's been a few days

Most of the new library is done, I've created a small console-based test app to get the master server list.. and have gone back to re-doing the Browser.

This is going to cause some changes:
  • New config system means it's incompatible (100%) with the old one, now the old one only had 2 config entries, so I doubt anybody would mind re-setting those....
  • New NewGRF loading system .. added a caching system that caches the NewGRF id, name and hash, so that the app does not need to re-read all that data from the files (as an example, on my machine it takes nearly 2,5 seconds to load 54 newgrfs, compared to 0.5s for the cached loading (most due to verification stuffs).. this is a 80% time reduction)
  • New implementation of Favourites loading, fully compatible with the old system
  • Implemented a managing class for some Environment-specific stuff (OpenTTD data locations, application data directory for AutoTTD etc) , which has Unix support
  • Minor changes to the server-query system, fixes an issue where some servers would not show up as responding from time to time .. Thanks for Brianetta to confirm that it was not what I believed it to be.
  • Implemented the Detailed Information packet for OpenTTD, allowing the new AutoTTD to get the company list from the server (means you don't have to be stuck joining as spectator all the time)
  • Implemented an Async/Sync intermediate class that allows me to easily make parts of the library both sync and async available (this mostly due to the fact that winforms and sync loading of data tends to get messy from time to time, and consoles and async the same.. now the same code gets executed, either sync or async, depending on how called)
  • Moved the version identifying system to be based on dynamic data, this data is downloaded together with the update information during startup (and cached in case of offline mode ofcourse), and allows me to add support for non-nightly/non-release builds without having to update the entire app
I'm now in a state where I can implement some suggestions/ideas I've been having, so by all means, dump them in here so I can read them... until then, a screenie of the new splash screen .. yes those numbers are the amount of servers/newgrfs loaded... but with the current speed you probably only have time to read that if you're on a slow PC.. as you can see by the time...
Image
Lead Manager of OpenDUNE
Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

Re: AutoTTD - OpenTTD Updater - 0.1.1.11

Post by Xaroth »

Yet another update with some features that I've added.
  • Sorting of clients/companies/spectators/mapsize now properly sorts the numeric values rather than doing string comparison.
  • Added response time to the server listing, allowing you to sort on the most responsive servers (or see when a server is lagging to boot)
  • Added a pie chart display, WITH save ability.. preview HERE, HERE and HERE. (note, big images!)
  • Added a "More Info" link to the server info pane, allowing you to open the server information in a separate tab, with company information (as soon as i get that displayed properly)
  • Added a System tab that shows
    • Downloaded datafiles (needs implementing still)
    • Installed NewGRFs and the NewGRF list from BaNaNaS
  • Favourites system got it's own separate tab page rather than a dodgy menu... allowing for easy adding/removing of favourites.
  • All of the above works through mono (tested on the mother of all daemons, Ubuntu ... (yay for vmware workstation) ) HERE a preview (it's old though, and 80% of the display hasn't been added before making it..)
If people are interested in testing, i usually hang out on irc so prod me there.. don't expect me to respond instantly as I do have a life (and job)... or post here.
Lead Manager of OpenDUNE
Wasila
Tycoon
Tycoon
Posts: 1498
Joined: 15 Mar 2008 07:02

Re: AutoTTD - OpenTTD Updater - 0.1.1.11

Post by Wasila »

This should be useful, thanks. But it's 'Update' not 'Updat' :P.

But under the sea of servers, I can't seem to find cargodist/trunk. Names?
Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

Re: AutoTTD - OpenTTD Updater - 0.1.1.11

Post by Xaroth »

Right, AutoTTD 0.2.something is almost ready to be released, I will be finishing off the update sequence so update notifications will work (again), but the rest of the functionality should be working.

I'll be on IRC if people are interested in helping me test (which would be REALLY appreciated...)
Lead Manager of OpenDUNE
Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

Re: AutoTTD - OpenTTD Updater - 0.2.0.13

Post by Xaroth »

AutoTTD 0.2.0.13 is released.

info at first post in the topic.
Lead Manager of OpenDUNE
User avatar
CommanderZ
Tycoon
Tycoon
Posts: 1872
Joined: 07 Apr 2008 18:29
Location: Czech Republic
Contact:

Re: AutoTTD - OpenTTD Updater - 0.2.0.13

Post by CommanderZ »

Unhandled exception

Code: Select all

Informace o vyvolání ladění JIT najdete na konci této zprávy,
nikoli v tomto dialogovém okně.

************** Text výjimky **************
System.NullReferenceException: Odkaz na objekt není nastaven na instanci objektu.
   v AutoTTD.Library.DownloadManager.IsInstalledVersion(String serverVersion)
   v AutoTTD.Library.DownloadManager.IsKnownVersion(String serverVersion)
   v AutoTTD.Library.DownloadManager.IsKnownVersion(GameServer server)
   v AutoTTD.Browser.frmMain.ShowSelectedServer()
   v AutoTTD.Browser.frmMain.lvServers_SelectedIndexChanged(Object sender, EventArgs e)
   v System.Windows.Forms.ListView.OnSelectedIndexChanged(EventArgs e)
   v System.Windows.Forms.ListView.WmReflectNotify(Message& m)
   v System.Windows.Forms.ListView.WndProc(Message& m)
   v System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   v System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   v System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


************** Načtená sestavení **************
mscorlib
    Verze sestavení: 2.0.0.0
    Verze Win32: 2.0.50727.3074 (QFE.050727-3000)
    Základ kódu: file:///C:/Windows/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
----------------------------------------
AutoTTD.Browser
    Verze sestavení: 0.2.0.13
    Verze Win32: 0.2.0.13
    Základ kódu: file:///C:/Users/Matej/Desktop/AutoTTD.Browser/AutoTTD.Browser.exe
----------------------------------------
System.Windows.Forms
    Verze sestavení: 2.0.0.0
    Verze Win32: 2.0.50727.3053 (netfxsp.050727-3000)
    Základ kódu: file:///C:/Windows/assembly/GAC_MSIL/System.Windows.Forms/2.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System
    Verze sestavení: 2.0.0.0
    Verze Win32: 2.0.50727.3053 (netfxsp.050727-3000)
    Základ kódu: file:///C:/Windows/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Drawing
    Verze sestavení: 2.0.0.0
    Verze Win32: 2.0.50727.3053 (netfxsp.050727-3000)
    Základ kódu: file:///C:/Windows/assembly/GAC_MSIL/System.Drawing/2.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
AutoTTD.Library
    Verze sestavení: 0.2.0.13
    Verze Win32: 0.2.0.13
    Základ kódu: file:///C:/Users/Matej/Desktop/AutoTTD.Browser/AutoTTD.Library.DLL
----------------------------------------
System.Xml
    Verze sestavení: 2.0.0.0
    Verze Win32: 2.0.50727.3074 (QFE.050727-3000)
    Základ kódu: file:///C:/Windows/assembly/GAC_MSIL/System.Xml/2.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
System.Configuration
    Verze sestavení: 2.0.0.0
    Verze Win32: 2.0.50727.3053 (netfxsp.050727-3000)
    Základ kódu: file:///C:/Windows/assembly/GAC_MSIL/System.Configuration/2.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
mscorlib.resources
    Verze sestavení: 2.0.0.0
    Verze Win32: 2.0.50727.3074 (QFE.050727-3000)
    Základ kódu: file:///C:/Windows/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
----------------------------------------
System.Windows.Forms.resources
    Verze sestavení: 2.0.0.0
    Verze Win32: 2.0.50727.3053 (netfxsp.050727-3000)
    Základ kódu: file:///C:/Windows/assembly/GAC_MSIL/System.Windows.Forms.resources/2.0.0.0_cs_b77a5c561934e089/System.Windows.Forms.resources.dll
----------------------------------------

************** Ladění JIT **************
Aby bylo povoleno ladění JIT, musí konfigurační soubor
pro tuto aplikaci nebo počítač (machine.config) mít
v oddílu system.windows.forms nastavenou hodnotu njitDebugging.
Aplikace rovněž musí být kompilována s povoleným
laděním.

Příklad:

<configuration>
    <system.windows.forms jitDebugging="true" />
</configuration>

Je-li ladění JIT povoleno, budou všechny neošetřené výjimky
odeslány ladicímu programu JIT, který je registrován v počítači,
a nebudou zpracovány tímto dialogovým oknem.
Happened IIRC after i clicked on a server in the server list.

Also, when I clicked Update and play with 0.7.0 server (while in win64 mode), it downloaded a package, launched it, but OTTD threw an arrer, that revisions don't match.
Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

Re: AutoTTD - OpenTTD Updater - 0.2.0.13

Post by Xaroth »

hmm, odd, can you tell me which server caused this? i'll have a look to see if i can reproduce it.
Lead Manager of OpenDUNE
User avatar
CommanderZ
Tycoon
Tycoon
Posts: 1872
Joined: 07 Apr 2008 18:29
Location: Czech Republic
Contact:

Re: AutoTTD - OpenTTD Updater - 0.2.0.13

Post by CommanderZ »

Xaroth wrote:hmm, odd, can you tell me which server caused this? i'll have a look to see if i can reproduce it.
I think it was diheral's server, but I'm not entirely sure. And next time it didn't cause this error.
Xaroth
Engineer
Engineer
Posts: 103
Joined: 01 May 2006 09:09

Re: AutoTTD - OpenTTD Updater - 0.2.0.13

Post by Xaroth »

Ah, i -did- notice that dihedral's server was runnign an unknown version, probably due to a warning/error during compilation.. I'll still have a look at it though.
Lead Manager of OpenDUNE
Post Reply

Return to “General OpenTTD”

Who is online

Users browsing this forum: No registered users and 8 guests