Skip to content

Documentation?

ColonisationCaptain edited this page Jun 27, 2020 · 4 revisions

The game is played on a 16x16 board. Two 2d sequences are used to store an identifier of the terrain (terrain id) and the sprite in each of the cells (game object id).

Terrain IDs

Terrain ID Terrain Colour
0 No man's land green
1 Player 1's land red
2 Player 2's land yellow

Game object IDs

The correct game object id can be derived from the id of the player who owns it and the unit id using 64p+u, where p is the player id and u is the unit id.

Unit ID Unit
1 1 land troop
2 2 land troops
3 3 land troops

Game state

game_state defines what is displayed on screen.

Value Game State
{nil, {}} Map Screen
{0, {}} Menu Screen - game_state[2] stores the displayed actions
{1, {}} Info Popup - game_state[2] stores the popup text
Clone this wiki locally