SuperSimpleAI v25 (Old Stable), v41 (Stable) and v47 (Testing)

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

User avatar
3iff
Tycoon
Tycoon
Posts: 1093
Joined: 21 Oct 2005 09:26
Location: Birmingham, England

Re: SuperSimpleAI v25 (Old Stable), v41 (Stable) and v45 (Testing)

Post by 3iff »

Absolutely my pleasure...

I really like the way V45 uses double road stations. Somehow I never quite thought of doing that (in that way).
It also makes upgrading the stations to through stations a lot easier.
Wanabe
Engineer
Engineer
Posts: 1
Joined: 07 Jul 2023 10:34

Re: SuperSimpleAI v25 (Old Stable), v41 (Stable) and v45 (Testing)

Post by Wanabe »

Hello, it seems I have managed to find a combination of settings/newGRF to get V45 of Super Simple AI to crash in JGR 0.54.2 (https://github.com/JGRennison/OpenTTD-patches/releases). If I had to geuss based on the name of the Function in the stack trace it's due to Mail being removed from the game via viewtopic.php?t=87332 ( Improved Town Industries 2).

I've played other games close to vanilla settings with Super Simple running in the background and it seems rather stable in those configurations, even after long sessions or many years and multi-session plays. I like the simplicity of this AI overall. While it can certainly struggle or otherwise get itself into serious trouble it can also be surprisingly effective with what it does.

While I'm posting I'll add that I've noticed that sometimes it has trouble with train lines with 90 degree turns turned off and can get the trains stuck going in and out of a depot. The trains I've seen stuck did technically have an indirect route if it just turned and went to the nearest train station first but the pathfinder couldn't figure that out for the AI.

Other than the above occuring here and there my only real gripe with SuperSimpleAI is probably how slow it takes to calculate/pathfind its new routes it's building. It could understandably be intentional, of course. Sometimes though it can take so long building a train route for example that I've seen it trying to build one for multiple years and then eventually demolish it.

Cheers and thanks for developing this AI for the community.
Attachments
Wanabe&Fenix.sav
(953.55 KiB) Downloaded 38 times
Error1.png
(222.62 KiB) Not downloaded yet
Error2.png
(112.86 KiB) Not downloaded yet
Jaume
Engineer
Engineer
Posts: 54
Joined: 24 Aug 2007 15:43

Re: SuperSimpleAI v25 (Old Stable), v41 (Stable) and v46 (Testing)

Post by Jaume »

Thank you for your report Wanabe :-)

I don't have time these days, this new version 46 only fixes the crash reported at last reply by Wanabe, and a little protection for the problem reported by 3iff recently: now this AI don't try to use roadveh/train/aircraft if they are disallowed in GameSettings. But, I think, pathfinding may hang the AI if these configuration changes when it is pathfinding.

And, since v44, replacing road vehicles doesn't work well. Some road vehicles are stopped in depots for months, until they are removed.

This version is poorly tested!
Jaume
Engineer
Engineer
Posts: 54
Joined: 24 Aug 2007 15:43

Re: SuperSimpleAI v25 (Old Stable), v41 (Stable) and v47 (Testing)

Post by Jaume »

Hi all,

Version 47 is here. It fixes another (and unusual) crash.
User avatar
3iff
Tycoon
Tycoon
Posts: 1093
Joined: 21 Oct 2005 09:26
Location: Birmingham, England

Re: SuperSimpleAI v25 (Old Stable), v41 (Stable) and v47 (Testing)

Post by 3iff »

Not sure if this is fixed in V47, but I finally grabbed an issue with V45...but I've left the screenshot at home (Sorry)

Anyway, the details are in MAIN.NUT line 537 (of version 45).
The AI tries to add a wagon...and on rare occasions, WAGON = NULL but there's no check for this possibility.
It then tries to check the minspeed (or maxspeed?) of a non-existant item and it crashes the AI.
It's a very rare event which is why I've had trouble tracking it.
I'll try and get the screenshot here next time I'm on but maybe that's enough info to be going on with?
(Ah, is that the bugfix in V46??)

Meanwhile, I'll try V47.
User avatar
3iff
Tycoon
Tycoon
Posts: 1093
Joined: 21 Oct 2005 09:26
Location: Birmingham, England

Re: SuperSimpleAI v25 (Old Stable), v41 (Stable) and v47 (Testing)

Post by 3iff »

Sorry about the misinformation above. I had the wrong file and wrong line number...

Anyway, it looks like the problem may have been investigated by you in V46 (the code had been changed) and using V47 I haven't seen the issue again.
Post Reply

Return to “OpenTTD AIs and Game Scripts”

Who is online

Users browsing this forum: No registered users and 5 guests