[oden] Time, path searching, game directory

This commit is contained in:
John Doty 2023-06-30 16:24:54 -07:00
parent 96e95e22ce
commit 26bfcc7a94
8 changed files with 185 additions and 13 deletions

View file

@ -1,22 +0,0 @@
import { cls, print, spr, use_texture } from "./graphics.ts";
import { load_texture } from "./assets.ts";
let the_texture: number | undefined = undefined;
export function init() {
print("Hello world!");
// Start this load, but then...
load_texture("./src/happy-tree.png").then((n) => (the_texture = n));
}
export function update() {}
export function draw() {
cls(0.1, 0.2, 0.3);
if (the_texture != undefined) {
// ...it gets resolved here?
use_texture(the_texture);
spr((320 - 256) / 2, 0, 256, 240, 0, 0);
}
}