Transport Tycoon Forums

The place to talk about Transport Tycoon
It is currently Sun Dec 16, 2018 12:17 am

All times are UTC




Post new topic  Reply to topic  [ 43 posts ]  Go to page 1 2 3 Next
Author Message
 Post subject: Chopper - Helicopter AI
PostPosted: Tue Sep 08, 2009 7:42 pm 
Offline
Engineer
Engineer
User avatar

Joined: Tue Aug 22, 2006 4:19 pm
Posts: 14
Location: Garden of England
Image

Introduction
Chopper is an AI for OTTD which uses only helicopters. Chopper can transport all types of cargo, so use GRFs such as AV8 to allow him to do so. Chopper has many options enabling you to configure how he plays. You can alter how fast he builds, whether he will attempt subsidies, and even whether he is allowed to build at a town you've built at. Chopper can play well competitively with helicopters alone, so don't underestimate your rival!

AI Parameters
Image
(1) Parameter all AIs have;
(2) Minimum town size;
(3) You can alter how Chopper is feeling, which in turn affects his speed;
(4) Whether Chopper should choose station locations randomly or cleverly;
(5) Chopper likes subsidies, but with this you can stop him stealing them all;
(6) Change the min distance between town stations;
(7) Change the max distance between town stations;
(8) Change the min distance between industry stations;
(9) Change the max distance between industry stations;
(10) Limit how many loading stations Chopper can have per industry;
(11) When this is enabled, the max distance between stations will be increased depending on the plane speed factor;
(12) Stop Chopper from being competitive with you;
(13) Stop Chopper clogging up towns with airports;
(14) Stop Chopper from building intercity routes;
(15) Show debug signs...unless you are me you will almost certainly want this off;
(15) Show more stuff in the log.

Notable features
-Works with grfs, use AV8 to allow Chopper to do more cargos;
-Transports mail and passengers;
-Attempts subsidies (r17425 and above);
-Visits oilrigs to transport those poor passengers who no one bothers to help;
-Supports saving/loading;
-Autoreplaces vehicles;
-Transports cargo if you use an appropriate grf;
-Loves plane speed factor 1/1. :wink:

Known bugs
none!

To play with Chopper
Download from BaNaNaS, or from the bottom of this topic.

Lastly...(Important information)
If you enable Chopper before the things he requires are available, he will repay his loan and sit and wait until he can start (usually 1976). During this time he will just display "Zzzz...". Chopper requires the helidepot and heliport to be available, and for there to be at least one helicopter available.

Thankyou to all the Devs who made the NoAI framework and WrightAI, and please have fun testing and playing with Chopper! :D


Attachments:
Chopper.7.tar [102 KiB]
Downloaded 1075 times

_________________
My website | Chopper - Helicopter AI | OTTD Scenario - Bottleneck


Last edited by Marbs on Mon Aug 22, 2011 7:06 pm, edited 10 times in total.
Top
   
PostPosted: Tue Sep 08, 2009 7:48 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Mon Aug 03, 2009 2:29 pm
Posts: 1418
Location: Manchester
Did I mention I love helicopters, this ai is a must-have for me, planes are boring, this would work well with AV8, I shall test this now I hope to see more releases of this ai. :mrgreen:

_________________
==Flickr==


Top
   
PostPosted: Tue Sep 08, 2009 7:52 pm 
Offline
Engineer
Engineer
User avatar

Joined: Tue Aug 22, 2006 4:19 pm
Posts: 14
Location: Garden of England
This is just the right AI for you if you like helicopters then! I have tested Chopper with AV8, and he performed well, though took a little while to get a decent profit due to the higher start up costs. There will almost certainly be more releases in the next few days or weeks, since I have quite a bit of spare time. :D

_________________
My website | Chopper - Helicopter AI | OTTD Scenario - Bottleneck


Top
   
PostPosted: Tue Sep 08, 2009 7:54 pm 
Offline
Tycoon
Tycoon

Joined: Thu Apr 02, 2009 10:43 pm
Posts: 3008
Location: Massachusetts, USA
Could you upload it to Bananas?

Also, one suggestion for settings. Could you make a setting so that it doesn't build in towns that the player has built in?


Top
   
PostPosted: Tue Sep 08, 2009 8:17 pm 
Offline
Engineer
Engineer
User avatar

Joined: Tue Aug 22, 2006 4:19 pm
Posts: 14
Location: Garden of England
Okay, Chopper is now available from BaNaNaS, so you don't even need to bother download from this topic. :)

That's a good suggestion, I'll add it to my todo list!

_________________
My website | Chopper - Helicopter AI | OTTD Scenario - Bottleneck


Top
   
PostPosted: Tue Sep 08, 2009 8:25 pm 
Offline
Transport Coordinator
Transport Coordinator
User avatar

Joined: Wed Dec 07, 2005 7:22 pm
Posts: 272
Welcome to the AI developer club!

_________________
Denver & Rio Grande Railroad AI


Top
   
PostPosted: Tue Sep 08, 2009 9:30 pm 
Offline
OpenTTD Developer
OpenTTD Developer
User avatar

Joined: Mon Jun 09, 2003 6:21 pm
Posts: 4538
Location: /home/sweden
Looks like you found yourself a nice specialty for your AI. :-) Which could be good to have some boundaries set and make it stable within those boundaries instead of aiming to do everything.

_________________
My OpenTTD contributions (AIs, Game Scripts, patches, OpenTTD Auto Updater, and some sprites)
Junctioneer (a traffic intersection simulator)


Top
   
PostPosted: Tue Sep 08, 2009 9:38 pm 
Offline
Engineer
Engineer
User avatar

Joined: Sun Mar 22, 2009 7:24 am
Posts: 81
Location: Haarlem, The Netherlands
I chuckled. Lovely idea for a new AI, I'll give it a try soon.


Top
   
PostPosted: Wed Sep 09, 2009 12:21 am 
Offline
Transport Coordinator
Transport Coordinator
User avatar

Joined: Sun Jul 13, 2008 12:57 am
Posts: 313
Neat idea :D
Good luck with the (very satisfying) time sink of AI development ;)

_________________
Building Powargrid: a turn based strategy game


Top
   
PostPosted: Wed Sep 09, 2009 11:10 pm 
Offline
Engineer
Engineer
User avatar

Joined: Tue Aug 22, 2006 4:19 pm
Posts: 14
Location: Garden of England
Thankyou for the replies everyone! I got a lot of progress done today:
-Fixed bug #00001;
-Added feature request "make a setting so that it doesn't build in towns that the player has built in";
-Vastly improved Chopper's log;
-Added more parameters (attitude, intercity, debug);
-And best of all, Chopper now uses oilrigs! (see picture below)

Image

I have also just noticied that the AV8 set has helicopters that refit to any cargo, so tomorrow I will try and get some industrial helicopter links working, and we'll have helicopters transporting oil and terrified livestock in no time! :lol:

Unfortunately at the moment Chopper does not do so well with AV8, due to the massive start up costs involved, but I'm going to run a test now to see if he can keep a profit and expand over time, since it would be really great to have him working well with AV8.

One thing that I should improve soon is how Chopper chooses what to build. Currently it's just by chance, 2/3rd chance of building town to town route, 1/3rd chance of building town to oilrig. It works for now, but is not the most economic method. :P

_________________
My website | Chopper - Helicopter AI | OTTD Scenario - Bottleneck


Top
   
PostPosted: Thu Sep 10, 2009 7:47 am 
Offline
Tycoon
Tycoon
User avatar

Joined: Mon Apr 07, 2008 6:29 pm
Posts: 1872
Location: Czech Republic
Quote:
One thing that I should improve soon is how Chopper chooses what to build. Currently it's just by chance, 2/3rd chance of building town to town route, 1/3rd chance of building town to oilrig. It works for now, but is not the most economic method.


It should be fairly simple to calculate an expected income/loss for a heli route


Top
   
PostPosted: Thu Sep 10, 2009 10:49 am 
Offline
Tycoon
Tycoon

Joined: Thu Apr 02, 2009 10:43 pm
Posts: 3008
Location: Massachusetts, USA
Haha, I like the AI Paramaters, "I'd be a fool not to". Anyway, does chopper AI stop at heliports for cargo? E.g. I produce goods at good factory, Chopper picks them up by heli.


Top
   
PostPosted: Thu Sep 10, 2009 3:50 pm 
Offline
Engineer
Engineer
User avatar

Joined: Tue Aug 22, 2006 4:19 pm
Posts: 14
Location: Garden of England
Chopper doesn't do goods yet, but I'm working on that for the next version. Though I will add a setting to turn it off, in case you don't like him leeching off of your industries. :P

Also, in time Chopper will also do other freight cargos, but of course you will have to have a suitable GRF enabled (probably AV8), since the default helicopters can only be refitted to passengers, mail, valuables and goods.

I'm glad you like the parameters, I tried to make Chopper seem a bit more life like through them, using phrases rather than numbers. :D

[edit]
I've just redone Chopper's airport placement, so he now picks the best spot possible, and actually modifies the land in order to build the airport, whereas before he just tried to find an empty flat space :P

I decided to test this, and ran a 512*512 tropical game for him to play on his own for a while. Unfortunately, just after 2 years Chopper had used up all 200 of the aircraft limit, as can be seen in the graph below where the line suddenly flattens.

The reasons Chopper performed this well are:
-Initial town size multiplier was set to 10, number of towns set to High;
-Plane speed factor was set to 1/1;
-Town controlled noise levels was on (meaning Chopper can build many more stations per town, I counted 17 airports in one town);
-There was no competition from other players;
-Chopper's attitude setting was set to "Caffeine high";
-Chopper's concern setting was set to "Economics" (this is a new feature I'm adding, the other setting is "Aesthetics").

Now I know though that in a best case scenario, Chopper can do quite well :)


Attachments:
File comment: Chopper reaches the limit of 200 aircraft in just over 2 years.
Chopper aircraft limit.PNG
Chopper aircraft limit.PNG [ 17.81 KiB | Viewed 14005 times ]
File comment: An example showing that Chopper now knows how to modify the land, and so has a much better chance of placing a helistation right next to the town center. You can see the brown dirt from where Chopper excavated to make space!
Chopper better station placement.PNG
Chopper better station placement.PNG [ 206.71 KiB | Viewed 13969 times ]

_________________
My website | Chopper - Helicopter AI | OTTD Scenario - Bottleneck


Last edited by Marbs on Fri Sep 11, 2009 12:20 am, edited 3 times in total.
Top
   
PostPosted: Thu Sep 10, 2009 9:20 pm 
Offline
OpenTTD Developer
OpenTTD Developer

Joined: Wed Dec 20, 2006 1:31 pm
Posts: 978
Location: Aschaffenburg
Marbs wrote:
I have also just noticied that the AV8 set has helicopters that refit to any cargo, so tomorrow I will try and get some industrial helicopter links working, and we'll have helicopters transporting oil and terrified livestock in no time! :lol:
Oh, I expected Chopper AI to prefer industries producing wood or lumber :p

_________________
⢇⡸⢸⠢⡇⡇⢎⡁⢎⡱⢸⡱⢸⣭⠀⢸⢜⢸⢸⣀⢸⣀⢸⣭⢸⡱⠀⢰⠭⡆⣫⠰⣉⢸⢸⠀⢰⠭⡆⡯⡆⢹⠁⠀⢐⠰⡁


Top
   
PostPosted: Fri Sep 11, 2009 7:25 pm 
Offline
OpenTTD Developer
OpenTTD Developer
User avatar

Joined: Mon Jun 09, 2003 6:21 pm
Posts: 4538
Location: /home/sweden
I just want to thank you for this nice AI. I just ran it along with PAXLink to add some more to my otherwise solo test games. Actually I was interested how they compares. Currently PAXLink has the tendency to go bankrupt from time to time.

After 20 years (starting 1975 with default vehicles) Chopper AI had a steady profit of about 100 thousands a year. PAXLink wobbles up and down around 360 thousands a year. Considering that Chopper AI is limited to only helicopters I think that is a really good result. Just checked and Chopper AI has 36 helicopters and 53 stations. PAXLink has 53 aircrafts, 67 buses and 43 stations.

_________________
My OpenTTD contributions (AIs, Game Scripts, patches, OpenTTD Auto Updater, and some sprites)
Junctioneer (a traffic intersection simulator)


Top
   
PostPosted: Mon Sep 14, 2009 10:33 am 
Offline
OpenTTD Developer
OpenTTD Developer

Joined: Thu Sep 11, 2008 7:32 am
Posts: 1034
Location: Spain
I love the idea of this AI. Thanks to FISH I'm currently playing games with a lot of islands, so once that Chopper can restart after loading a game I will give it a try :D

_________________
Spanish translation of OpenTTD
Extended heightmaps

Have fun, don't quarrel too much and add as many advanced settings as you can.


Top
   
PostPosted: Tue Sep 15, 2009 9:31 pm 
Offline
Engineer
Engineer
User avatar

Joined: Tue Aug 22, 2006 4:19 pm
Posts: 14
Location: Garden of England
Image
Version 7 of Chopper is out! You can download it from BaNaNaS, or the bottom of my first post,

If you are interested, here is the list of the main improvements I can think of in version 7:
-Chopper now transports all cargo types, not just passengers and mail! (use AV8 or some other helicopter grf);
-Saving/Loading now works! Well, nothing need be saved or loaded any more, I changed it so that it is all read off the map (which is even better, because if for whatever reason Chopper crashes, you can save and then reload straight away and it will continue to work);
-Old vehicles are replaced;
-Land is flattened for airports instead of simply trying to find an empty space;
-Stations are reused. Instead of building a new station every time there is a new route, Chopper first checks for existing stations and will use them instead, unless they are too crowded of course;
-If a station is built, but no helicopter can be afforded, the station isn't deleted. It is left in case it can be reused later. If it is left unused for a long time, it is eventually deleted;
-Goods are transported to towns, this is the only new cargo that will work without a GRF, since all the default helicopters support goods.

There shouldn't be any bugs. Chopper works better on 0.7.3 or the nightly, because that has extra functions, however Chopper will work on 0.7.2 as well, he will just perform ever so slightly worse.

Please test and have fun :D

_________________
My website | Chopper - Helicopter AI | OTTD Scenario - Bottleneck


Top
   
PostPosted: Wed Sep 16, 2009 9:10 am 
Offline
OpenTTD Developer
OpenTTD Developer

Joined: Thu Sep 11, 2008 7:32 am
Posts: 1034
Location: Spain
Marbs wrote:
Version 7 of Chopper is out!


Great :D

Marbs wrote:
Please test and have fun :D


Will do ;)

_________________
Spanish translation of OpenTTD
Extended heightmaps

Have fun, don't quarrel too much and add as many advanced settings as you can.


Top
   
PostPosted: Thu Sep 17, 2009 6:21 pm 
Offline
Engineer
Engineer

Joined: Wed Jan 21, 2009 12:24 pm
Posts: 72
Marbs wrote:

Lastly...(Important information)
If you enable Chopper before the things he requires are available, he will repay his loan and sit and wait until he can start (usually 1976). During this time he will just display "Zzzz...". Chopper requires the helidepot and heliport to be available, and for there to be at least one helicopter available.


Looks great so far, but is the above set in stone or could there possibly be the option of using small airports and airships until better aircraft and heliports/depots are available?


Top
   
PostPosted: Sat Sep 19, 2009 5:15 pm 
Offline
Engineer
Engineer
User avatar

Joined: Tue Aug 22, 2006 4:19 pm
Posts: 14
Location: Garden of England
Image
Swansea Stu wrote:
Marbs wrote:

Lastly...(Important information)
If you enable Chopper before the things he requires are available, he will repay his loan and sit and wait until he can start (usually 1976). During this time he will just display "Zzzz...". Chopper requires the helidepot and heliport to be available, and for there to be at least one helicopter available.


Looks great so far, but is the above set in stone or could there possibly be the option of using small airports and airships until better aircraft and heliports/depots are available?


That's a good idea, I'm not sure why I didn't think of it earlier! Attached here is a new version of Chopper that will use small airports and large (city) airports if no heli type airports are available. This means that Chopper can start back as far as 1920 (using AV8, that is when the airships are introduced). The downside is that these airships cost a lot, and are very slow so do not make much profit, even on plane speed factor 1/1.

I have not released this on BaNaNaS yet, because it is not 100% complete. I want to make it so that when the helidepot and helistation become available, Chopper destroys his small/large airports and replaces them. However I am not entirely sure how I will go about this yet.

To destroy an airport there have to be no helicopters at it, so Chopper would either have to send the helicopters to another depot to get them out the way, or sell the helicopters. It would be useful to have some kind of "close airport" option to make helicopters simply circle above until the airport is reopened. The airport could then be demolished and replaced, however there is a small chance this could fail (someone else building in the way really fast or building an airport nearby that raises the noise level). If it failed Chopper might have lost a valuable spot.

I could always just let the small and large airports stay for the rest of the game, however they make a lot of noise compared to the heli airports, and so will stop Chopper making as much money. They also take up a lot of space, which might be annoying for other players.

Anyway, thank you all for trying out Chopper and keep the suggestions coming! :D


Attachments:
File comment: Chopper uses small and large (city) airports. Not released on BaNaNaS yet.
Chopper.8.tar [105.5 KiB]
Downloaded 234 times

_________________
My website | Chopper - Helicopter AI | OTTD Scenario - Bottleneck
Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 43 posts ]  Go to page 1 2 3 Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000-2018 phpBB Limited

Copyright © Owen Rudge/The Transport Tycoon Forums 2001-2018.
Hosted by Zernebok Hosting.