Files
Sandbox/src/main.c
2026-03-29 23:04:49 -05:00

30 lines
404 B
C

#include <stdio.h>
#include "SDL2/SDL.h"
#include "game.h"
#include "input.h"
int main(int argc, char* argv[])
{
printf("Starting...\n");
GameState *gs = Game_New();
if (gs == NULL)
{
printf("Failed to start.\n");
return 1;
}
while (gs->running)
{
Input_Poll(gs);
Game_Update(gs);
}
printf("Shutting down...\n");
Game_Destroy(gs);
SDL_Quit();
printf("Done.\n");
return 0;
}