revert changed them to scancodes
Milk.H 2024-05-07 11:06:08 +02:00
parent ec8b0ccf75
commit 8c74c0f771
1 changed files with 12 additions and 13 deletions

View File

@ -20,24 +20,24 @@ pub struct InputConfigs {}
#[derive(Deserialize, Serialize)] #[derive(Deserialize, Serialize)]
pub struct KeyboardConfig { pub struct KeyboardConfig {
// directionals // directionals
Up: ScanCodes, Up: u32,
Down: ScanCodes, Down: u32,
Right: ScanCodes, Right: u32,
Left: ScanCodes, Left: u32,
// the punches // the punches
LightPunch: ScanCodes, LightPunch: u32,
MediumPunch: ScanCodes, MediumPunch: u32,
HeavyPunch: ScanCodes, HeavyPunch: u32,
// the kicks // the kicks
LightKick: ScanCodes, LightKick: u32,
MediumKick: ScanCodes, MediumKick: u32,
HeavyKick: ScanCodes, HeavyKick: u32,
// Macros // Macros
PunchMacro: ScanCodes, PunchMacro: u32,
KickMacro: ScanCodes, KickMacro: u32,
} }
impl Default for KeyboardConfig { impl Default for KeyboardConfig {
@ -64,7 +64,6 @@ impl Default for KeyboardConfig {
/// TODO finish this /// TODO finish this
/// UNTESTED AND UNFINISHED /// UNTESTED AND UNFINISHED
#[repr(u32)] #[repr(u32)]
#[derive(Deserialize, Serialize)]
pub enum ScanCodes { pub enum ScanCodes {
Escape = 0x01, Escape = 0x01,
Key1 = 0x02, Key1 = 0x02,