[Freeciv-Dev] barbarian AI
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
Hello,
I have resumed working on the barbarian stuff, and I do now wonder how
to handle the barbarian leader.
Its behaviour should be: move towards/onto any friendly unit; if
there's none, flee.
The first part is relatively simple, although a problem is that the
barbarian leader might move first onto a Legion, which then moves away
in the same turn leaving the leader undefended. Because of the weird
list code, I don't know how to move it to the end of the list.
Another problem is fleeing. I thought the AI would likely have a
notion of the "secureness" of the tiles to move vulnerable units
around, but there doesn't seem to be such a thing. Anybody knows a
good fleeing algorithm? I'm sure I can reuse some code, I just can't
find it...
Falk
- [Freeciv-Dev] barbarian AI,
Falk Hueffner <=
|
|