better menu screen
[gbajam22] / src / gba / main.c
index a520caf..925aebf 100644 (file)
@@ -4,6 +4,8 @@
 #include "debug.h"
 #include "game.h"
 #include "maxmod.h"
+#include "input.h"
+#include "xgl.h"
 
 static void vblank(void);
 
@@ -32,12 +34,14 @@ int main(void)
        REG_DISPSTAT |= DISPSTAT_IEN_VBLANK;
        unmask(INTR_VBLANK);
 
+       xgl_init();
+
        if(init_screens() == -1) {
                panic(get_pc(), "failed to initialize screens");
        }
 
        if(change_screen(find_screen("game")) == -1) {
-               panic(get_pc(), "failed to find game screen");
+               panic(get_pc(), "failed to find starting screen");
        }
 
        intr_enable();
@@ -53,6 +57,7 @@ static void vblank(void)
 {
        vblperf_count++;
 
+       keyb_vblank();
        curscr->vblank();
 
 #ifndef NOSOUND