Cleaned some code, drastically reduced memory footprint.

This commit is contained in:
2021-09-05 15:02:02 -07:00
parent cb447a6033
commit 2285568480
19 changed files with 263 additions and 108 deletions

View File

@ -9,29 +9,20 @@
/** Debug Inputs */
#define INPUT_NULL (inputbind_t)0x00
#define INPUT_DEBUG_UP (inputbind_t)0x01
#define INPUT_DEBUG_DOWN (inputbind_t)0x02
#define INPUT_DEBUG_LEFT (inputbind_t)0x03
#define INPUT_DEBUG_RIGHT (inputbind_t)0x04
#define INPUT_DEBUG_RAISE (inputbind_t)0x05
#define INPUT_DEBUG_LOWER (inputbind_t)0x06
#define INPUT_DEBUG_FINE (inputbind_t)0x07
#define INPUT_DEBUG_PLUS (inputbind_t)0x08
#define INPUT_DEBUG_MINUS (inputbind_t)0x09
/** Real Inputs (Starts at 64/0x40) */
#define INPUT_UP (inputbind_t)0x40
#define INPUT_DOWN (inputbind_t)0x41
#define INPUT_LEFT (inputbind_t)0x42
#define INPUT_RIGHT (inputbind_t)0x43
#define INPUT_ACCEPT (inputbind_t)0x44
/** Real Inputs (Starts at 32/0x20) */
#define INPUT_UP (inputbind_t)0x20
#define INPUT_DOWN (inputbind_t)0x21
#define INPUT_LEFT (inputbind_t)0x22
#define INPUT_RIGHT (inputbind_t)0x23
#define INPUT_ACCEPT (inputbind_t)0x24
/** Additional sources */
#define INPUT_MOUSE_X (inputsource_t)0x20
#define INPUT_MOUSE_Y (inputsource_t)0x21
#define INPUT_MOUSE_X (inputsource_t)0x10
#define INPUT_MOUSE_Y (inputsource_t)0x11
#define INPUT_BIND_COUNT 0xFF
#define INPUT_SOURCE_COUNT 0xFFFF
#define INPUT_BIND_COUNT 0x40
#define INPUT_SOURCE_COUNT 0xFF
/**
* Input Bind, a specific action bind reference for the game engine to use.
@ -44,7 +35,7 @@ typedef uint8_t inputbind_t;
* hell this number refers to. For most platforms it will be an input, such as a
* keyboard scancode or a (pad number * button count) + button.
*/
typedef uint16_t inputsource_t;
typedef uint8_t inputsource_t;
/**
* Value that represents the state of an input. Defined as 0-1 where 0 is set