WiiDuktape/source/game.js
Fries e9349f026a add grrlib.
also restructure the code so the js file has an update and start
function that gets called.
2024-06-19 21:08:16 -07:00

20 lines
322 B
JavaScript

const PAD_BUTTON_START = 0x1000;
const PAD_BUTTON_A = 0x0100;
function start() {
}
function update() {
const pressed = wii.pad.buttons_down();
if (pressed & PAD_BUTTON_START) {
wii.print("exiting from js");
wii.exit();
}
if (pressed & PAD_BUTTON_A) {
wii.print("a pressed");
}
wii.grrlib.fill_screen();
}