diff --git a/main.c b/main.c index 6218b78..e6131d7 100644 --- a/main.c +++ b/main.c @@ -12,12 +12,12 @@ int SCREEN_WIDTH = 1024; int SCREEN_HEIGHT = 768; -struct State { +typedef struct State { float camX; float camY; float px; float py; -}; +} State; void framebuffer_size_callback(GLFWwindow* window, int width, int height) { (void)window; @@ -26,7 +26,7 @@ void framebuffer_size_callback(GLFWwindow* window, int width, int height) { SCREEN_HEIGHT = height; } -void processInput(GLFWwindow *window, struct State* state) { +void processInput(GLFWwindow *window, State* state) { if (glfwGetKey(window, GLFW_KEY_ESCAPE) == GLFW_PRESS) { glfwSetWindowShouldClose(window, true); } @@ -141,7 +141,7 @@ int main(void) { // float deltaTime = 0.0f; // float lastFrame = 0.0f; - struct State state = {0}; + State state = {0}; int frameCount = 0; float elapsed = 0.0f; float lastFrame;