mirror of
https://github.com/rastapasta/mapscii.git
synced 2024-11-25 01:23:58 +01:00
24 lines
573 B
JavaScript
24 lines
573 B
JavaScript
/*#
|
|
termap - Terminal Map Viewer
|
|
by Michael Strassburger <codepoet@cpan.org>
|
|
Discover the planet in your console!
|
|
|
|
This scripts boots up the application.
|
|
|
|
TODO: params parsing and so on
|
|
#*/
|
|
|
|
require('coffee-script/register');
|
|
|
|
const fs = require('fs');
|
|
const Termap = require(__dirname+'/src/Termap');
|
|
const Tile = require(__dirname+'/src/Tile')
|
|
|
|
termap = new Termap();
|
|
|
|
// TODO: abstracing this class, create loader class
|
|
data = fs.readFileSync(__dirname+"/tiles/regensburg.pbf.gz");
|
|
tile = new Tile(data);
|
|
termap.renderer.features = tile.layers
|
|
termap._draw();
|