Page 1 of 3

MogulAI

Posted: 14 Aug 2009 18:30
by Dezmond_snz
Today i introducing first public version of my AI named so humble "MogulAI". :)

This AI uses only trucks, trying to grow as fast as it can (sometimes it reaches RV's limit in 5 years).
Using industry-industry truck routes.
Save/load implemented.
Bank balance monitoring and managment implemented.
Routes, stations and vehicles count managment implemented.
Upgrading vehicles implemented.

Tested with FIRS, eGRVTS.
Here is example of network it built in 4.5 years:
Moguls Trans Corp ltd., 1954-05-03.png
Moguls Trans Corp ltd., 1954-05-03.png (63.99 KiB) Viewed 1808 times
Available at BaNaNaS also.
Waiting for your feedback.

edit for b5892:
Little update with fix of road vehicle's "memory effect".

edit for b5898:
- better behavior when coming close to RVs limit;
- use built-in replace functions;
- fixed bug of calculating starting count of vehicles for route;
- some minor tweaks.

edit for b5900:
- fixed load-game bug.
MogulAI-b5900.tar
(120 KiB) Downloaded 1430 times

Re: MogulAI

Posted: 14 Aug 2009 19:37
by Xander
I look forward to 7.3 :)

Welcome to the AI community. Hope you'll stick around :D

Re: MogulAI

Posted: 15 Aug 2009 10:47
by Dezmond_snz
Uploaded new build 5373 of AI that now should work with 0.7.2.
Made check of OTTD version and using NoAI features depending on revision.

Re: MogulAI

Posted: 15 Aug 2009 13:40
by Wold
You should think about the distance your trucks go to produce income, because 30-40 tiles results in 1-2k income. It's fine though, I like it for a first release.

Re: MogulAI

Posted: 15 Aug 2009 14:20
by Dezmond_snz
Wold wrote:You should think about the distance your trucks go to produce income, because 30-40 tiles results in 1-2k income. It's fine though, I like it for a first release.
Actualy, AI checks distance when looking for possible service and minimum distance is 70 tiles.

Build 5390 at first post.
Upgrade vehicles implemented. Now it'll check available engines for better ones.

Re: MogulAI

Posted: 15 Aug 2009 14:23
by Xander
Just gave Mogul (5373) a run on 0.7.2

Very slick - quick to find and build routes and populates them very well.

A couple of slight hiccups, it connected an unserviced steel mill to a factory and shipped grain to one factory and livestock to another from the same farm.

Can't wait to see how this AI progresses - should prove to be quite a challenge, even for veteran players :)

Re: MogulAI

Posted: 15 Aug 2009 14:28
by Wold
Dezmond_snz wrote:
Wold wrote:You should think about the distance your trucks go to produce income, because 30-40 tiles results in 1-2k income. It's fine though, I like it for a first release.
Actualy, AI checks distance when looking for possible service and minimum distance is 70 tiles.
Well there's something wrong with that check ;)

Re: MogulAI

Posted: 15 Aug 2009 15:09
by Dezmond_snz
Wold wrote:Well there's something wrong with that check ;)
Hmm... Interesting. I'll have a look.

Got it. There was another place with check, so 40 tiles was possible. :) Much thanks. In next build posted here it'll be fixed. (Hope post will be soon)
Xander wrote:Just gave Mogul (5373) a run on 0.7.2
Very slick - quick to find and build routes and populates them very well.

A couple of slight hiccups, it connected an unserviced steel mill to a factory and shipped grain to one factory and livestock to another from the same farm.

Can't wait to see how this AI progresses - should prove to be quite a challenge, even for veteran players :)
That's very strange. Provide screenshot next time, please.

Re: MogulAI

Posted: 15 Aug 2009 15:46
by Xander
Just gave it another run and I'm going to voice a slight concern I had last time but didn't mention:

Mogul is too good :P

In 3 years it had made not only cleared its loan but was sitting on over £1.5 million 8o. Seriously - that's frighteningly good.

Congrats - you've made a god level AI :D
:bow:

Re: MogulAI

Posted: 15 Aug 2009 16:10
by KIDS
Just to be sure --- it plays the same way as everyone else, no rating boosts or free terraforming like the original AI? If so, that sound beautiful! I'll be sure to test it. Speaking of which, I still expect it to eventually implode into itself as the general AI road congestion puts a brake on its road vehicles.

Re: MogulAI

Posted: 15 Aug 2009 16:15
by Xander
KIDS wrote:Just to be sure --- it plays the same way as everyone else, no rating boosts or free terraforming like the original AI? If so, that sound beautiful! I'll be sure to test it. Speaking of which, I still expect it to eventually implode into itself as the general AI road congestion puts a brake on its road vehicles.
None of then new AIs can do this. The only thing they can do which humans can't is build adjacent stations as new stations.

Re: MogulAI

Posted: 15 Aug 2009 16:20
by Yexo
Xander wrote:The only thing they can do which humans can't is build adjacent stations as new stations.
Human players can do that too, just press ctrl while building the station.

Re: MogulAI

Posted: 16 Aug 2009 07:39
by Lord Aro
i must congratulate you - GREAT AI :bow: :bow: :D

i found this bug:

EDIT: it deleted it but only after a year or two

Re: MogulAI

Posted: 16 Aug 2009 09:08
by Dezmond_snz
Thanks for so good opinions. Thanks very much. :oops:
Lord Aro wrote:...
i found this bug:
EDIT: it deleted it but only after a year or two
Well, it's not exactly a bug, i think, 'cuz there was good industry when he began build route. Such delay in removing this route conditioned by that AI was busy with some other work.
I'll add check in middle of building to detect such scenarios in future.
Thanks for report.

Now working on implementing routes from non-raw industries. Coming soon... ;)

Re: MogulAI

Posted: 19 Aug 2009 16:10
by dillonb3
Very impressive AI in the space of 9 years it has spawned over 500 road vehicles and currently leads the leaderboard. Don't know if anyone else has this problem but every 2nd time I load the game its AI crashes and stops building

Re: MogulAI

Posted: 14 Jul 2010 16:38
by Dezmond_snz
Dezmond_snz wrote:Now working on implementing routes from non-raw industries. Coming soon... ;)
Well, that my "soon" become a bit longer than soon. :mrgreen:

Finally i have reason to dig my topic up and present new version of MogulAI.
I made very many changes to strategy and microplaying of AI so now it must be more stable for longer game period.
Some of main changes i can remember:
- new totally custom pathfinder with reserved more traditional one;
- can handle any of industry-to-industry routes (i'm too lazy to implement town as destination or source :) );
- much better vehicles count managment for routes;
- extending stations for more vehicles;
- build statues in towns;
- a bit of terraforming for station and depot placing;
- "damn authority manager" - brings peaсe in intercourses with local authorities ;)
- queue detector and negative profit detector;
- something more... forgot already.

New version and same comments in first post.
Now i should learn how to upload it to bananas...
/me gone to grab some coffee ;)

Re: MogulAI

Posted: 14 Jul 2010 16:42
by Kogut
What a awesome bump! I must check how MagulAI is working!

Re: MogulAI

Posted: 15 Jul 2010 16:45
by Dezmond_snz
Ok, now MogulAI available at BaNaNaS.
I cannot find bugs in it anymore and that's scared me a bit.
Help me to find them, please. ;)

Re: MogulAI

Posted: 15 Jul 2010 20:30
by Kogut
OK (1.02)

Re: MogulAI

Posted: 15 Jul 2010 20:37
by Lord Aro
also, something of interest...