Add start of ship editing grid

This commit is contained in:
asraelite 2018-03-05 00:57:33 +00:00
parent b88c0eb358
commit 2fbabc785e
16 changed files with 249 additions and 18 deletions

16
js/graphics/edit.mjs Normal file
View file

@ -0,0 +1,16 @@
import {context} from './index.mjs';
import * as edit from '../game/edit.mjs';
import * as world from '../world/index.mjs';
export function render() {
let ship = world.playerShip;
context.save();
context.translate(...ship.com);
context.rotate(ship.r);
let [cx, cy] = ship.localCom;
context.translate(-cx, -cy);
context.restore();
}