made them public
parent
70d598bf13
commit
fe95327ca8
|
@ -4,7 +4,9 @@ use gilrs::ev::Button;
|
||||||
///
|
///
|
||||||
use serde::{Deserialize, Serialize};
|
use serde::{Deserialize, Serialize};
|
||||||
#[derive(Deserialize, Serialize)]
|
#[derive(Deserialize, Serialize)]
|
||||||
pub struct Configs {}
|
pub struct Configs {
|
||||||
|
input: InputConfigs,
|
||||||
|
}
|
||||||
|
|
||||||
#[derive(Deserialize, Serialize)]
|
#[derive(Deserialize, Serialize)]
|
||||||
pub struct DisplayConfigs {
|
pub struct DisplayConfigs {
|
||||||
|
@ -18,34 +20,34 @@ pub struct InputConfigs {
|
||||||
keyboard_single: KeyboardConfig,
|
keyboard_single: KeyboardConfig,
|
||||||
//Keyboard_duo_1: KeyboardConfig,
|
//Keyboard_duo_1: KeyboardConfig,
|
||||||
// keyboard_duo_2: KeyboardConfig
|
// keyboard_duo_2: KeyboardConfig
|
||||||
Controller1: Option<ControllerConfig>,
|
pub Controller1: Option<ControllerConfig>,
|
||||||
Controller2: Option<ControllerConfig>,
|
pub Controller2: Option<ControllerConfig>,
|
||||||
Controller3: Option<ControllerConfig>,
|
pub Controller3: Option<ControllerConfig>,
|
||||||
Controller4: Option<ControllerConfig>,
|
pub Controller4: Option<ControllerConfig>,
|
||||||
Controller5: Option<ControllerConfig>,
|
pub Controller5: Option<ControllerConfig>,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Deserialize, Serialize, Debug)]
|
#[derive(Deserialize, Serialize, Debug)]
|
||||||
pub struct ControllerConfig {
|
pub struct ControllerConfig {
|
||||||
// directionals
|
// directionals
|
||||||
Up: Button,
|
pub Up: Button,
|
||||||
Down: Button,
|
pub Down: Button,
|
||||||
Right: Button,
|
pub Right: Button,
|
||||||
Left: Button,
|
pub Left: Button,
|
||||||
|
|
||||||
// the punches
|
// the punches
|
||||||
LightPunch: Button,
|
pub LightPunch: Button,
|
||||||
MediumPunch: Button,
|
pub MediumPunch: Button,
|
||||||
HeavyPunch: Button,
|
pub HeavyPunch: Button,
|
||||||
|
|
||||||
// the kicks
|
// the kicks
|
||||||
LightKick: Button,
|
pub LightKick: Button,
|
||||||
MediumKick: Button,
|
pub MediumKick: Button,
|
||||||
HeavyKick: Button,
|
pub HeavyKick: Button,
|
||||||
|
|
||||||
// Macros
|
// Macros
|
||||||
PunchMacro: Option<Button>,
|
pub PunchMacro: Option<Button>,
|
||||||
KickMacro: Option<Button>,
|
pub KickMacro: Option<Button>,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Default for ControllerConfig {
|
impl Default for ControllerConfig {
|
||||||
|
@ -72,24 +74,24 @@ impl Default for ControllerConfig {
|
||||||
#[derive(Deserialize, Serialize, Debug)]
|
#[derive(Deserialize, Serialize, Debug)]
|
||||||
pub struct KeyboardConfig {
|
pub struct KeyboardConfig {
|
||||||
// directionals
|
// directionals
|
||||||
Up: ScanCodes,
|
pub Up: ScanCodes,
|
||||||
Down: ScanCodes,
|
pub Down: ScanCodes,
|
||||||
Right: ScanCodes,
|
pub Right: ScanCodes,
|
||||||
Left: ScanCodes,
|
pub Left: ScanCodes,
|
||||||
|
|
||||||
// the punches
|
// the punches
|
||||||
LightPunch: ScanCodes,
|
pub LightPunch: ScanCodes,
|
||||||
MediumPunch: ScanCodes,
|
pub MediumPunch: ScanCodes,
|
||||||
HeavyPunch: ScanCodes,
|
pub HeavyPunch: ScanCodes,
|
||||||
|
|
||||||
// the kicks
|
// the kicks
|
||||||
LightKick: ScanCodes,
|
pub LightKick: ScanCodes,
|
||||||
MediumKick: ScanCodes,
|
pub MediumKick: ScanCodes,
|
||||||
HeavyKick: ScanCodes,
|
pub HeavyKick: ScanCodes,
|
||||||
|
|
||||||
// Macros
|
// Macros
|
||||||
PunchMacro: Option<ScanCodes>,
|
pub PunchMacro: Option<ScanCodes>,
|
||||||
KickMacro: Option<ScanCodes>,
|
pub KickMacro: Option<ScanCodes>,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Default for KeyboardConfig {
|
impl Default for KeyboardConfig {
|
||||||
|
|
Loading…
Reference in New Issue