[Freeciv-Dev] Re: (PR#4326) Pathfinding
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
On Fri, Jun 06, 2003 at 11:06:29AM -0700, Gregory Berkolaiko wrote:
>
> On Fri, 6 Jun 2003, Raimar Falke wrote:
>
> > On Tue, Jun 03, 2003 at 02:12:29PM -0700, ChrisK@xxxxxxxx wrote:
> > > On Tue, Jun 03, 2003 at 01:21:04PM -0700, Raimar Falke wrote:
> > > > On Sat, May 31, 2003 at 12:20:49PM -0700, ChrisK@xxxxxxxx wrote:
> > > > >
> > > > > Problem No. 3:
> > > > >
> > > > > With the old code, I was able to send a land unit (not marine) from a
> > > > > ship
> > > > > into an empty enemy city. It knew that the direct way was impossible
> > > > > and did
> > > > > chose a way from ship onto land, from land into city.
> > > > >
> > > > > The new code throws an error: only marines can attack from sea.
> > > >
> > > > This seems interresting. It should find the correct path. Do you have
> > > > a savegame?
> > >
> > > Attack Lahore.
> >
> > I see. The solution is to use unit.c:test_unit_move_to_tile in
> > pft.c:normal_move_unit. However this isn't easy since we don't have
> > the unit type which test_unit_move_to_tile
> > wants. test_unit_move_to_tile needs this for the marines flag.
> >
> > Greg: you may now see why I prefered a flags field in pf_parameter
> > instead of the zoc_used field.
>
> I admit I was thinking the same. But we need to carefully consider what
> we do, because some AI calculations need to ignore ZoC...
They this code has to remove F_IGZOC in parameter->flags.
> or use a different notion of ZoC.
If code wants this you have to be more specific.
> Another solution is write another MC-callback marine_move_unit.
You would need another flags to trigger this. So we would have to add
a "bool is_marine" to pf_parameter. I'm strongly against this since
this duplicates unit_type->flags.
Raimar
--
email: rf13@xxxxxxxxxxxxxxxxx
Windows: From the people who brought you edlin...
- [Freeciv-Dev] Re: (PR#4326) Pathfinding, (continued)
[Freeciv-Dev] Re: (PR#4326) Pathfinding, Gregory Berkolaiko, 2003/06/06
[Freeciv-Dev] Re: (PR#4326) Pathfinding, Gregory Berkolaiko, 2003/06/06
Message not available
- [Freeciv-Dev] Re: (PR#4326) Pathfinding,
Raimar Falke <=
[Freeciv-Dev] Re: (PR#4326) Pathfinding, Gregory Berkolaiko, 2003/06/09
[Freeciv-Dev] Re: (PR#4326) Pathfinding, Gregory Berkolaiko, 2003/06/09
[Freeciv-Dev] Re: (PR#4326) Pathfinding, Gregory Berkolaiko, 2003/06/10
[Freeciv-Dev] Re: (PR#4326) Pathfinding, Gregory Berkolaiko, 2003/06/11
|
|