Wikia

Freeciv

Watchlist Recent changes

Map Coordinates

All of the code examples above are in map coordinates. These preserve the local geometry of square tiles, but do not represent the global map geometry well. In map coordinates, you are guaranteed (so long as we use square tiles) that the tile adjacency rules

(map_x-1, map_y-1)
(map_x-1, map_y)
(map_x-1, map_y+1)
(map_x, map_y-1)
(map_x, map_y)
(map_x, map_y+1)
(map_x+1, map_y-1)
(map_x+1, map_y)
(map_x+1, map_y+1)

are preserved, regardless of what the underlying map or drawing code looks like. This is the definition of the system.

Map coordinates are easiest for local operations (like square_iterate or adjc_iterate) but unwieldy for global operations.

Pages on Freeciv

Add a Page
572pages on
this wiki
Advertisement | Your ad here

Latest Photos

Add a Photo
573photos on this wiki
See more >

Recent Wiki Activity

See more >

Around Wikia's network

Random Wiki