feat(#15): use new font in fps counter

This commit is contained in:
Juan Sebastián Montoya 2024-09-20 08:34:45 -05:00
parent ad3226de52
commit 36bebe5237

View file

@ -1,8 +1,8 @@
import { GameObject } from "./game-object.js";
export class FpsCounter extends GameObject {
constructor({ debug = false }) {
super({ debug });
constructor() {
super();
this.fps = 0;
}
@ -15,7 +15,7 @@ export class FpsCounter extends GameObject {
return;
}
ctx.fillStyle = "Red";
ctx.font = "normal 12pt Arial";
ctx.font = "normal 12pt Pixelify Sans";
ctx.fillText(this.fps + " fps", 5, 15);
}
}