Fixed buffer overflowing because of mouse input
This commit is contained in:
@ -120,9 +120,9 @@ void glfwOnKey(GLFWwindow *window,
|
||||
) {
|
||||
input_t *input = &GAME_STATE->engine.input;
|
||||
if(action == GLFW_PRESS) {
|
||||
input->buffer[key] = 1;
|
||||
input->buffer[(inputsource_t)key] = 1;
|
||||
} else if(action == GLFW_RELEASE) {
|
||||
input->buffer[key] = 0;
|
||||
input->buffer[(inputsource_t)key] = 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user