Tested it now with the 3rd frisian scenario.
The AI behaved quite well, just some nits:
– It builds mainly blockhouses and small milsites. IMHO it should build
preferably bigger milsites near the enemy´s border, even if it´s unguarded.
– It´s still quite confused by the inability to build woodcutters, quarries and
mines. It builds useless buildings like taverns (that can be solved by just
forbidding everything) and it neglects important buildings like warehouses (are
very important there because that´s where the script creates wares you cannot
produce yourself).
– There is much free space as a consequence of not having foresters, but
space-consuming buildings (reedyard etc) are cramped closely together; but
that´s a more general AI-problem.
– I get some compiler warnings:
/home/benedikt/wl/AI-fixes/src/ai/defaultai.cc:2461: Use "TODO(username):
<msg>".
/home/benedikt/wl/AI-fixes/src/ai/defaultai.cc:2463: Trailing whitespace at end
of line
[1007/1455] Building CXX object src/ai/CMakeFiles/ai.dir/defaultai.cc.o
../src/ai/defaultai.cc: In member function ‘bool
DefaultAI::check_productionsites(uint32_t)’:
../src/ai/defaultai.cc:4502:46: warning: comparison of integer expressions of
different signedness: ‘uint32_t’ {aka ‘unsigned int’} and ‘int’ [-Wsign-compare]
gametime - site.bo->last_dismantle_time >
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
(std::abs(management_data.get_military_number_at(169)) / 10 + 1) * 60
* 1000 &&
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> But this was meant for Nordfriese in particular to see whether my changes
> would solve his issues in the scenario which led him to start working (and
> making good progress for his own scenario specific AI). However I already had
> the impression he might be a little bit sadistic with the player to connect
> all these farms. ;-)
Hey ;) The point of this objective is force the player to be almost idle until
the enemy is standing right at his gates. And to force him to create a good
road network under this pressure, which can be very important for the battles
later.
Btw, my own AI is not scenario-specific – it´s a template for every(!) scenario
that wants an AI specific to it
--
https://code.launchpad.net/~widelands-dev/widelands/AI-fixes/+merge/367309
Your team Widelands Developers is subscribed to branch
lp:~widelands-dev/widelands/AI-fixes.
_______________________________________________
Mailing list: https://launchpad.net/~widelands-dev
Post to : [email protected]
Unsubscribe : https://launchpad.net/~widelands-dev
More help : https://help.launchpad.net/ListHelp