Add basic background rendering

This commit is contained in:
asraelite 2018-03-02 01:32:18 +00:00
parent 0c5ad88981
commit fc8d282509
10 changed files with 156 additions and 8 deletions

View file

@ -1,16 +1,21 @@
import * as graphics from './graphics/index.mjs';
const game = {
state: {
room: 'menu',
paused: false
}
};
export let game;
export function init() {
game.state.room = 'menu';
game = {
state: {
room: 'menu',
paused: false
}
};
graphics.init();
tick();
}
function tick() {
graphics.render();
requestAnimationFrame(tick);
}