townengine/include/twn_input.h

30 lines
860 B
C

#ifndef TWN_INPUT_H
#define TWN_INPUT_H
#include "twn_config.h"
#include "twn_types.h"
#include "twn_engine_api.h"
#include "twn_control.h"
#include <stdint.h>
#include <stdbool.h>
#include <stddef.h>
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);
TWN_API void input_add_action(const char *action_name);
TWN_API void input_delete_action(const char *action_name);
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);
TWN_API Vec2 input_get_action_position(const char *action_name);
TWN_API void input_set_mouse_captured(bool enabled);
TWN_API bool input_is_mouse_captured(void);
#endif