glob2-devel
[Top][All Lists]

## Re: [glob2-devel] flags vs. areas: getting the best of both worlds

 From: Joe Wells Subject: Re: [glob2-devel] flags vs. areas: getting the best of both worlds Date: Sat, 07 Apr 2007 17:49:48 +0100 User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux)

```Kai Antweiler <address@hidden> writes:

>> Actually, the radius can be smaller than the distance following my
>> suggested definition above.
>
> Oops!  I forgot about "the continues set of ...".
>
> I think distance should have a quadratic influence, so that flag
> has locally me power.

I'm not quite sure what you mean.  Can you give an example?

> Also the radius isn't the best choice determine the strength, as it
> already influences which areas of cells will be considered to be
> governed.
>
> There should be a strength or precedence value instead.

I agree that one wants some notion of strength.  I think under my
proposal the radius effectively acts as the strength.  See my example
below.

> For example you might want Flag B to govern most cells to it's left
> were it competes with Flag A, but not touch any of the cells to its
> right.  Let's say on the right are some cell that you want to be inactive
> now, but active at a later time.  And you can't make Flag A smaller
> without fragmenting the areas that it should govern.

Can you give an example?

Here is an example like what you suggest that should do what you want.
We want A to govern the cells marked by a, B to govern the cells
marked by b, and the cells marked by c to be inactive (for now).  To
solve this, I add another flag C that requests zero workers and clears
nothing (and is therefore inactive).  Let the radius of A be 1, the
radius of B be 3, and the radius of C be 3.  Here is a diagram that
shows how the cells divide:

aabbbbccc
aabbbbccc
AabbbBCcc
aabbbbccc
aabbbbccc

When contiguous cells are shared by multiple flags, the boundaries
between the different subregions will generally be straight lines.

Of course, it might be easier to do this example by removing all of
the guard cells on the locations marked c.

>>>> A minor addition:  It might be useful to allow moving a war flag to
>>>> optionally move the set of cells it governs.  This could allow things
>>>> like "lines of battle" or help to make flanking attacks.
>>>
>>> Do you mean that the flag will have a noncircular region that
>>
>> You didn't seem to complete your sentence.  What was your question?
>
> I was wondering if you meant that those flags must be moveable like
> it flags are today, or something absurd.
> But I guess you mean that when moving a flag there should be an option
> to drag the fields that are governed by it along.

Right, that is what I meant.

> approximating a stretching, shrinking and turning effect as well.

What would the user interface for this be like?  That is the hard
part.  I designed my suggestion the way it is because it uses only
existing user interface tools (both for input and output).  The only
small changes I suggest are adding two options to war flags that
control whether the war flag can govern a set of guard cells instead
of a circular region (defaulting to the current behavior) and whether
the war flag would drag those cells along when moved.

--
Joe

```