diff options
author | omnisci3nce <omniscient.oce@gmail.com> | 2024-07-12 12:47:07 +1000 |
---|---|---|
committer | omnisci3nce <omniscient.oce@gmail.com> | 2024-07-12 12:47:07 +1000 |
commit | f74cf52946f4e569a26bc81105537b40be95c2c7 (patch) | |
tree | 1d000367350d0e28eb7cfbc800286a0ed30a4e6c /src/systems/input.c | |
parent | fedba7ff68924ff50022405fc9103a5acf7013fe (diff) |
wip: big makeover
Diffstat (limited to 'src/systems/input.c')
-rw-r--r-- | src/systems/input.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/systems/input.c b/src/systems/input.c index 0c8f768..a371ecd 100644 --- a/src/systems/input.c +++ b/src/systems/input.c @@ -6,11 +6,11 @@ #include "log.h" -static input_state *g_input; // Use a global to simplify caller code +static Input_State *g_input; // Use a global to simplify caller code -bool input_system_init(input_state *input, GLFWwindow *window) { +bool Input_Init(Input_State *input, GLFWwindow *window) { INFO("Input init"); - memset(input, 0, sizeof(input_state)); + memset(input, 0, sizeof(Input_State)); input->window = window; // Set everything to false. Could just set memory to zero but where's the fun in that @@ -29,9 +29,9 @@ bool input_system_init(input_state *input, GLFWwindow *window) { return true; } -void input_system_shutdown(input_state *input) {} +void Input_Shutdown(Input_State *input) {} -void input_update(input_state *input) { +void Input_Update(Input_State *input) { glfwPollEvents(); // --- update keyboard input @@ -95,4 +95,4 @@ bool key_is_pressed(keycode key) { return g_input->depressed_keys[key]; } bool key_just_pressed(keycode key) { return g_input->just_pressed_keys[key]; } -bool key_just_released(keycode key) { return g_input->just_released_keys[key]; }
\ No newline at end of file +bool key_just_released(keycode key) { return g_input->just_released_keys[key]; } |