#include #include #include #include"mino.h" #include"graph.h" #include"scene.h" #include"input.h" #include"core.h" _ V game_loop(F64 dt){/*prelude*/graph_before(),graph_events();InputPoint p;InputButtons b; /*interlude*/ input_update(),p=input_point,b=input_buttons; core_tick(p,b,dt); /*postlude*/ graph_after();} _ Scene*game_run(V){U64 prev,now;core_init();prev=SDL_GetPerformanceCounter(); WH(1,now=SDL_GetPerformanceCounter(),game_loop((now-prev)/(F64)SDL_GetPerformanceFrequency()),prev=now);R 0;} Scene scene_game={"Game",game_run}; _ Scene*title_run(V){R&scene_game;} Scene scene_title={"Title",title_run}; I main(I ac,C**av){(V)ac,(V)av; graph_init(),atexit(graph_deinit); scene_run(&scene_title); R 0;}