Page 1 of 1

Yexo's last feature: Loading the last available AI version

Posted: 29 Jan 2010 08:47
by Zuu
While if we as AI authors have made our job good users shouldn't notice thing change I think it is good to announce it here in the NoAI forum.

What this all is about is r18944 which change the AI loading a bit so instead of taking the AI version used in a savegame it will take the AI version with the highest version number that still says that it can load the savegame.

This makes it even more important that every AI author sticks to integer versions in info.nut. Otherwise my guess is that that string will be parsed into an integer and eg "10.78" will become just 10. IIRC if two AIs report the same version only one of them will be loaded, and exactly how that decision works I don't know. Even if OpenTTD would load all AIs the scanner code would then just pick the first AI with the highest integer version that can load the savegame.


As of what I can see the only way to force using a specific version is now to in the console type: (but I'll happily be corrected if there are other ways I've missed in my review of the changes that Yexo made)

Code: Select all

start_ai <ai name>.<ai version>
(apart from removing higher AI versions from the OpenTTD search path)


Lastly I'd like to thank Yexo for implementing this feature.

Re: Yexo's last feature: Loading the last available AI version

Posted: 30 Jan 2010 08:05
by fanioz
Thats great, is that undocumented feature yet ?