Merge branch 'flo666/change-gamepad-mapping' into 'master'

change gamepad mapping

See merge request veloren/veloren!2841
This commit is contained in:
Dominik Broński 2021-09-30 18:48:42 +00:00
commit 382bc2f9da
2 changed files with 13 additions and 8 deletions

View File

@ -96,6 +96,9 @@ impl From<&crate::settings::GamepadSettings> for ControllerSettings {
map.entry(settings.game_buttons.slot9)
.or_default()
.push(GameInput::Slot9);
map.entry(settings.game_buttons.slot10)
.or_default()
.push(GameInput::Slot10);
map.entry(settings.game_buttons.toggle_cursor)
.or_default()
.push(GameInput::ToggleCursor);

View File

@ -57,6 +57,7 @@ pub mod con_settings {
pub slot7: Button,
pub slot8: Button,
pub slot9: Button,
pub slot10: Button,
pub toggle_cursor: Button,
pub escape: Button,
pub enter: Button,
@ -150,8 +151,8 @@ pub mod con_settings {
Self {
primary: Button::Simple(GilButton::RightTrigger2),
secondary: Button::Simple(GilButton::LeftTrigger2),
block: Button::Simple(GilButton::Unknown),
slot1: Button::Simple(GilButton::Unknown),
block: Button::Simple(GilButton::LeftThumb),
slot1: Button::Simple(GilButton::RightThumb),
slot2: Button::Simple(GilButton::Unknown),
slot3: Button::Simple(GilButton::Unknown),
slot4: Button::Simple(GilButton::Unknown),
@ -160,8 +161,9 @@ pub mod con_settings {
slot7: Button::Simple(GilButton::Unknown),
slot8: Button::Simple(GilButton::Unknown),
slot9: Button::Simple(GilButton::Unknown),
toggle_cursor: Button::Simple(GilButton::Unknown),
escape: Button::Simple(GilButton::Start),
slot10: Button::Simple(GilButton::DPadDown),
toggle_cursor: Button::Simple(GilButton::DPadRight),
escape: Button::Simple(GilButton::Select),
enter: Button::Simple(GilButton::Unknown),
command: Button::Simple(GilButton::Unknown),
move_forward: Button::Simple(GilButton::Unknown),
@ -179,12 +181,12 @@ pub mod con_settings {
sneak: Button::Simple(GilButton::East),
toggle_lantern: Button::Simple(GilButton::DPadLeft),
mount: Button::Simple(GilButton::North),
map: Button::Simple(GilButton::Select),
bag: Button::Simple(GilButton::DPadRight),
map: Button::Simple(GilButton::Start),
bag: Button::Simple(GilButton::Unknown),
quest_log: Button::Simple(GilButton::Unknown),
character_window: Button::Simple(GilButton::Unknown),
social: Button::Simple(GilButton::Unknown),
crafting: Button::Simple(GilButton::DPadDown),
crafting: Button::Simple(GilButton::Unknown),
spellbook: Button::Simple(GilButton::Unknown),
settings: Button::Simple(GilButton::Unknown),
help: Button::Simple(GilButton::Unknown),
@ -200,7 +202,7 @@ pub mod con_settings {
respawn: Button::Simple(GilButton::South),
interact: Button::Simple(GilButton::North),
toggle_wield: Button::Simple(GilButton::West),
swap_loadout: Button::Simple(GilButton::LeftThumb),
swap_loadout: Button::Simple(GilButton::DPadUp),
}
}
}