Complete.Org: Mailing Lists: Archives: freeciv-dev: September 2002:
[Freeciv-Dev] Re: [Patch] [RFC] Path finding version 14
Home

[Freeciv-Dev] Re: [Patch] [RFC] Path finding version 14

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Raimar Falke <rf13@xxxxxxxxxxxxxxxxx>
Cc: freeciv development list <freeciv-dev@xxxxxxxxxxx>
Subject: [Freeciv-Dev] Re: [Patch] [RFC] Path finding version 14
From: Gregory Berkolaiko <Gregory.Berkolaiko@xxxxxxxxxxxx>
Date: Sat, 14 Sep 2002 20:32:27 +0100 (BST)

On Sat, 14 Sep 2002, Raimar Falke wrote:

> On Sat, Sep 14, 2002 at 07:17:48PM +0100, Gregory Berkolaiko wrote:
> > 
> > True true.  Your naming confused the hell out of me: 
> > plain_get_next_position is the function behind pf_next and not behind 
> > pf_get_next_position as a sane person would expect :)
> 
> There is no pf_get_next_position (except in an old comment). There is
> a pf_next_get_position. It is quite simple:
>   - there is pf_get_path
>   - and there is pf_next and the query functions pf_next_*
> 
> And the implementation has:
>  - plain_get_path (called by pf_get_path and pf_next_get_path) and
>  - plain_get_next_position (called by pf_next)

So there is
        pf_next_get_position    
and
        plain_get_next_position 
but they are complitely unrelated.

I call this confusing.

> > > > 5.  What is the last argument to enum known_type (*get_known) (int,
> > > > int, struct player *,int) ?
> > > 
> > > Good question. Should be removed. No idea how it got there.
> > 
> > How did it compile with this?
> 
> A constant 0 is supplied.

Why not 42? :)

Anyway, my code is roughly ready.  It's still wet behind the ears but 
unless it's picked, there is no need to wash it.  Among other things, it 
_doesn't_ support is_position_dangerous yet.

What sort of test shall we run?  How about finding and printing paths to
Michoacan for all units repeated N times in the attached savegame (login
aas02101)?

Anyway, I split for today...

The path_finding[ch] attached.  Don't fry me please.  If you see something 
that your code does and my doesn't (probably lots of things) please tell 
me.

G.

Attachment: pf.tar.gz
Description: GNU Zip compressed data

Attachment: t6.gz
Description: GNU Zip compressed data


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