Complete.Org: Mailing Lists: Archives: freeciv-dev: April 2001:
[Freeciv-Dev] Re: suggestion
Home

[Freeciv-Dev] Re: suggestion

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Grzegorz Borowiak <grzes@xxxxxxxxxxxxxxx>
Cc: "'freeciv-dev@xxxxxxxxxxx'" <freeciv-dev@xxxxxxxxxxx>
Subject: [Freeciv-Dev] Re: suggestion
From: Daniel Sjölie <deepone@xxxxxxxxxx>
Date: Tue, 24 Apr 2001 06:25:04 +0200

On 2001-04-23 19:41:17, Grzegorz Borowiak wrote:
> On Mon, 23 Apr 2001, Glenn Taylor wrote:
> 
> > Grzegorz Borowiak wrote:
> > 
> > > On Sun, 22 Apr 2001, Michele Slocovich wrote:
> > >
> > > > Idea
> > > > scripting language for client side ai implementation
> > >
> > > My proposals: C, C++.
> > >
> > > All other are too slow to provide good ai.
> > 
> > That's a pretty broad generalization. What time-critical
> > decisions have to be made in FreeCiv that would necessitate
> > as-fast-as-possible-AI? 
> > And can you give specific examples from that 'all other' category to
> > show how they're not appropriate?
> 
> Did you ever write some game like chess, checkers or go? If you did, you
> see what I mean. AI has really many to analyze. It must predict enemy
> moves for some turns. Situation is even more complex than in checkers,
> because civ is not deterministic; results of battle etc are random. So
> AI must predict all probable variants of events.
> 
> After all, AI must calculate value of situation in all variants and
> compare them. It is hard to make such a thing arbitrary, not using neurals
> or other adaptively developed stuff.
> 
> In addition, unlike checkers, in civ there is no full knowledge. AI must
> "guess" what is behind enemy lines. It must use not only probabilistics
> for this, but also some artificial experience, stored in e.g. neural
> networks, which are also time-consuming.

It think what You have just shown is that searching is not a god
solution for making a freeciv AI... Behavior based approaches are a lot
more appropriate here I believe... Possibly it could be complemented by
searching on some higher level but for most things it is not motivated
at all...

I think that very few (if any) human players plan in detail when playing
freeciv... I mean that You rather think "I'll use these troops to take
that city" than "I'l move this unit one step east, one north-east..."
To actually carry out these "higher" goals behaviour based AI should do
nicely... Then there really isn't that much to consider on the top level
where searching/planning might be a good idea... Also, searching looses
a LOT of it's attractiveness because of the uncertainty You mention...
Guesses about what a human opponent might do next will be extremly hard,
if not impossible, on the detail level...

> If AI has to be really good and comparable to human, but relatively fast,
> it cannot be done in other languages than those which compile to native
> machine code. It doesn't have to be nothing other than C/C++; it can be
> Fortran, Ada or Pascal, but C/C++ is here the best solution.
> 
> Bots can be written easily if many useful library functions will be
> developed.

I agree that the low level AI should be coded in C... I also think that
there should be a default higher level AI written in C using these but
it should be relatively trivial to expost the lower level to any
scripting language that can interface with C (most if not all) and thus
write a new high level AI in any language...

/Daniel

-- 
Now take a deep breath, smile and don't take life so seriously... :)



[Prev in Thread] Current Thread [Next in Thread]