Event in lua (partial)
This commit is contained in:
@@ -8,10 +8,23 @@
|
||||
#pragma once
|
||||
#include "inputbutton.h"
|
||||
#include "inputaction.h"
|
||||
#include "event/event.h"
|
||||
|
||||
#define INPUT_LISTENER_PRESSED_MAX 16
|
||||
#define INPUT_LISTENER_RELEASED_MAX INPUT_LISTENER_PRESSED_MAX
|
||||
|
||||
typedef struct {
|
||||
const inputaction_t action;
|
||||
} inputevent_t;
|
||||
|
||||
typedef struct {
|
||||
inputactiondata_t actions[INPUT_ACTION_COUNT];
|
||||
|
||||
eventlistener_t pressedListeners[INPUT_LISTENER_PRESSED_MAX];
|
||||
event_t eventPressed;
|
||||
eventlistener_t releasedListeners[INPUT_LISTENER_RELEASED_MAX];
|
||||
event_t eventReleased;
|
||||
|
||||
#if INPUT_GAMEPAD == 1
|
||||
float_t deadzone;
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user