major ui refactor incomming
parent
a75c18d197
commit
5f193829c8
|
|
@ -1,10 +1,7 @@
|
||||||
import { Task } from "@tasks";
|
import { Item, ItemState } from "@items";
|
||||||
import { Game } from '@game';
|
|
||||||
import { ARROWHEAD, FLINT_NORMAL, SLATE, STICK } from '../items/CoreItems.js';
|
|
||||||
import { ItemState } from "@items";
|
|
||||||
import { Popup } from "../../../src/ui/Popup.js";
|
|
||||||
import { inspect } from 'util';
|
|
||||||
import { Place, ResourceNode } from "@world";
|
import { Place, ResourceNode } from "@world";
|
||||||
|
// import { STICK } from "../items/CoreItems.js";
|
||||||
|
|
||||||
|
|
||||||
// export const GATHER_FLINT = new Task('core:gather-flint')
|
// export const GATHER_FLINT = new Task('core:gather-flint')
|
||||||
// .setName('Gather Flint')
|
// .setName('Gather Flint')
|
||||||
|
|
@ -32,6 +29,12 @@ import { Place, ResourceNode } from "@world";
|
||||||
// Game.current.inv.add(itemState);
|
// Game.current.inv.add(itemState);
|
||||||
// });
|
// });
|
||||||
|
|
||||||
|
|
||||||
|
export const STICK = new Item()
|
||||||
|
.setName("Stick")
|
||||||
|
.plural('Sticks')
|
||||||
|
.setId('core:resources/stick')
|
||||||
|
|
||||||
export const Forest = new Place()
|
export const Forest = new Place()
|
||||||
.setName('Forest')
|
.setName('Forest')
|
||||||
.setId('core:forest')
|
.setId('core:forest')
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
"@nodegui/nodegui": "^0.33.3",
|
||||||
"@types/blessed": "^0.1.17",
|
"@types/blessed": "^0.1.17",
|
||||||
"@types/bonjour": "^3.5.8",
|
"@types/bonjour": "^3.5.8",
|
||||||
"@types/chai": "^4.2.19",
|
"@types/chai": "^4.2.19",
|
||||||
|
|
@ -17,6 +18,7 @@
|
||||||
"bonjour": "^3.5.0",
|
"bonjour": "^3.5.0",
|
||||||
"chai": "^4.3.4",
|
"chai": "^4.3.4",
|
||||||
"chalk": "^4.1.1",
|
"chalk": "^4.1.1",
|
||||||
|
"chokidar": "^3.5.2",
|
||||||
"deepmerge": "^4.2.2",
|
"deepmerge": "^4.2.2",
|
||||||
"faker": "^5.5.3",
|
"faker": "^5.5.3",
|
||||||
"frigid": "^1.3.13",
|
"frigid": "^1.3.13",
|
||||||
|
|
@ -44,6 +46,7 @@
|
||||||
"test": "mocha",
|
"test": "mocha",
|
||||||
"lint": "eslint src/**/*.ts",
|
"lint": "eslint src/**/*.ts",
|
||||||
"web": "web-dev-server --open index.html --node-resolve --watch",
|
"web": "web-dev-server --open index.html --node-resolve --watch",
|
||||||
"profile": "node --inspect-brk --no-warnings --loader ./lib/aliases.mjs --enable-source-maps out/src/index.js"
|
"profile": "node --inspect-brk --no-warnings --loader ./lib/aliases.mjs --enable-source-maps out/src/index.js",
|
||||||
|
"gui": "qode qode.js"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,53 @@
|
||||||
|
import {
|
||||||
|
QMainWindow,
|
||||||
|
QWidget,
|
||||||
|
QLabel,
|
||||||
|
FlexLayout,
|
||||||
|
QPushButton,
|
||||||
|
QIcon
|
||||||
|
} from '@nodegui/nodegui';
|
||||||
|
// import logo from '../assets/logox200.png';
|
||||||
|
|
||||||
|
const win = new QMainWindow();
|
||||||
|
win.setWindowTitle("Hello World");
|
||||||
|
|
||||||
|
const centralWidget = new QWidget();
|
||||||
|
centralWidget.setObjectName("myroot");
|
||||||
|
const rootLayout = new FlexLayout();
|
||||||
|
centralWidget.setLayout(rootLayout);
|
||||||
|
|
||||||
|
const label = new QLabel();
|
||||||
|
label.setObjectName("mylabel");
|
||||||
|
label.setText("Hello");
|
||||||
|
|
||||||
|
const button = new QPushButton();
|
||||||
|
// button.setIcon(new QIcon(logo));
|
||||||
|
|
||||||
|
const label2 = new QLabel();
|
||||||
|
label2.setText("World");
|
||||||
|
label2.setInlineStyle(`
|
||||||
|
color: red;
|
||||||
|
`);
|
||||||
|
|
||||||
|
rootLayout.addWidget(label);
|
||||||
|
rootLayout.addWidget(button);
|
||||||
|
rootLayout.addWidget(label2);
|
||||||
|
win.setCentralWidget(centralWidget);
|
||||||
|
win.setStyleSheet(
|
||||||
|
`
|
||||||
|
#myroot {
|
||||||
|
background-color: #009688;
|
||||||
|
height: '100%';
|
||||||
|
align-items: 'center';
|
||||||
|
justify-content: 'center';
|
||||||
|
}
|
||||||
|
#mylabel {
|
||||||
|
font-size: 16px;
|
||||||
|
font-weight: bold;
|
||||||
|
padding: 1;
|
||||||
|
}
|
||||||
|
`
|
||||||
|
);
|
||||||
|
win.show();
|
||||||
|
|
||||||
|
global.win = win;
|
||||||
|
|
@ -5,7 +5,7 @@ import { TaskList } from './TaskList.js';
|
||||||
import { Inventory } from './Inventory.js';
|
import { Inventory } from './Inventory.js';
|
||||||
import { Menu } from './ui/Menu.js';
|
import { Menu } from './ui/Menu.js';
|
||||||
import Time, { Tickable } from './Time.js';
|
import Time, { Tickable } from './Time.js';
|
||||||
import { render, Renderable, setTitle, start } from './ui/UI.js';
|
import { render, Renderable, setTitle, start } from '@ui';
|
||||||
import { ready } from './multiplayer/mDNS.js';
|
import { ready } from './multiplayer/mDNS.js';
|
||||||
import faker from 'faker';
|
import faker from 'faker';
|
||||||
import { World } from '@world';
|
import { World } from '@world';
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ import { Serializable } from 'frigid';
|
||||||
import { Game } from './Game.js';
|
import { Game } from './Game.js';
|
||||||
import { Item, ItemState } from './registries/Items.js';
|
import { Item, ItemState } from './registries/Items.js';
|
||||||
import { Popup } from './ui/Popup.js';
|
import { Popup } from './ui/Popup.js';
|
||||||
import { Renderable } from './ui/UI.js';
|
import { Renderable } from '@ui';
|
||||||
|
|
||||||
export class Inventory extends Serializable implements Renderable {
|
export class Inventory extends Serializable implements Renderable {
|
||||||
items: ItemState<any>[];
|
items: ItemState<any>[];
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ import faker from 'faker';
|
||||||
import { Task, TaskState } from './registries/Tasks.js';
|
import { Task, TaskState } from './registries/Tasks.js';
|
||||||
import Time, { Tickable } from './Time.js';
|
import Time, { Tickable } from './Time.js';
|
||||||
import { Game } from './Game.js';
|
import { Game } from './Game.js';
|
||||||
import { render, Renderable, RenderMode } from './ui/UI.js';
|
import { render, Renderable, RenderMode } from '@ui';
|
||||||
import { Memory } from './Memory.js';
|
import { Memory } from './Memory.js';
|
||||||
import { getTheme } from '@themes';
|
import { getTheme } from '@themes';
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
import { getTheme } from '@themes';
|
import { getTheme } from '@themes';
|
||||||
import { Serializable } from 'frigid';
|
import { Serializable } from 'frigid';
|
||||||
import { Task, TaskState } from './registries/Tasks.js';
|
import { Task, TaskState } from './registries/Tasks.js';
|
||||||
import { render, Renderable, panels } from './ui/UI.js';
|
import { render, Renderable, panels } from '@ui';
|
||||||
|
|
||||||
export class TaskList extends Serializable implements Renderable {
|
export class TaskList extends Serializable implements Renderable {
|
||||||
tasks: TaskState<unknown, unknown>[] = [];
|
tasks: TaskState<unknown, unknown>[] = [];
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
import chalk from "chalk";
|
import chalk from "chalk";
|
||||||
import { Serializable } from "frigid";
|
import { Serializable } from "frigid";
|
||||||
import { getTheme } from "@themes";
|
import { getTheme } from "@themes";
|
||||||
import { Renderable } from "./ui/UI.js";
|
import { Renderable } from "@ui";
|
||||||
|
|
||||||
type AbbreviatedMonthName = string;
|
type AbbreviatedMonthName = string;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,7 @@
|
||||||
|
|
||||||
|
|
||||||
|
export function osrsNumber(x: number): string {
|
||||||
|
if(x < 10_000) return '' + x;
|
||||||
|
else if (x < 10_000_000) return Math.floor(x / 1000) + 'K';
|
||||||
|
else return Math.floor(x / 1_000_000) + 'M';
|
||||||
|
}
|
||||||
82
src/index.ts
82
src/index.ts
|
|
@ -1,14 +1,83 @@
|
||||||
import { render } from './ui/UI.js';
|
|
||||||
import { ensureDirSync } from 'fs-extra';
|
import { ensureDirSync } from 'fs-extra';
|
||||||
import { lstatSync } from 'fs';
|
import { appendFileSync, lstatSync } from 'fs';
|
||||||
import { parse, resolve } from 'path';
|
import { parse, resolve } from 'path';
|
||||||
import walkSync from 'walk-sync';
|
import walkSync from 'walk-sync';
|
||||||
import { fileURLToPath } from 'url';
|
import { fileURLToPath } from 'url';
|
||||||
import { Game } from '@game';
|
import { Game } from '@game';
|
||||||
import { isStarted, stop } from './ui/UI.js';
|
import { isStarted, stop, render } from '@ui';
|
||||||
import { writeFileSync } from 'fs';
|
import { writeFileSync } from 'fs';
|
||||||
import ansi from 'sisteransi';
|
import ansi from 'sisteransi';
|
||||||
|
import { spawn } from 'child_process';
|
||||||
|
import cluster from 'cluster';
|
||||||
|
import chokidar from 'chokidar';
|
||||||
|
|
||||||
|
const hotReload = true;
|
||||||
|
let restartTimer: NodeJS.Timeout = null;
|
||||||
|
|
||||||
|
let worker: cluster.Worker = null;
|
||||||
|
function createWorker() {
|
||||||
|
start();
|
||||||
|
|
||||||
|
function start() {
|
||||||
|
if (cluster.isMaster) {
|
||||||
|
worker = cluster.fork();
|
||||||
|
worker.on('message', (message) => {
|
||||||
|
if(message === 'ipc-restart') {
|
||||||
|
worker.on('exit', () => {
|
||||||
|
setTimeout(createWorker, 0);
|
||||||
|
})
|
||||||
|
worker.kill();
|
||||||
|
} else if (message === 'ipc-quit') {
|
||||||
|
worker.on('exit', () => {
|
||||||
|
process.exit(0);
|
||||||
|
})
|
||||||
|
worker.kill();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// from any cluster context, gracefully exit if needed, and begin anew!
|
||||||
|
export function restart() {
|
||||||
|
if (cluster.isWorker) {
|
||||||
|
process.send('ipc-restart');
|
||||||
|
} else if(worker) {
|
||||||
|
worker.on('exit', () => {
|
||||||
|
setTimeout(createWorker, 0);
|
||||||
|
})
|
||||||
|
worker.kill();
|
||||||
|
} else {
|
||||||
|
createWorker();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export function quit() {
|
||||||
|
if (cluster.isWorker) {
|
||||||
|
process.send('ipc-quit');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (cluster.isWorker) {
|
||||||
|
begin();
|
||||||
|
} else {
|
||||||
|
// TODO make hotreload actually bring a popup on the client
|
||||||
|
// so that the user should press enter to enable a reload.
|
||||||
|
if(hotReload) {
|
||||||
|
chokidar.watch('./out').on('all', (evt, path) => {
|
||||||
|
appendFileSync('log.log', evt + ' ' + path + '\n');
|
||||||
|
if(restartTimer) clearTimeout(restartTimer)
|
||||||
|
restartTimer = setTimeout(() => {
|
||||||
|
restart();
|
||||||
|
restartTimer = null;
|
||||||
|
}, 1000);
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
createWorker();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
async function begin() {
|
||||||
console.clear();
|
console.clear();
|
||||||
|
|
||||||
function gracefulShutdown() {
|
function gracefulShutdown() {
|
||||||
|
|
@ -22,10 +91,11 @@ function gracefulShutdown() {
|
||||||
}
|
}
|
||||||
console.log('exitting');
|
console.log('exitting');
|
||||||
process.stdout.write(ansi.cursor.show);
|
process.stdout.write(ansi.cursor.show);
|
||||||
|
|
||||||
process.exit(0);
|
process.exit(0);
|
||||||
}
|
}
|
||||||
process.on('exit', gracefulShutdown);
|
|
||||||
|
|
||||||
|
process.on('exit', gracefulShutdown);
|
||||||
|
|
||||||
const saveFile = process.argv[2] || 'data/world01.json';
|
const saveFile = process.argv[2] || 'data/world01.json';
|
||||||
|
|
||||||
|
|
@ -52,7 +122,7 @@ for(const path of extensions) {
|
||||||
console.log('Setup Complete.');
|
console.log('Setup Complete.');
|
||||||
|
|
||||||
|
|
||||||
for(let seconds = 0; seconds > 0; seconds --) {
|
for (let seconds = 2; seconds > 0; seconds--) {
|
||||||
process.stdout.write('Starting DF-Idle in ' + seconds + '\r');
|
process.stdout.write('Starting DF-Idle in ' + seconds + '\r');
|
||||||
await new Promise(res => setTimeout(res, 1000));
|
await new Promise(res => setTimeout(res, 1000));
|
||||||
}
|
}
|
||||||
|
|
@ -63,3 +133,5 @@ console.clear();
|
||||||
// isnt necessarily the entire thing, its just one instance of a save file.
|
// isnt necessarily the entire thing, its just one instance of a save file.
|
||||||
// But probably the initial menu screens will be their own thing entirely.
|
// But probably the initial menu screens will be their own thing entirely.
|
||||||
const game = Game.create(saveFile);
|
const game = Game.create(saveFile);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -1,13 +1,14 @@
|
||||||
import { Serializable } from 'frigid';
|
import { Serializable } from 'frigid';
|
||||||
import { getTheme } from '@themes';
|
import { getTheme } from '@themes';
|
||||||
import { Renderable } from '../ui/UI.js';
|
import { Renderable } from '@ui';
|
||||||
|
import { osrsNumber } from '../Util.js';
|
||||||
|
|
||||||
export type ItemID = string;
|
export type ItemID = string;
|
||||||
|
|
||||||
const items = new Map<ItemID, Item<any>>();
|
const items = new Map<ItemID, Item<any>>();
|
||||||
|
|
||||||
// ITEMS SHALL BE SINGULAR
|
// ITEMS SHALL BE SINGULAR
|
||||||
export class Item<Data = any> extends Serializable {
|
export class Item<Data = any> {
|
||||||
|
|
||||||
name = {
|
name = {
|
||||||
singular: '',
|
singular: '',
|
||||||
|
|
@ -77,7 +78,10 @@ export class ItemState<Data> extends Serializable implements Renderable {
|
||||||
}
|
}
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
return getTheme().normal(` ${this.item.name}{|}${this.qty} `);
|
return getTheme().normal(` ${osrsNumber(this.qty)} ${(() => {
|
||||||
|
if(this.qty === 1) return this.item.name.singular;
|
||||||
|
else return this.item.name.plural;
|
||||||
|
})()} `);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,6 @@ import EventEmitter from 'events';
|
||||||
import chalk from 'chalk';
|
import chalk from 'chalk';
|
||||||
import { Pawn } from '../Pawn.js';
|
import { Pawn } from '../Pawn.js';
|
||||||
import { Game } from '../Game.js';
|
import { Game } from '../Game.js';
|
||||||
import { panels } from '../ui/UI.js';
|
|
||||||
import { progressbar, ProgressbarStyle } from '../Progressbar.js';
|
import { progressbar, ProgressbarStyle } from '../Progressbar.js';
|
||||||
|
|
||||||
const tasks: Map<string, Task<unknown, unknown>> = new Map();
|
const tasks: Map<string, Task<unknown, unknown>> = new Map();
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@ import { Game } from "@game";
|
||||||
import { boxStyle, getTheme } from "@themes";
|
import { boxStyle, getTheme } from "@themes";
|
||||||
import { panels } from "@ui";
|
import { panels } from "@ui";
|
||||||
import blessed from 'neo-blessed';
|
import blessed from 'neo-blessed';
|
||||||
|
import { quit, restart } from "../index.js";
|
||||||
|
|
||||||
// TODO convert all these popup-y things to be View based
|
// TODO convert all these popup-y things to be View based
|
||||||
// make them be boxes that have a view
|
// make them be boxes that have a view
|
||||||
|
|
@ -9,6 +10,7 @@ export class EscapeMenu {
|
||||||
|
|
||||||
options = [
|
options = [
|
||||||
'RESUME',
|
'RESUME',
|
||||||
|
'RELOAD',
|
||||||
'QUIT'
|
'QUIT'
|
||||||
];
|
];
|
||||||
selected = 0;
|
selected = 0;
|
||||||
|
|
@ -22,7 +24,11 @@ export class EscapeMenu {
|
||||||
this.box = blessed.box({
|
this.box = blessed.box({
|
||||||
top: 3,
|
top: 3,
|
||||||
left: 'center',
|
left: 'center',
|
||||||
width: 30,
|
width: 20,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
height: 'shrink',
|
height: 'shrink',
|
||||||
content: '',
|
content: '',
|
||||||
tags: true,
|
tags: true,
|
||||||
|
|
@ -43,8 +49,12 @@ export class EscapeMenu {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 1: {
|
case 1: {
|
||||||
|
restart();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 2: {
|
||||||
Game.current.sync();
|
Game.current.sync();
|
||||||
process.exit(0);
|
quit();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else if(key.full === 'escape') {
|
} else if(key.full === 'escape') {
|
||||||
|
|
@ -60,9 +70,10 @@ export class EscapeMenu {
|
||||||
}
|
}
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
this.box.setContent(' Paused\n\n' + this.options.map((v, i) => {
|
const space = ' '.repeat(this.box.width / 2 - 4);
|
||||||
|
this.box.setContent(space + 'Paused\n\n' + this.options.map((v, i) => {
|
||||||
if(i === this.selected) {
|
if(i === this.selected) {
|
||||||
return ` ${getTheme().bright(v)} `;
|
return ` ❯ ${getTheme().bright(v)} `;
|
||||||
} else {
|
} else {
|
||||||
return ` ${getTheme().normal(v)} `;
|
return ` ${getTheme().normal(v)} `;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ import { ItemState } from '../registries/Items.js';
|
||||||
import { Player } from "../multiplayer/Player";
|
import { Player } from "../multiplayer/Player";
|
||||||
import { Pawn } from '../Pawn.js';
|
import { Pawn } from '../Pawn.js';
|
||||||
import { getTheme, boxStyle } from '@themes';
|
import { getTheme, boxStyle } from '@themes';
|
||||||
import { panels } from './UI.js';
|
import { panels } from '@ui';
|
||||||
|
|
||||||
export class GiftPopup {
|
export class GiftPopup {
|
||||||
box;
|
box;
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { Pawn } from '../Pawn.js';
|
import { Pawn } from '../Pawn.js';
|
||||||
import { panels, Renderable } from './UI.js';
|
import { panels, Renderable } from '@ui';
|
||||||
import { Game } from '../Game.js';
|
import { Game } from '../Game.js';
|
||||||
import { progressbar, stats } from '../Progressbar.js';
|
import { progressbar, stats } from '../Progressbar.js';
|
||||||
import { Popup } from './Popup.js';
|
import { Popup } from './Popup.js';
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ import { Game } from '../Game.js';
|
||||||
import { stringify } from '../Memory.js';
|
import { stringify } from '../Memory.js';
|
||||||
import { Pawn } from '../Pawn.js';
|
import { Pawn } from '../Pawn.js';
|
||||||
import Time from '../Time.js';
|
import Time from '../Time.js';
|
||||||
import { panels } from './UI.js';
|
import { panels } from '@ui';
|
||||||
import { boxStyle } from '@themes';
|
import { boxStyle } from '@themes';
|
||||||
|
|
||||||
export class PawnDetails {
|
export class PawnDetails {
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ import chalk from 'chalk';
|
||||||
import blessed from 'neo-blessed';
|
import blessed from 'neo-blessed';
|
||||||
import { Game } from '../Game.js';
|
import { Game } from '../Game.js';
|
||||||
import { boxStyle, getTheme } from '@themes';
|
import { boxStyle, getTheme } from '@themes';
|
||||||
import { panels } from './UI.js';
|
import { panels } from '@ui';
|
||||||
|
|
||||||
export class Popup {
|
export class Popup {
|
||||||
box;
|
box;
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { Renderable, RenderMode } from './UI.js';
|
import { Renderable, RenderMode } from '@ui';
|
||||||
import { KeypressAcceptor } from './Menu.js';
|
import { KeypressAcceptor } from './Menu.js';
|
||||||
import { getTheme } from '@themes';
|
import { getTheme } from '@themes';
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -29,15 +29,15 @@ export function isStarted() {
|
||||||
|
|
||||||
export const panels = {
|
export const panels = {
|
||||||
get left() {
|
get left() {
|
||||||
assertStarted()
|
assertStarted();
|
||||||
return leftPanel;
|
return leftPanel;
|
||||||
},
|
},
|
||||||
get right() {
|
get right() {
|
||||||
assertStarted()
|
assertStarted();
|
||||||
return rightPanel;
|
return rightPanel;
|
||||||
},
|
},
|
||||||
get screen() {
|
get screen() {
|
||||||
assertStarted()
|
assertStarted();
|
||||||
return screen;
|
return screen;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { Renderable } from './UI.js';
|
import { Renderable } from '@ui';
|
||||||
import { KeypressAcceptor } from './Menu.js';
|
import { KeypressAcceptor } from './Menu.js';
|
||||||
|
|
||||||
export abstract class View implements Renderable, KeypressAcceptor {
|
export abstract class View implements Renderable, KeypressAcceptor {
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ import { getTheme } from "@themes";
|
||||||
import { Game } from "../../Game.js";
|
import { Game } from "../../Game.js";
|
||||||
import { progressbar } from "../../Progressbar.js";
|
import { progressbar } from "../../Progressbar.js";
|
||||||
import { PawnDetails } from "../PawnDetails.js";
|
import { PawnDetails } from "../PawnDetails.js";
|
||||||
import { panels } from "../UI.js";
|
import { panels } from "@ui";
|
||||||
import { View } from "../View.js";
|
import { View } from "../View.js";
|
||||||
|
|
||||||
export default class PawnsView extends View {
|
export default class PawnsView extends View {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue