Trans AI .:19.07.23 :.

Discuss the new AI features ("NoAI") introduced into OpenTTD 0.7, allowing you to implement custom AIs, and the new Game Scripts available in OpenTTD 1.2 and higher.

Moderator: OpenTTD Developers

Post Reply
bokkie
Transport Coordinator
Transport Coordinator
Posts: 326
Joined: 19 Jan 2007 19:26

Re: Trans AI .: 09-08-29 :.

Post by bokkie » 31 Aug 2009 15:42

Because I was having problems with AI's on my custom build, I ran a few AI's on trunk (for 40 years) to see where they originated from. The following screenshost show issues I saw with your AI:
1a - doesn't repay loan even though it has more than enough money [EDIT: my bad, it does! :D]
1b - doesn't sell off trains losing money even though the 'vehicle seller task' was completed
2a - weird pathfinding in the bottom of the screen towards the station
2b - also curious pathfinding, next to that an unconnected station

You probably already know about them but on the other hand it might help you developing your AI :) Next to that, your AI didn't build that many routes. Maybe the map is hard with hilly terrain and high sea level. [EDIT: money shortage might be a problem too]. I'm not sure which settings I set for your AI.
Attachments
Unnamed, 1992-03-26.png
screenshot 1
(230.29 KiB) Downloaded 53 times
Unnamed, 1992-03-26#1.png
screenshot 2
(351.8 KiB) Downloaded 55 times

User avatar
fanioz
Transport Coordinator
Transport Coordinator
Posts: 320
Joined: 19 Dec 2008 05:03
Location: Indonesia
Contact:

Re: Trans AI .: 09-08-29 :.

Post by fanioz » 02 Sep 2009 01:29

Hei, bokkie :D,
1. Yes it does pay loan, but quickly take it again :D
1b. Yes, it doesn't handle that problem.
2a.b. Yes pathfinding is still another issue to taken care.
Thanks bokkie, this would really help .:D
Correct me If I am wrong - PM me if my English was bad :D

**[OpenTTD AI]** Image
***[NewGRF] *** Image

User avatar
fanioz
Transport Coordinator
Transport Coordinator
Posts: 320
Joined: 19 Dec 2008 05:03
Location: Indonesia
Contact:

Re: Trans AI .: 09-08-29 :.

Post by fanioz » 11 Sep 2009 16:14

Any body know why Trans failed on loading a saved game in r17496.
It said there is no 'rawget' index. I hope I didn't miss any announcement. Last known working was r17297
Correct me If I am wrong - PM me if my English was bad :D

**[OpenTTD AI]** Image
***[NewGRF] *** Image

Yexo
Tycoon
Tycoon
Posts: 3653
Joined: 20 Dec 2007 12:49

Re: Trans AI .: 09-08-29 :.

Post by Yexo » 11 Sep 2009 16:40

fanioz wrote:Any body know why Trans failed on loading a saved game in r17496.
It said there is no 'rawget' index. I hope I didn't miss any announcement. Last known working was r17297
Provide a direct link to the version used, a link to the savegame and I'll have a look.

User avatar
fanioz
Transport Coordinator
Transport Coordinator
Posts: 320
Joined: 19 Dec 2008 05:03
Location: Indonesia
Contact:

Re: Trans AI .: 09-08-29 :.

Post by fanioz » 11 Sep 2009 18:54

Here is saved game, and screenshoot of 3 AI's. Trans, NoCab, Mogul.
Looking at type of :
-data => Closure
-version => Instance

so there was no 'rawget' and 'rawin'

edit: to be continued due to attachement limit ....
Attachments
save_game_made _by17496.sav
(43.73 KiB) Downloaded 103 times
Trans_090829_NoCab_328_Mogul_5390.PNG
(57.29 KiB) Downloaded 23 times
Last edited by fanioz on 11 Sep 2009 18:59, edited 1 time in total.
Correct me If I am wrong - PM me if my English was bad :D

**[OpenTTD AI]** Image
***[NewGRF] *** Image

User avatar
fanioz
Transport Coordinator
Transport Coordinator
Posts: 320
Joined: 19 Dec 2008 05:03
Location: Indonesia
Contact:

Re: Trans AI .: 09-08-29 :.

Post by fanioz » 11 Sep 2009 18:57

.... (see also above)
Here is simple script that does well.
Attachments
Simplified_AI.png
Simplified_AI.png (13.23 KiB) Viewed 5024 times
simplified.tar
(10 KiB) Downloaded 113 times
Correct me If I am wrong - PM me if my English was bad :D

**[OpenTTD AI]** Image
***[NewGRF] *** Image

User avatar
Menno
Tycoon
Tycoon
Posts: 1190
Joined: 05 Feb 2005 14:35
Location: Netherlands, Utrecht

Re: Trans AI .: 09-08-29 :.

Post by Menno » 09 Oct 2009 20:52

I tried a game with Trans 90829 among other AI's.
It did nothing at all, except building one depot and a truck loading bay at a power plant. According to the debug window it apparently needs moer money. It was 1977, and it could have loaned 200,000 GBP. Yet it payed it all back and does many runs of (only) trying to plan or build things.
See attached save game and screenshots.
OpenTTD 0.7.3
NewGRFs: OpenGFX, better vehicles names, Av8 1.501

(I will post comparable posts in the other AI's topics)
Attachments
AI game.sav
(658.84 KiB) Downloaded 105 times
Almighty Transport, 15th Aug 1989.png
also some error message
(171.58 KiB) Downloaded 1 time
Almighty Transport, 20th Aug 1989.png
it went on like this for 10 years straight
(170.34 KiB) Downloaded 1 time
*hmz*

Vemarkis
Engineer
Engineer
Posts: 83
Joined: 06 Jan 2009 18:27
Location: Helsinki, Finland

Re: Trans AI .: 09-08-29 :.

Post by Vemarkis » 10 Oct 2009 11:43

The AI also has problem with custom vehicle sets, it will often fail to build any trains with UKRS, or NARS. It still builds routes, it just never buys trains for them. Often it goes haywire after the first route fails to get a train, it builds a new route right next to it between the same industries(sometimes getting up to 6 different routes between the same industries). With £500,000 loan, at 1921 I'd imagine it should be able to buy at least 1 train. I noticed it does buy a locomotive in the depot, then sells it immediately afterwards, and then moves onto the next route(which often is right alongside the one done beforehand). The AI works fine with the default trains, however.

i.e it reports it found locomotive: 7 and wagon 12 when transporting GRVL with the UKRS + UKRS Addon + PBI + PBI Brick Chain. It worked fine with the same cargo with the default trainset + default wagons carry new cargoes grf.
Attachments
Unnamed, 13-02-1920.png
(366.5 KiB) Downloaded 1 time
Unnamed, 05-07-1920.png
(356.43 KiB) Downloaded 1 time

User avatar
fanioz
Transport Coordinator
Transport Coordinator
Posts: 320
Joined: 19 Dec 2008 05:03
Location: Indonesia
Contact:

Re: Trans AI .: 09-08-29 :.

Post by fanioz » 14 Oct 2009 01:17

@Menno : the road service doesn't work since last few changes in Trans AI road pathfinder.
@ Vemarkis: I think, I should try with your setup (of newgrf). And I'll try a better engine selection.

Thanks, for both of your report. I hope I'll have time to fix this. :D
Correct me If I am wrong - PM me if my English was bad :D

**[OpenTTD AI]** Image
***[NewGRF] *** Image

User avatar
fanioz
Transport Coordinator
Transport Coordinator
Posts: 320
Joined: 19 Dec 2008 05:03
Location: Indonesia
Contact:

Re: Trans AI .: 09-08-29 :.

Post by fanioz » 30 Oct 2009 14:32

Just try to update my AI :D
:: it should run safely without load/save
:: Servicing by Road Vehicles only : (Bus, Truck and Tram)

Just give it try, thanks :D

note:
-not yet uploaded to bananas
-download available in the 2nd post or http://www.tt-forums.net/download/file.php?id=119279
Correct me If I am wrong - PM me if my English was bad :D

**[OpenTTD AI]** Image
***[NewGRF] *** Image

Joriz
Engineer
Engineer
Posts: 2
Joined: 03 Nov 2009 20:36

Re: Trans AI .: 09-08-29 :. (also available 091030)

Post by Joriz » 03 Nov 2009 20:41

Don't know if this error is already reported.

The following keeps happening after opening a save game (where the AI worked in the game years before good) after about one minute.

OS: Windows 7 RC 64 bit
Game: OpenTTD 7.3 64 bit
Attachments
openttd-ai-crash.jpg
(249.94 KiB) Downloaded 1 time

User avatar
fanioz
Transport Coordinator
Transport Coordinator
Posts: 320
Joined: 19 Dec 2008 05:03
Location: Indonesia
Contact:

Re: Trans AI .: 09-08-29 :. (also available 091030)

Post by fanioz » 04 Nov 2009 02:05

Joriz wrote:Don't know if this error is already reported.

The following keeps happening after opening a save game (where the AI worked in the game years before good) after about one minute.

OS: Windows 7 RC 64 bit
Game: OpenTTD 7.3 64 bit
Thanks for testing, that is indeed a new report. Probably I would need your savegame, to see actually what happened with RoadVehicle71 and its Group.
:D
Correct me If I am wrong - PM me if my English was bad :D

**[OpenTTD AI]** Image
***[NewGRF] *** Image

Joriz
Engineer
Engineer
Posts: 2
Joined: 03 Nov 2009 20:36

Re: Trans AI .: 09-08-29 :. (also available 091030)

Post by Joriz » 04 Nov 2009 19:30

The error keeps displaying after 1 minute of playing.

In the attachment you can find my savegame.
Attachments
Sarnville Transport, 27th Jun 1990.sav
(1.09 MiB) Downloaded 115 times

Brumi
President
President
Posts: 904
Joined: 18 Jul 2009 17:54

Re: Trans AI .: 09-08-29 :. (also available 091030)

Post by Brumi » 07 Nov 2009 19:38

Hi Fanioz,
I've had a little AI testing time now, and I'm glad to see that you've come up with a new release. There are quite a lot of changes :)
Here are my remarks (using 0.7.3):
  • It's good that it connects stations, but maybe it shouldn't connect pickup stations with dropoff stations.
  • In my tests, TransAI 091030 didn't build a train at all.
  • It seems that the setting "allow pax cargo" doesn't work. The AI still builds buses.
  • I think the AI has some preference towards the cheaper cargoes, mostly passengers, mail, livestock and grain.
Anyway, it's good to see that you're still working on your AI. :)

User avatar
fanioz
Transport Coordinator
Transport Coordinator
Posts: 320
Joined: 19 Dec 2008 05:03
Location: Indonesia
Contact:

Re: Trans AI .: 09-08-29 :. (also available 091030)

Post by fanioz » 09 Nov 2009 10:28

Joriz wrote:The error keeps displaying after 1 minute of playing.

In the attachment you can find my savegame.
Thanks for your save game. I've fixed it today :D
Brumi wrote:Hi Fanioz,
Hi, Brumi. :)
Brumi wrote:It's good that it connects stations, but maybe it shouldn't connect pickup stations with dropoff stations.
Good idea, have not implemented it yet.
Brumi wrote:In my tests, TransAI 091030 didn't build a train at all.
Yup, I didn't figure out yet, how I could introduce the train again. (Hey, I've said that this version would only build Road vehicle and Trams :D )
Brumi wrote:It seems that the setting "allow pax cargo" doesn't work. The AI still builds buses.
That is just a 'preview' setting. :mrgreen: Oh, no I'm forget to activate it (even in 091109 :oops: )
Brumi wrote:I think the AI has some preference towards the cheaper cargoes, mostly passengers, mail, livestock and grain.
Well, I would say, it doesn't sort cargoes by price only. It choose a Drop off (sort by number of cargo accepted), check which cargo would be accepted , then find a pair. This would make AI to choose Town / Factory over a Power Plant in Temperate climate, etc.
Brumi wrote:Anyway, it's good to see that you're still working on your AI.
:D Thanks, I still have time to code, but have a limited internet access :roll:


So...
I've uploaded TransAI 091109 on 2nd post. In this forum Only , no Bananas, no Train. :lol:
Click here to download directly
Correct me If I am wrong - PM me if my English was bad :D

**[OpenTTD AI]** Image
***[NewGRF] *** Image

Kogut
Tycoon
Tycoon
Posts: 2493
Joined: 26 Aug 2009 06:33
Location: Poland

Re: Trans AI .: 09-08-29 :. (also available 091109)

Post by Kogut » 20 Feb 2010 11:25

savegame added, after crash
Attachments
Przechwytywanie.PNG
Przechwytywanie2.PNG
(23.46 KiB) Downloaded 1 time
trans crash.sav
(38.46 KiB) Downloaded 96 times
Correct me If I am wrong - PM me if my English is bad
AIAI - AI for OpenTTD

User avatar
fanioz
Transport Coordinator
Transport Coordinator
Posts: 320
Joined: 19 Dec 2008 05:03
Location: Indonesia
Contact:

Re: Trans AI .: 09-08-29 :. (also available 091109)

Post by fanioz » 26 Feb 2010 08:23

Thanks for reporting, I've to waiting for "the right time" to release the next version. :D
Correct me If I am wrong - PM me if my English was bad :D

**[OpenTTD AI]** Image
***[NewGRF] *** Image

User avatar
fanioz
Transport Coordinator
Transport Coordinator
Posts: 320
Joined: 19 Dec 2008 05:03
Location: Indonesia
Contact:

Re: Trans AI .:10.02.27 :. (Rail-less)

Post by fanioz » 27 Feb 2010 11:55

Updated :
#the first page
#Download Area
#NoAI page if you're using svn.

and of course Trans-AI was available today, 100227 :D
-beware of the library needed to run. 8)
-bugs reports are always free :lol:
Correct me If I am wrong - PM me if my English was bad :D

**[OpenTTD AI]** Image
***[NewGRF] *** Image

User avatar
Zuu
OpenTTD Developer
OpenTTD Developer
Posts: 4553
Joined: 09 Jun 2003 18:21
Location: /home/sweden

Re: Trans AI .:10.02.27 :. (Rail-less)

Post by Zuu » 27 Feb 2010 13:16

changelog wrote:*100228
Removed : Rail service
Added : Aircraft (passenger only) service
Added : Ship service
Added : Tram service
I tired your last version which did well except that it did only build airports. Reading your change log I hoped that it should also build ships and tram service? I loaded the generic tram set.

It might have been that the AI though that air was more profitable, so I turned it off in your AI Settings, but then the AI didn't do anything. I saw that your water connector found two towns close to water which were connected to the same body of water but it never built anything.

Is this intended?

I used a mountainous/rough map but with height distribution = medium so there were still plenty of rather flat areas. (sea-level was set to high)
My OpenTTD contributions (AIs, Game Scripts, patches, OpenTTD Auto Updater, and some sprites)
Junctioneer (a traffic intersection simulator)

User avatar
planetmaker
OpenTTD Developer
OpenTTD Developer
Posts: 9311
Joined: 07 Nov 2007 22:44
Location: Sol d

Re: Trans AI .:10.02.27 :. (Rail-less)

Post by planetmaker » 27 Feb 2010 13:29

Why not offer it for download via Bananas, too? Btw: Personally I think there's hardly ever the 'right time' (as in perfect) for most things.

Post Reply

Return to “OpenTTD AIs and Game Scripts”

Who is online

Users browsing this forum: No registered users and 1 guest