News:

Simutrans Sites
Know our official sites. Find tools and resources for Simutrans.

r5984 and earlier: AI does not obey option allow_buying_obsolete_vehicles=off

Started by jk271, October 16, 2012, 08:47:19 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

jk271

Hi,
I have been playing sim-r5984 with several AIs. My game began in 1930 and I have been playing with timeline. Purchase of obsolete vehicles was disabled in settings. But one of AI created train having obsolete vehicles.

Option enable/disable allow_buying_obsolete vehicles probably does not apply to AI.

It might be a feature, but I think, it is a bug. Such a feature/bug is being in game for a long time.

OS: 32bit Linux on 32bit CPU
pakset: pak64, other not tested
severity: low
link to saved game:
http://simutrans-germany.com/files/upload/r5984-m1521-1931.sve

Regards jk271


P.S. I like improvement of AI goods. AI goods is able to make money with pak64 now !

Dwachs

Quote from: jk271 on October 16, 2012, 08:47:19 PM
Option enable/disable allow_buying_obsolete vehicles probably does not apply to AI.

It might be a feature, but I think, it is a bug. Such a feature/bug is being in game for a long time.
Yes indeed, this is very old behavior of AI player. I do not know, whether this is intended or not.

The no-obsolete-vehicle option was introduced years later.

paichtis

On the other hand players can (sometimes) also bypass this option.
(not posting here how but if a dev wants to know how to fix the hole I'll send him a private message)

jk271

Quote from: Dwachs on October 19, 2012, 06:56:15 PM
Yes indeed, this is very old behavior of AI player. I do not know, whether this is intended or not.

The no-obsolete-vehicle option was introduced years later.

I have not known about succession of changes leading to current state of game. Thank you for point it out.

In my opinion is, that AI should not do it. Rules should be same for all players (except some differences for public player).

On the other hand the change probably needs voice from other simutrans comunity members. At least from developers.

prissi

Initially the replacer for unknow vehicles on load time was the same than the AI seach. And the former must find a vehicle or simutrans would have crashed. So it was without timeline. Even though the AI does not use depots (There was a patch, but it had some problems) it should use no obsolete vehicles of not allowed.

Dwachs

here is a patch. I did not find a more elegant solution. any comments?

prissi

I do not find this very inelegant. Especially since the scripted AI may want such a function too.