コード例 #1
0
ファイル: game.c プロジェクト: jerryxzhang/Kernel-Sanders
/* This is the entry-point for the game! */
void c_start(void) {
    /* Initialize our interrupt vector. */
    init_interrupts();
    
    /* Initialize peripherals. */
    init_keyboard();
    
    /* Initialize timers. */
    init_timer();

    display_background();
    game_started = 0;
    game_lost = 0;

	/* After setting up the game, we can enable interrupts again so the game
	 * can run as expected. */
	enable_interrupts();
	

    /* Loop forever, so that we don't fall back into the bootloader code. */
    while (1) {
    }
}
コード例 #2
0
ファイル: sdl.cpp プロジェクト: jsthibault/cpp_nibbler
void
sdl::refresh(map_t const &map)
{
  display_background();
  display_items(map);
}