Complete.Org: Mailing Lists: Archives: freeciv-dev: August 1999:
Re: [Freeciv-Dev] Suggestion: FreeCiv on a Hex!
Home

Re: [Freeciv-Dev] Suggestion: FreeCiv on a Hex!

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Freeciv Dev <freeciv-dev@xxxxxxxxxxxx>
Subject: Re: [Freeciv-Dev] Suggestion: FreeCiv on a Hex!
From: Artur Biesiadowski <abies@xxxxxxxxx>
Date: Thu, 19 Aug 1999 10:27:26 +0200

Andy Black wrote:

abcde
fghij
klmno

> if h is the hexagon in quesstion, it's neghbors are (clockwise from the
> top) c, d, i, m, g, b

> when looking at the cell boarders, you would look at the folowing array
> positions [x-1, y-1], [x, y-1], [x+1, y-1], [x-1, y+1], [x, y+1], [x+1,
> y+1]

Which, for hexagon h give:
b c d l m n (instead of c d i m g b )

In hexmap with straight columns (opposed to straigth rows), you ALWAYS
take a [x,y-1] and [x,y+1], [x-1,y],[x+1,y]. And two more from either
y+1 or y-1  x-1/x+1 sides.

BTW, if somebody will start to implement this in C code, please use
hexes with aligned rows. It helps during repaint when you have
3d-looking sprites - you have to repaint only two hexes each from up and
bottom, instead of 3.



Artur

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