Moderator: OpenTTD Developers
the following image:
A changelog for version 9:
- Build signals around tunnels that were placed in an existing rail line
- Bugfix: verify if a tunnel will be built as the AI expects it to be built (expectations were sometimes wrong)
- Bugfix: A train stuck on a disconnected piece of rail will get a depot where it can be sold (might take a few years)
If I extract the .tar file that was downloaded by openTTD to the AI folder, RailwAI starts without any problem.
If I take a look at the .tar file, it seems that openTTD writes 3 bytes too much for the file shippathfinder.nut. Usually this wouldn't matter because of zero-padding in the tar-files, but in this case BaNaNaS generated no zero-padding here I have opened an issue on GitHub about this bug in OpenTTD.
Luckily I'm not dumb and with a slightly different file length, BaNaNaS does more zero padding.
Changelog for version 11 (a lots of updates lately):
- Bugfix: verify if a train is in the way to build a tunnel properly
- Small changes in pathfinder for ships
- Slightly fewer buoys are used
- Workaround for a bug in OpenTTD that made this AI not downloadable through OpenTTD
- Strategy: use more trains. Use less ships. Try to build more cargo routes.
- Bugfix: Use trucks more often
- Bugfix: Buoys aren't anymore avoided when planning where canals should come
- A truck service may not have the same loading station as destination station
- Bugfix: rail will be always connected properly when a rail station became accidentally a terminus station.
- Repair accidentally missing rail connections between two adjacent rail tiles
- Miscellanous things: give vehicles a name
- When extending a service A-B to C, do a better check if C is further than B (seen from A)
- Bugfix: no crash from loading a game saved while building a new train route of which the route had been re-planned
- Bugfix: continue building canals from a savegame, when it was doing that
- Do not try to replan a rail track when the first attempt wasn't feasible because it was too expensive
- Loan will not be higher than 0, if the company has 10 times more cash than the maximum allowed loan
- Implement electrifying/upgrading rail (whole network at once, only if the company has more than 5 million pounds)
The changelog for version 13:
- Share orders and copy vehicle to the group, when buying a new truck/bus/ship from a different type on a connection
- Bugfix: no crash when canceling a plan to buy a new truck/bus/ship
- Bugfix: do not build a station meant to be a terminus connecting to other tracks
- Bugfix: continue building a road detour around a level crossing from a savegame
- Bugfix: try to use bridges above the desired speed limit (instead of 0 km/h) when building a road bridge
- Removal of 90 degree turns on the rail network added in the yearly checks
- Do not build 90 degree turns when connecting rail on a specific tile to adjacent rail tiles
The changelog for version 15:
- Bugfix: removing a dead end road on a sloping tile
- Bugfix: do not use rail building costs when determining what road type to use
- Bugfix: compatibility issues with Aro AI
- Adapt chances to pick a certain transport modality based on the company name.
- Allow to extend a single rail bridge to two parallel bridges
- Ignore one-way roads in pathfinding.
- Build a second road depot on long truck routes
- Use ships slightly more often
- Longer minimum length of double rail sections on single track railway lines
- RailwAI became better in removing a level crossing with an alternative solution
- Trains/trucks/buses: if only slow vehicles are available (e.g. below 60 km/h), speed is now more important for deciding which vehicle to use
- Increased minimum distance between the first passenger railway stations on a route
- Passenger routes: set orders sometimes to full load to increase station ratings
- Minimum platform length of 5 tiles for freight trains
- Improved efficiency on the feasibility checks of a new rail line
- Retry building a level crossing when it fails because a vehicle is in the way
- Prefer industries with high production more
- Do not prefer very long truck routes, as the chances of getting income are less
It has been a while, but again time for some improvements. The changelog for version 16:
- Bugfix: Ship pathfinder shouldn't fail when trying to create a new dock on land
- Bugfix: Do not sell trucks or buses that are in a depot and were succesfully autorenewed
- Improved search to a suitable location for docks
- Added passenger ferry services
- Added new options in the list for company name parts
- Upgraded NoAI API-version to 1.6 or higher (get rid of legacy code)
- Bugfix: verify if a road bridge is connected to the next tile, when building a new route
- Bugfix: verify if a rail bridge is connected to the previous tile, when building a new route
- Bugfix: do not lower tile too much when building a railway tunnel in northeast direction
- Bugfix: do not place signals placed in the wrong direction, based on a path signal in the other direction
- Do not randomly connect rails to an adjacent train station
- When a ship or road vehicle is lost, build new roads or canals to let it reach its destination
- Re-use existing water depots
- RailwAI doesn't go to sleep when no vehicles are running yet, or when a lot of money is available to spend
- Sell vehicles when the destination station doesn't accept the cargo anymore
- Sell some vehicles if too many are waiting at the loading station
- Added support for station coverage set to lower values than default
- Check if the vehicle limit is reached before planning a new connection
- Vehicles that have 0% reliability are actively sent to a depot
- Allow more ships in one vehicle group
- Added time usage logging
- Several code optimizations to increase performance
I met your AI run for a couple years on a 1024x1024 map, temperate climate. I like its building style
After 12 years it has :
- 20 trains
- 45 RV
- 9 ships
I have noticed 2 things in its behavior :
- It tends to scan the entire map quite frequently. I think it's limiting the expansion of the company.
=> Maybe you can reduce the frequency of the scan, to make the AI a bit more competitive ?
- Its engine choice is sometimes wierd : On a wood line, it runs 2 trains : 1 with a steam engine and some wood wagon, and another train with DMU only.
=> Maybe it should calculate, on a given train line, what configuration has the more cargo ?
These are only suggestions
keep it simple, stupid
It looks like scanning the map indeed takes a lot of time on a large map. I used to test on much smaller maps, so I'll try to improve the performance on large maps in the next updates.
The usage of 2 different train types on a route is as intended: in my opinion it looks better with more different trains. Seemingly there was a DMU that can be used to transport wood. The length of a train might be short if the company didn't have enough money for a longer train yet. RailwAI should be able to adjust the train length after a while. Please let me know if it indeed increases the train length some day.
- Bugfix: Do not convert electrified railway into diesel railway, even if there are no electric trains.
- Heuristic map scanning, instead of interating the whole map (huge performance improvement on large maps)
- A general performance improvement in computing tiles
I tested your AI in the same game I did previously. Overall performance is improved
After one year of existance, it seems to be stuck in a loop where it scans industries on the map ...
Here is a screen of what the debug menu says :
I can't link the save do to files reasons.
keep it simple, stupid
- Keep track of the reason a vehicle is sent to a depot, instead of guessing the correct action in the depot
- Solve more train deadlocks by sending trains to a nearby depot for maintenance, and by changing signal types
- Allow bidirectional transporation of cargo (e.g. valuables) if possible
- Do not randomly connect a train station to adjacent rails
- Speed optimizations in pathfinders
- Rail pathfinder: found path is more often suitable for a double track railway line
- Bugfix: do not accidentally remove rail below a bridge when only the bridge should be removed
- Bugfix: do not remove a dead end rail track, if it can be connected easily
- Bugfix: prevent disconnected rail track parts on the second track
- Bugfix: prevent infinite loops of starting a rail pathfinder
- Check if road stations on town roads are disabled (construction.road_stop_on_competitor_road)
- Added a bit of strategy about distance between truck stations
- Do not buy an other bankrupt company when the own company doesn't make enough profit
- More speed optimizations in pathfinders
- Do not only use drivethrough stations for buses/trucks
- Use full load for bus routes operated with less than 3 buses
- Take steepness setting of slopes into account when buying a new train
- Road pathfinder: allow road corners on sloped tiles on which corner roads can be built
- Rail: changed distance between signals from 4 to 6
Users browsing this forum: No registered users and 4 guests