[AI] AAAHogEx

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

AAAHogEx
Engineer
Engineer
Posts: 117
Joined: 30 Jan 2022 15:37
Location: Japan

Re: [AI] AAAHogEx

Post by AAAHogEx »

Kjell291 wrote: 20 Jul 2022 08:30
I noticed the AI does not use Chips stations, could this be added as a feature in the future?
That has been on my mind for some time, and I have done some research, but unfortunately there does not seem to be a way to use Chips stations from AI. ;( ;( ;(
But as you may know, Industrial Stations Renewal improves the appearance of stations.

And I just wanted to say that this is by far the best AI I have ever tried!
Thanks for the nice feedback!
Kjell291
Engineer
Engineer
Posts: 3
Joined: 18 Jul 2022 12:48

Re: [AI] AAAHogEx

Post by Kjell291 »

I got a new error with firs, everything from 2cc, fish and av8.
OpenTTD.png
(149.04 KiB) Not downloaded yet
AAAHogEx
Engineer
Engineer
Posts: 117
Joined: 30 Jan 2022 15:37
Location: Japan

Re: [AI] AAAHogEx

Post by AAAHogEx »

Kjell291 wrote: 21 Jul 2022 07:45 I got a new error with firs, everything from 2cc, fish and av8.OpenTTD.png
Thanks for the report!

I've released it as version 24

・FIX: crash when using 2cc
・FIX: estimation in maintenance costs of single-track rails
・Other minor bug fixes
beloncfy
Engineer
Engineer
Posts: 3
Joined: 11 Apr 2009 03:30

Re: [AI] AAAHogEx

Post by beloncfy »

I hate your AI , it is way too smart and hard to defeat :x . Usually I can defeat others AI easily until your AI show up, good job.

By the way, sometime this AI may not survive in the beginning when starting with 200k of cash (from loan), especially when the "Infrastructure Maintenance Fee" is enabled.

Maybe your AI can start with the road and short distance train at the beginning instead of aircraft before reaching 600k to avoid this?
AAAHogEx
Engineer
Engineer
Posts: 117
Joined: 30 Jan 2022 15:37
Location: Japan

Re: [AI] AAAHogEx

Post by AAAHogEx »

beloncfy wrote: 12 Sep 2022 07:26 I hate your AI , it is way too smart and hard to defeat :x . Usually I can defeat others AI easily until your AI show up, good job.

By the way, sometime this AI may not survive in the beginning when starting with 200k of cash (from loan), especially when the "Infrastructure Maintenance Fee" is enabled.

Maybe your AI can start with the road and short distance train at the beginning instead of aircraft before reaching 600k to avoid this?
I created this AI because I was playing with other AIs were not enough for me, so when you say so, it is exactly what I expected! :wink:
I imagine that the scenarios and goal scripts will make it a play style that even advanced players will enjoy. :idea:

Thanks for the report on "Infrastructure Maintenance Fee".
I just tried it and this AI suddenly went bankrupt building an international airport when I started it after 1990. (I had no problem with earlier starting years).
I will try to fix this, but did this condition apply to your case as well?
beloncfy
Engineer
Engineer
Posts: 3
Joined: 11 Apr 2009 03:30

Re: [AI] AAAHogEx

Post by beloncfy »

AAAHogEx wrote: 12 Sep 2022 12:09
I created this AI because I was playing with other AIs were not enough for me, so when you say so, it is exactly what I expected! :wink:
I imagine that the scenarios and goal scripts will make it a play style that even advanced players will enjoy. :idea:

Thanks for the report on "Infrastructure Maintenance Fee".
I just tried it and this AI suddenly went bankrupt building an international airport when I started it after 1990. (I had no problem with earlier starting years).
I will try to fix this, but did this condition apply to your case as well?
Your intention is understandable, million thanks for creating this very competitive AI and make this game more challenging and much more fun to play.

Precisely, I always prefer to start the game after 1990 with the "infrastructure maintenance fee" enabled, that's why the occurrent of bankruptcy is quite often.
JustMoreMemes
Engineer
Engineer
Posts: 42
Joined: 08 Dec 2018 18:09

Re: [AI] AAAHogEx

Post by JustMoreMemes »

This is one incredible AI, amazing work creating it! I've never had another AI fight so competitively or use so many advanced features, it builds complex stations and networks and uses different road and rail types as well as custom stations, I'm very impressed. It can beat me unless I'm building on my A-game. The only issue I have with it is that in the early game (early 1800's for me) when the only road transport is horse and carts from EGRVTS it will spam so many of them that the entire route jams up and it stops transporting, causing it to make a new route and spam it full of horses until it jams up and it makes a new route and so on, on my save it build 5 routes snaking around a town to ship water and completely boxed the place in. It's probably just an issue with the time I start though, I think maybe it should have a system to try and make trains or canals if road transport isn't working after a couple of attempts.
orielis
Engineer
Engineer
Posts: 7
Joined: 02 Oct 2022 06:41

Re: [AI] AAAHogEx

Post by orielis »

I'm working on a UK map and scenario that starts in 1850. The game started a new company in 1866 with AAAHogEx as the AI.

It decided to start with ships, which was probably a good idea, however it bought 6 of the largest ships in the game so far, and set them up to deliver mail. The ships have a capacity of 400 bags, and four of them are sitting at Dundee and Edinburgh, trying to get a full load. I think one of them is about 1/3 full after the better part of a year so it looks like it'll take a couple years to fill a single ship -- not good when two or three are waiting at that port. There has been exactly one delivery over the year your company has been in business -- that netted about $1k, plus there is a ship currently steaming with 80 bags to, I think Edinburgh.

It's not going to matter, as you can see looking at the financials. I just got a warning that the company is in trouble -- bankruptcy can't be far away unless it sells a couple of those ships.

Reading through this thread, it appears that the AI has done well in other situations. This has been a pretty tough scenario to make money in. Most of the towns started pretty small and building roads and rail is quite expensive. Ships are working well, now that there are some industries on the map, but your AI spent nearly all its money for ships and it looks like some tram stuff.


Rolfand Livery Ltd., 1867-05-03.png
(328.68 KiB) Not downloaded yet
AAAHogEx
Engineer
Engineer
Posts: 117
Joined: 30 Jan 2022 15:37
Location: Japan

Re: [AI] AAAHogEx

Post by AAAHogEx »

JustMoreMemes wrote: 14 Sep 2022 19:40 It's probably just an issue with the time I start though, I think maybe it should have a system to try and make trains or canals if road transport isn't working after a couple of attempts.
Sorry for the late reply and thanks for the report! The 1800's is more difficult because of the inefficiency of the vehicle. EGRVTS does not include trains or canals in 1800's, but do you use other NewGRFs?
AAAHogEx
Engineer
Engineer
Posts: 117
Joined: 30 Jan 2022 15:37
Location: Japan

Re: [AI] AAAHogEx

Post by AAAHogEx »

orielis wrote: 08 Oct 2022 00:47 I'm working on a UK map and scenario that starts in 1850. The game started a new company in 1866 with AAAHogEx as the AI.
Is this the scenario you played?

viewtopic.php?f=60&t=77124

Seemed like quite a challenging scenario! I've tried running the AI a bit, but it's certainly not working. I'll try to adjust it, but it may take a while since I'm busy at work for a while. :bow:
orielis
Engineer
Engineer
Posts: 7
Joined: 02 Oct 2022 06:41

Re: [AI] AAAHogEx

Post by orielis »

Yeah, that's the scenario. It's been a challenge getting a company up and making money -- as it turns out I think that ships are probably the best bet, now that there are a decent number of industries on the map (it starts out with just a coal mine and power plant).

Laying track or building roads are incredibly expensive in this scenario, especially considering the small, slow vehicles and I've had several AI companies flame out just in the first 20 years. Just for example a single track train line from London to Reading, which is very short would cost around $150k or so, not counting the train itself. So I built up a road network, carriage by carriage.
Qbomb
Engineer
Engineer
Posts: 1
Joined: 17 Oct 2022 23:19

Re: [AI] AAAHogEx

Post by Qbomb »

Hey, I know this might be a bit random and not super important but I was wondering if it would be possible to remove the numbers in front of the names.

This is honestly just a personal thing and is something that I was trying to do to make it look a bit more authentic? as the numbers seem to just rub something in my head the wrong way.

Other than that this AI has been super fun to play with/against and I really enjoy it in my games!

(I am new(ish) to Openttd especially AI/Newgrf so I am unsure if there is already a method to do this)
AAAHogEx
Engineer
Engineer
Posts: 117
Joined: 30 Jan 2022 15:37
Location: Japan

Re: [AI] AAAHogEx

Post by AAAHogEx »

Qbomb wrote: 17 Oct 2022 23:23 Hey, I know this might be a bit random and not super important but I was wondering if it would be possible to remove the numbers in front of the names.

This is honestly just a personal thing and is something that I was trying to do to make it look a bit more authentic? as the numbers seem to just rub something in my head the wrong way.

Other than that this AI has been super fun to play with/against and I really enjoy it in my games!

(I am new(ish) to Openttd especially AI/Newgrf so I am unsure if there is already a method to do this)
Thanks for your input!
There is currently no way to remove the number. I will consider the option to remove it in a future plan.
JustMoreMemes
Engineer
Engineer
Posts: 42
Joined: 08 Dec 2018 18:09

Re: [AI] AAAHogEx

Post by JustMoreMemes »

AAAHogEx wrote: 08 Oct 2022 02:21
JustMoreMemes wrote: 14 Sep 2022 19:40 It's probably just an issue with the time I start though, I think maybe it should have a system to try and make trains or canals if road transport isn't working after a couple of attempts.
Sorry for the late reply and thanks for the report! The 1800's is more difficult because of the inefficiency of the vehicle. EGRVTS does not include trains or canals in 1800's, but do you use other NewGRFs?
I had Sailing Ships, Sal's Canal Boats, WSF & BC Ferry Sets, plus SQUID for boats and Early Rail, NARS 2.03 plus the 600mm Narrow Gauge set for trains, but I had the same issue with UKRS2 and NARS 2.5, it would build rails and canals sometimes but if it decided to use road vehicles it would just spam them and then build new routes. The only change I really think it needs is for it to decide to use a canal or train line if a two road routes aren't moving enough cargo instead of adding another 5 road routes.
AAAHogEx
Engineer
Engineer
Posts: 117
Joined: 30 Jan 2022 15:37
Location: Japan

Re: [AI] AAAHogEx

Post by AAAHogEx »

JustMoreMemes wrote: 25 Oct 2022 02:01 I had Sailing Ships, Sal's Canal Boats, WSF & BC Ferry Sets, plus SQUID for boats and Early Rail, NARS 2.03 plus the 600mm Narrow Gauge set for trains, but I had the same issue with UKRS2 and NARS 2.5, it would build rails and canals sometimes but if it decided to use road vehicles it would just spam them and then build new routes. The only change I really think it needs is for it to decide to use a canal or train line if a two road routes aren't moving enough cargo instead of adding another 5 road routes.
Thank you for your report. There is indeed a problem with more roads over time. This is because as the AI approaches Max Vechicles, it periodically withdraws from less profitable routes and looks for new routes to increase the profit margin per vehicle, but in doing so, it does not remove existing roads that are no longer needed. This algorithm is designed to prevent congestion from reducing the profitability of routes in competition with other AIs. At this time, only certain modes of transportation can be prevented from being overbuilt by turning on "Infrastructure Maintenance" in the game settings. The reason why railroads and canals are not used may be because their profitability estimates were lower than those of roads. I will look into those newgrfs when I have time.
AAAHogEx
Engineer
Engineer
Posts: 117
Joined: 30 Jan 2022 15:37
Location: Japan

Re: [AI] AAAHogEx

Post by AAAHogEx »

orielis wrote: 08 Oct 2022 17:26 Yeah, that's the scenario. It's been a challenge getting a company up and making money -- as it turns out I think that ships are probably the best bet, now that there are a decent number of industries on the map (it starts out with just a coal mine and power plant).

Laying track or building roads are incredibly expensive in this scenario, especially considering the small, slow vehicles and I've had several AI companies flame out just in the first 20 years. Just for example a single track train line from London to Reading, which is very short would cost around $150k or so, not counting the train itself. So I built up a road network, carriage by carriage.
I found the cause - AAAHogEx is looking at Passengers last month for each town when planning, but sometimes this value seems to go wrong. So it seems that it is not an AI problem, but either one of the NewGRFs or the openttd itself.

Image
Attachments
スクリーンショット 2022-11-30 153630.png
(2.38 MiB) Not downloaded yet
xarick
Transport Coordinator
Transport Coordinator
Posts: 341
Joined: 26 Feb 2015 00:52

Re: [AI] AAAHogEx

Post by xarick »

Found a crash
Attachments
Unnamed, 1975-06-06.png
(284.23 KiB) Not downloaded yet
Formerly known as Samu
AAAHogEx
Engineer
Engineer
Posts: 117
Joined: 30 Jan 2022 15:37
Location: Japan

Re: [AI] AAAHogEx

Post by AAAHogEx »

xarick wrote: 22 Feb 2023 12:28 Found a crash
Thank you for your report. I am currently experiencing a possible crash with the upgrade of the rail line. I have also identified other issues with freight lines not completing pathfinding and are currently working on an update. I plan to release it shortly.
RanFodar
Engineer
Engineer
Posts: 2
Joined: 15 Jul 2022 13:32

Re: [AI] AAAHogEx

Post by RanFodar »

Hey,

Pathfinding seems to be a problem when it comes to rail. When there's an uncomplete route, the tracks would be left abandoned and the station tiles deleted. It's not a rare occurence for me to stumble on this problem, it's much more than the other transportation modes. I hope this is fixed for the foreseeable future.
AAAHogEx
Engineer
Engineer
Posts: 117
Joined: 30 Jan 2022 15:37
Location: Japan

Re: [AI] AAAHogEx

Post by AAAHogEx »

RanFodar wrote: 25 Feb 2023 10:01 Hey,

Pathfinding seems to be a problem when it comes to rail. When there's an uncomplete route, the tracks would be left abandoned and the station tiles deleted. It's not a rare occurence for me to stumble on this problem, it's much more than the other transportation modes. I hope this is fixed for the foreseeable future.
Thank you for your feedback. I am working on improving the pathfinding area of the tracks, so it will be much better in the next release. However, there will continue to be an issue with broken tracks remaining when saving and loading while building a line.
Post Reply

Return to “OpenTTD AIs and Game Scripts”

Who is online

Users browsing this forum: No registered users and 22 guests