townengine/include/twn_input.h

29 lines
836 B
C
Raw Permalink Normal View History

#ifndef TWN_INPUT_H
#define TWN_INPUT_H
2024-07-08 00:44:20 +00:00
#include "twn_types.h"
#include "twn_engine_api.h"
#include "twn_control.h"
2024-07-08 00:44:20 +00:00
#include <stdint.h>
#include <stdbool.h>
#include <stddef.h>
2024-07-08 00:44:20 +00:00
TWN_API void input_bind_action_control(const char *action_name, Control control);
TWN_API void input_unbind_action_control(const char *action_name, Control control);
2024-07-08 00:44:20 +00:00
TWN_API void input_add_action(const char *action_name);
TWN_API void input_delete_action(const char *action_name);
2024-07-08 00:44:20 +00:00
TWN_API bool input_is_action_pressed(const char *action_name);
TWN_API bool input_is_action_just_pressed(const char *action_name);
TWN_API bool input_is_action_just_released(const char *action_name);
2024-07-08 00:44:20 +00:00
TWN_API Vec2 input_get_action_position(const char *action_name);
2024-07-30 21:05:28 +00:00
TWN_API void input_set_mouse_captured(bool enabled);
TWN_API bool input_is_mouse_captured(void);
2024-07-08 00:44:20 +00:00
#endif