AI on bzr 8544 (and later) did not expand territory

Bug #1740503 reported by tando
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
widelands
Fix Released
Undecided
Unassigned

Bug Description

I am testing a self build Map (512x512 - 8 Player - Ubuntu - Widelands-Daily) over the past several days. The AI did a good job but after upgrade to 8544 the AI did only sometimes expand - I am not able to find the setting when it does or not.
On Build 19 the AI did expand. I put the Map and two replays in a „zip-file“.
Note: Player 1 is the Human player - I did not build anything.

tando
Link to the Map and Replays: https://www.dropbox.com/s/buo1wh8r85v3xfw/Widelands_Bug_AI.zip?dl=0

Tags: ai
Revision history for this message
tando (christofphilipps) wrote :
Revision history for this message
TiborB (tiborb95) wrote :

When testing your map I see that the map is probably quite CPU hungry, and FPS falls down very quickly. If this is the case with your testing, AI is not getting enough CPU time to do anything.

If you look at output in thge terminal, you might see outputs like:
...AI: game speed to high....
then you just need to slow down the speed.

Anyway the question is what is slowing down game on this map. I would say it can be new allows_seafaring check.....

Revision history for this message
TiborB (tiborb95) wrote :

Can you say what was the last revision when the map worked fine?

Revision history for this message
tando (christofphilipps) wrote :

OK - I think you get the right point !

Indeed, I tested at high speed (sometimes 30 or (much) more). At 8543 that was no Problem. There was a Test-Game between 7 AI-Players over 70 hours of gaming time at this Version.

After your hint I started a new test game with 8547 at speed 2x and everything is OK.

Thanks

Revision history for this message
TiborB (tiborb95) wrote :

But I think this is real problem, though not of AI...

On my recent testing I noticed significant hangs in game corresponding to running of allows_seafaring function (every ~20 seconds)... If it will be confirmed by other players, this will have to be addressed. Of course the intensity of problems depends on amount of water (surface) in the particular map (providing there are at least 2 ports)

Revision history for this message
GunChleoc (gunchleoc) wrote :

Pathfinding is always a tough problem - maybe perform the check less often? We could maybe use a notification to let it run only on terrain and port space changes, plus once in the beginning when the map gets loaded.

Changed in widelands:
milestone: none → build20-rc1
Revision history for this message
TiborB (tiborb95) wrote :

Yes, these are good options, but perhaps current algorithm can be simplified and speed up.

Revision history for this message
GunChleoc (gunchleoc) wrote :

allows_seafaring performance was fixed in r8653, so I'm considering this bug closed.

Changed in widelands:
status: New → Fix Committed
Revision history for this message
GunChleoc (gunchleoc) wrote :

Fixed in build20-rc1

Changed in widelands:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.