General improvements

I forgot what I actually changed. It may not even be playable, I just want to get this up there.
This commit is contained in:
Asraelite 2023-03-31 11:43:56 +02:00
parent 8a0bf0ada9
commit c73130e3ff
25 changed files with 584 additions and 274 deletions

View file

@ -132,6 +132,20 @@ export function game() {
ship.maxFuel.toFixed(1);
};
let speed = new GuiText('', 0, 0, 0, 0, {
size: 14,
align: 'right',
valign: 'bottom',
});
shadow.append(speed);
speed.posRelative({x: 1, y: 1});
speed.y -= 30;
speed.x -= 10;
speed.tick = () => {
speed.text = 'Speed: ' + world.speed.toFixed(1) + 'x';
};
let score = new GuiText('', 0, 0, 0, 0, {
size: 14,
align: 'left',

View file

@ -16,7 +16,7 @@ export default class GuiText extends GuiElement {
this.color = color;
this.text = text;
this.spacing = size * 1.2;
this.font = size + 'px Consolas';
this.font = size + 'px Courier New';
this.align = align;
this.valign = valign;
}