Complete.Org: Mailing Lists: Archives: freeciv-dev: August 2001:
[Freeciv-Dev] Re: Map coordinate cleanups.
Home

[Freeciv-Dev] Re: Map coordinate cleanups.

[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: Map coordinate cleanups.
From: Tony Stuckey <stuckey@xxxxxxxxxxxxxxxxx>
Date: Fri, 17 Aug 2001 10:07:55 -0500

On Fri, Aug 17, 2001 at 12:11:42PM +0200, Raimar Falke wrote:
> I have to admit I haven't learned the difference between proper and
> normal during my coding. Maybe I have used too much copy and paste. I
> think there should be the following sets of positions/tiles:
> 
>  A = the base set of all possible positions
>  B = the set of real positions: a real position is a position which have
>  directly or indirectly a tile associated with it
>  C = the set of normalized positions: each tile has exactly one
>  normalized position associated with it
>  D = A minus B = the set of unreal positions
>  E = B minis C = the set of unnormalized positions
> 
> B is a subset of A. C is a subset of B. Depending on the topology
> these are subsets or proper subsets.
> 
> The following methods are declared:
>  - is_real_position(p) tests if p is in B
>  - is_normalized_position(p) tests if p is in C
>  - p'=normalize_position(p) p must be in B, returns the normalized
>  version of p
> 
> All methods should receive and accept only normalized positions. Only
> at the generation of positions (mapgen, iterate macros) should be
> logic which tests if the created position for realness and normalize
> it.
> 
> At least for me this segmentation is easy to understand. Can this be
> mapped into your model? Have I forgot something?

        This is also the most accessible description I've seen.
-- 
Anthony J. Stuckey                              stuckey@xxxxxxxxxxxxxxxxx
"And they said work hard, and die suddenly, because it's fun."
        -Robyn Hitchcock.


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