mirror of
https://github.com/jugeeya/UltimateTrainingModpack.git
synced 2025-02-17 14:40:31 +00:00
Update button_config.rs
This commit is contained in:
parent
5920e011b6
commit
862253b52a
1 changed files with 0 additions and 108 deletions
|
@ -49,114 +49,6 @@ pub fn button_mapping(
|
|||
}
|
||||
}
|
||||
|
||||
pub fn name_to_font_glyph(button: ButtonConfig, style: ControllerStyle) -> Option<u16> {
|
||||
let is_gcc = style == ControllerStyle::GCController;
|
||||
Some(match button {
|
||||
ButtonConfig::A => 0xE0E0,
|
||||
// TODO: Find one that works in training...
|
||||
ButtonConfig::B => 0xE0E0,
|
||||
ButtonConfig::X => {
|
||||
if is_gcc {
|
||||
0xE206
|
||||
} else {
|
||||
0xE0E2
|
||||
}
|
||||
}
|
||||
ButtonConfig::Y => {
|
||||
if is_gcc {
|
||||
0xE207
|
||||
} else {
|
||||
0xE0E3
|
||||
}
|
||||
}
|
||||
ButtonConfig::L => {
|
||||
if is_gcc {
|
||||
return None;
|
||||
} else {
|
||||
0xE0E4
|
||||
}
|
||||
}
|
||||
ButtonConfig::R => {
|
||||
if is_gcc {
|
||||
0xE205
|
||||
} else {
|
||||
0xE0E5
|
||||
}
|
||||
}
|
||||
ButtonConfig::ZL => {
|
||||
if is_gcc {
|
||||
0xE204
|
||||
} else {
|
||||
0xE0E6
|
||||
}
|
||||
}
|
||||
ButtonConfig::ZR => {
|
||||
if is_gcc {
|
||||
0xE208
|
||||
} else {
|
||||
0xE0E7
|
||||
}
|
||||
}
|
||||
ButtonConfig::DPAD_UP => {
|
||||
if is_gcc {
|
||||
0xE209
|
||||
} else {
|
||||
0xE079
|
||||
}
|
||||
}
|
||||
ButtonConfig::DPAD_DOWN => {
|
||||
if is_gcc {
|
||||
0xE20A
|
||||
} else {
|
||||
0xE07A
|
||||
}
|
||||
}
|
||||
ButtonConfig::DPAD_LEFT => {
|
||||
if is_gcc {
|
||||
0xE20B
|
||||
} else {
|
||||
0xE07B
|
||||
}
|
||||
}
|
||||
ButtonConfig::DPAD_RIGHT => {
|
||||
if is_gcc {
|
||||
0xE20C
|
||||
} else {
|
||||
0xE07C
|
||||
}
|
||||
}
|
||||
ButtonConfig::PLUS => {
|
||||
if is_gcc {
|
||||
0xE20D
|
||||
} else {
|
||||
0xE0EF
|
||||
}
|
||||
}
|
||||
ButtonConfig::MINUS => {
|
||||
if is_gcc {
|
||||
return None;
|
||||
} else {
|
||||
0xE0F0
|
||||
}
|
||||
}
|
||||
ButtonConfig::LSTICK => {
|
||||
if is_gcc {
|
||||
return None;
|
||||
} else {
|
||||
0xE104
|
||||
}
|
||||
}
|
||||
ButtonConfig::RSTICK => {
|
||||
if is_gcc {
|
||||
return None;
|
||||
} else {
|
||||
0xE105
|
||||
}
|
||||
}
|
||||
_ => return None,
|
||||
})
|
||||
}
|
||||
|
||||
#[derive(Debug, EnumIter, PartialEq, Eq, Hash, Copy, Clone)]
|
||||
pub enum ButtonCombo {
|
||||
OpenMenu,
|
||||
|
|
Loading…
Reference in a new issue