Class: GameOfLife

GameOfLife(rows, lines, pattern)

new GameOfLife(rows, lines, pattern)

Game Of Life object constructor
Parameters:
Name Type Description
rows int Game's board(grid) rows
lines int Game's board(grid) lines
pattern array initial pattern to paint on board
Source:

Methods

(static) drawCell(x, y)

Draws a single cell on game's grid. Used for manual paint on grid by user.
Parameters:
Name Type Description
x int
y int
Source:

(static) init()

init game's state on grid
Source:

(static) setPattern(pattern)

Sets pattern property (later to be set on game's grid)
Parameters:
Name Type Description
pattern array
Source:

(static) start()

Starts game
Source:

(static) stop()

Stops game
Source:

(static) tick()

update the game's grid asynchronously.
Source: