Skip to content

Instantly share code, notes, and snippets.

@vim13
vim13 / main.js
Last active December 23, 2015 03:09 — forked from yat1ma30/main.js
var SCREEN_SIZE = 500; // キャンバスの幅
var SIDE_CELLS = 200; // 一辺のセルの数
var CELL_SIZE = SCREEN_SIZE / SIDE_CELLS; // セルの幅
var FPS = 10; // フレームレート
var canvas; //= document.getElementById('world');
var context; //= canvas.getContext('2d');
window.onload = function() {
var field = new Array(SIDE_CELLS*SIDE_CELLS); // フィールド情報
var tempField = new Array(SIDE_CELLS*SIDE_CELLS); // フィールド情報の一時記憶用