Code review comment for lp:~widelands-dev/widelands/seafaring-ai

Revision history for this message
TiborB (tiborb95) wrote :

few words to rev. 7245

I think the crashes of seafaring were due to the command queue, especially when it grows big and it takes too long for a command to be processed. AI does not know whether there is a relevant command in the queue and issues another one based on actual status of the ship. When the first command is executed, the status might have changed and second command might crash the game. So I want to add following check:
http://bazaar.launchpad.net/~widelands-dev/widelands/seafaring-ai/view/head:/src/logic/playercommand.cc#L787 (+ 2 similar test below)

I thinks (based on testing) it does the job, but I would like to limit the test only to computer player - I just dont know how to find out if the current player is an AI player.

I think these tests might interfere with GUI control of ships.

« Back to merge proposal