use c64 font

This commit is contained in:
Chris Wanstrath 2025-09-28 18:34:18 -07:00
parent 0ec9edd595
commit de990f312d

View File

@ -10,7 +10,7 @@ export class GameContext {
this.ctx.clearRect(0, 0, this.ctx.canvas.width, this.ctx.canvas.height) this.ctx.clearRect(0, 0, this.ctx.canvas.width, this.ctx.canvas.height)
} }
text(msg: string, x: number, y: number, color = "black", size = 16, font = "monospace") { text(msg: string, x: number, y: number, color = "black", size = 16, font = "C64ProMono") {
const c = this.ctx const c = this.ctx
c.save() c.save()
c.fillStyle = color c.fillStyle = color
@ -20,7 +20,7 @@ export class GameContext {
c.restore() c.restore()
} }
centerText(msg: string, y: number, color = "black", size = 16, font = "monospace") { centerText(msg: string, y: number, color = "black", size = 16, font = "C64ProMono") {
const c = this.ctx const c = this.ctx
c.save() c.save()
c.fillStyle = color c.fillStyle = color