From 90a3c7765b684d109f48fec4723ffb11fa16b965 Mon Sep 17 00:00:00 2001 From: IntellectualKitty Date: Fri, 25 Nov 2016 21:00:37 -0700 Subject: [PATCH] Update events.c --- tests/events.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/tests/events.c b/tests/events.c index fa14ae11b..db405499d 100644 --- a/tests/events.c +++ b/tests/events.c @@ -463,17 +463,19 @@ static void joystick_callback(int jid, int event) { if (event == GLFW_CONNECTED) { - int axisCount, buttonCount; + int axisCount, buttonCount, hatCount; glfwGetJoystickAxes(jid, &axisCount); glfwGetJoystickButtons(jid, &buttonCount); + glfwGetJoystickHats(jid, &hatCount); - printf("%08x at %0.3f: Joystick %i (%s) was connected with %i axes and %i buttons\n", + printf("%08x at %0.3f: Joystick %i (%s) was connected with %i axes, %i buttons, and %i hats\n", counter++, glfwGetTime(), jid, glfwGetJoystickName(jid), axisCount, - buttonCount); + buttonCount, + hatCount); } else {