Complete.Org: Mailing Lists: Archives: freeciv-dev: September 2001:
[Freeciv-Dev] Re: [Patch] Exploring triremes getting lost (PR#961)
Home

[Freeciv-Dev] Re: [Patch] Exploring triremes getting lost (PR#961)

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: rf13@xxxxxxxxxxxxxxxxxxxxxx
Cc: freeciv-dev@xxxxxxxxxxx
Subject: [Freeciv-Dev] Re: [Patch] Exploring triremes getting lost (PR#961)
From: Gregory Berkolaiko <gberkolaiko@xxxxxxxxxxx>
Date: Tue, 18 Sep 2001 21:47:13 +0100 (BST)

Raimar,

Thanks for reviewing the patch.  

 --- Raimar Falke <hawk@xxxxxxxxxxxxxxxxxxxxxxx> wrote: 
> On Mon, Sep 17, 2001 at 06:47:13PM +0100, Gregory Berkolaiko wrote:
> 
> > +static int find_nearest_friendly_port(struct unit *punit);
> 
> ??

a leftover from experimenting.  slipped through.

> > +    int unknown, most_unknown = 0; 
> > +    /* unknown is the composite weight for a tile, taking into
> account the 
> > +       number of unknown tiles around and distance to it */
> >      int threshold = THRESHOLD * move_rate;
> > +    /* threshold is how far we would venture */
> 
> Comments should be above the things they describe.

will fix (you are strict, aren't you? ;)

> > +       if (afraid_of_sinking && !is_coast_seen(x1,y1,pplayer))
> > +         unknown = 0; /* we want destination near a cost */
>                                                          ^^^^
> You mean coast?

sure

> > @@ -334,8 +344,20 @@
> >        do_unit_goto(punit, GOTO_MOVE_ANY, 0);
> >        if (punit->moves_left) {
> 
> >     if (punit->x != best_x || punit->y != best_y) {
> 
> Why and when does this case happen?

when on the way to (best_x,best_y) the unit gets scared of
(enemy, deep blue etc)

[..]
> > +      if (afraid_of_sinking && !is_coast_seen(x, y, pplayer)) {
> > +        if (punit->moves_left < (unit_move_rate(punit)+3)/2) {
> 
> s/3/SINGLE_MOVE/ ?!

oops. sorry :(

Actually I'm now thinking about implemeting GOTO_NEAR_LAND restriction as
you suggested...

G.


____________________________________________________________
Do You Yahoo!?
Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
or your free @yahoo.ie address at http://mail.yahoo.ie


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