mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Making Block and Slots1-9 available for gamepad mapping
This commit is contained in:
parent
30c446f8ee
commit
3131c178d6
@ -66,6 +66,36 @@ impl From<&crate::settings::GamepadSettings> for ControllerSettings {
|
||||
map.entry(settings.game_buttons.secondary)
|
||||
.or_default()
|
||||
.push(GameInput::Secondary);
|
||||
map.entry(settings.game_buttons.block)
|
||||
.or_default()
|
||||
.push(GameInput::Block);
|
||||
map.entry(settings.game_buttons.slot1)
|
||||
.or_default()
|
||||
.push(GameInput::Slot1);
|
||||
map.entry(settings.game_buttons.slot2)
|
||||
.or_default()
|
||||
.push(GameInput::Slot2);
|
||||
map.entry(settings.game_buttons.slot3)
|
||||
.or_default()
|
||||
.push(GameInput::Slot3);
|
||||
map.entry(settings.game_buttons.slot4)
|
||||
.or_default()
|
||||
.push(GameInput::Slot4);
|
||||
map.entry(settings.game_buttons.slot5)
|
||||
.or_default()
|
||||
.push(GameInput::Slot5);
|
||||
map.entry(settings.game_buttons.slot6)
|
||||
.or_default()
|
||||
.push(GameInput::Slot6);
|
||||
map.entry(settings.game_buttons.slot7)
|
||||
.or_default()
|
||||
.push(GameInput::Slot7);
|
||||
map.entry(settings.game_buttons.slot8)
|
||||
.or_default()
|
||||
.push(GameInput::Slot8);
|
||||
map.entry(settings.game_buttons.slot9)
|
||||
.or_default()
|
||||
.push(GameInput::Slot9);
|
||||
map.entry(settings.game_buttons.toggle_cursor)
|
||||
.or_default()
|
||||
.push(GameInput::ToggleCursor);
|
||||
|
@ -47,6 +47,16 @@ pub mod con_settings {
|
||||
pub struct GameButtons {
|
||||
pub primary: Button,
|
||||
pub secondary: Button,
|
||||
pub block: Button,
|
||||
pub slot1: Button,
|
||||
pub slot2: Button,
|
||||
pub slot3: Button,
|
||||
pub slot4: Button,
|
||||
pub slot5: Button,
|
||||
pub slot6: Button,
|
||||
pub slot7: Button,
|
||||
pub slot8: Button,
|
||||
pub slot9: Button,
|
||||
pub toggle_cursor: Button,
|
||||
pub escape: Button,
|
||||
pub enter: Button,
|
||||
@ -140,6 +150,16 @@ 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),
|
||||
slot2: Button::Simple(GilButton::Unknown),
|
||||
slot3: Button::Simple(GilButton::Unknown),
|
||||
slot4: Button::Simple(GilButton::Unknown),
|
||||
slot5: Button::Simple(GilButton::Unknown),
|
||||
slot6: Button::Simple(GilButton::Unknown),
|
||||
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),
|
||||
enter: Button::Simple(GilButton::Unknown),
|
||||
|
Loading…
Reference in New Issue
Block a user