Projetos
Ver no GitHub
blaze33/way-of-life
Sobre
Conway's game of life implemented in JavaScript & WebAssembly, rendered to canvas.
Jogos e emulaçãoCrescimento medido de estrelas
- em 24 h
- 0
- em 7 dias
- 0
- em 15 dias
- 0
- em 1 mês
- Coletando histórico
Variações líquidas em períodos sobrepostos, não totais diários. Medições ausentes ficam em branco. Estrelas indicam interesse, não qualidade.
README.md
OriginalThe Way of Life
Conway's game of life implemented both in JavaScript and in WebAssembly using a canvas element for rendering.
Installation
The npm package only links to the ES6 code so it's only usable as a dependency for now.
npm install --save-dev way-of-life
Usage
import {Engine, acorn} from 'way-of-life'
// initialize the game with an empty 40x40 matrix
const engine = new Engine(40, 40)
engine.init()
// initialize some living cells around the center of the matrix
acorn(engine, 20, 20)
// compute the next state of game
engine.computeNextState()
See the demo code for a more advanced usage.
Explore projetos relacionados
Carregando…