[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [glob2-devel] Warrior behaviour
From: |
Hein-Pieter van Braam |
Subject: |
Re: [glob2-devel] Warrior behaviour |
Date: |
Mon, 27 Dec 2004 21:04:57 +0100 |
User-agent: |
KMail/1.7.1 |
Hi,
can you please explain to me what the else block on line 1663 in Unit.cpp is
doing there? it seems that the warriors are a bit more sane without it, if I
understand it correctly, it causes the warriors to walk to the upper left if
they don't have anything else to do. I don't think it should be there, or
should at least be replaced with something random, maybe "Bind" them within a
reasonable radius from the closest hive?
greetings,
hp
On Monday 27 December 2004 20:04, Stephane Magnenat wrote:
> Hi,
>
> > I think I've tracked the problem of the weird warrior behaviour, it
> > appears that the warriors always "want" to go somewhere. I can't figure
> > out what it is, but as soon as they start following a guard area
> > gradient, they also have a point outside of the gradient where they want
> > to be, but they can't go there, because they are "trapped" in the guard
> > area.
> >
> > This appears to be the reason why they tend to hang around in one part of
> > the guard area.
> >
> > I'm looking into this, but the code's a bit complicated :)
>
> Yes I know, and not well commented. We should improve this, but this is not
> easy as documenting those big state machines is not straightforward.
>
> Thanks for your work on this, I really appreciate it :-)
>
> Steph