Mapped Pokégear to Back button on controllers
And enabling/disabling controller input to F6
This commit is contained in:
parent
2d92359734
commit
f5143a710a
Binary file not shown.
After Width: | Height: | Size: 6.6 KiB |
|
@ -49,7 +49,7 @@
|
|||
End If
|
||||
End If
|
||||
|
||||
If ControllerHandler.ButtonPressed(Buttons.Back, True) = True Then
|
||||
If KeyBoardHandler.KeyPressed(KeyBindings.DisableControllerKey) = True Then
|
||||
Core.GameOptions.GamePadEnabled = Not Core.GameOptions.GamePadEnabled
|
||||
If Core.GameOptions.GamePadEnabled Then
|
||||
Core.GameMessage.ShowMessage("Enabled XBOX 360 GamePad support.", 12, FontManager.MainFont, Color.White)
|
||||
|
|
|
@ -24,6 +24,7 @@ Public Class KeyBindings
|
|||
Public Shared DebugKey As Keys = Keys.F3
|
||||
Public Shared LightKey As Keys = Keys.F4
|
||||
Public Shared PerspectiveSwitchKey As Keys = Keys.F5
|
||||
Public Shared DisableControllerKey As Keys = Keys.F6
|
||||
Public Shared FullScreenKey As Keys = Keys.F11
|
||||
Public Shared DebugWalkKey As Keys = Keys.LeftControl
|
||||
|
||||
|
@ -257,6 +258,7 @@ Public Class KeyBindings
|
|||
"[DebugWalkKey]=" & GetKeyName(Keys.LeftControl) & Environment.NewLine &
|
||||
"[LightKey]=" & GetKeyName(Keys.F4) & Environment.NewLine &
|
||||
"[PerspectiveSwitch]=" & GetKeyName(Keys.F5) & Environment.NewLine &
|
||||
"[DisableController]=" & GetKeyName(Keys.F6) & Environment.NewLine &
|
||||
"[FullScreen]=" & GetKeyName(Keys.F11) & Environment.NewLine &
|
||||
"[Enter1]=" & GetKeyName(Keys.Enter) & Environment.NewLine &
|
||||
"[Enter2]=" & GetKeyName(Keys.Space) & Environment.NewLine &
|
||||
|
@ -293,6 +295,7 @@ Public Class KeyBindings
|
|||
"[DebugControl]=" & GetKeyName(DebugKey) & Environment.NewLine &
|
||||
"[LightKey]=" & GetKeyName(LightKey) & Environment.NewLine &
|
||||
"[PerspectiveSwitch]=" & GetKeyName(PerspectiveSwitchKey) & Environment.NewLine &
|
||||
"[DisableController]=" & GetKeyName(DisableControllerKey) & Environment.NewLine &
|
||||
"[FullScreen]=" & GetKeyName(FullScreenKey) & Environment.NewLine &
|
||||
"[Enter1]=" & GetKeyName(EnterKey1) & Environment.NewLine &
|
||||
"[Enter2]=" & GetKeyName(EnterKey2) & Environment.NewLine &
|
||||
|
|
|
@ -234,7 +234,7 @@ Public Class OverworldScreen
|
|||
End If
|
||||
|
||||
'Open the PokégearScreen:
|
||||
If KeyBoardHandler.KeyPressed(KeyBindings.SpecialKey) = True Or ControllerHandler.ButtonPressed(Buttons.Y) = True Then
|
||||
If KeyBoardHandler.KeyPressed(KeyBindings.SpecialKey) = True Or ControllerHandler.ButtonPressed(Buttons.Back) = True Then
|
||||
If NotificationPopupList.Count > 0 Then
|
||||
NotificationPopupList(0).Dismiss()
|
||||
Else
|
||||
|
@ -381,7 +381,7 @@ Public Class OverworldScreen
|
|||
|
||||
d.Add(Buttons.X, Localization.GetString("game_interaction_gamemenu", "Game Menu"))
|
||||
If Core.Player.HasPokegear = True Then
|
||||
d.Add(Buttons.Y, Localization.GetString("game_interaction_pokegear", "Pokégear"))
|
||||
d.Add(Buttons.Back, Localization.GetString("game_interaction_pokegear", "Pokégear"))
|
||||
End If
|
||||
d.Add(Buttons.Start, Localization.GetString("game_interaction_pausemenu", "Game Menu"))
|
||||
|
||||
|
|
|
@ -11018,6 +11018,9 @@
|
|||
<Content Include="Content\Data\smashrockitems.dat">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
</Content>
|
||||
<Content Include="Content\GUI\GamePad\xboxControllerBack.png">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
</Content>
|
||||
<Content Include="Content\GUI\MainMenu\clouds.png">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
</Content>
|
||||
|
|
|
@ -317,7 +317,7 @@ Public MustInherit Class Screen
|
|||
'Loop through the buttons and add to the x location.
|
||||
For i = 0 To Descriptions.Count - 1
|
||||
Select Case Descriptions.Keys(i)
|
||||
Case Buttons.A, Buttons.B, Buttons.X, Buttons.Y, Buttons.Start, Buttons.LeftStick, Buttons.RightStick, Buttons.LeftTrigger, Buttons.RightTrigger
|
||||
Case Buttons.A, Buttons.B, Buttons.X, Buttons.Y, Buttons.Start, Buttons.Back, Buttons.LeftStick, Buttons.RightStick, Buttons.LeftTrigger, Buttons.RightTrigger
|
||||
x -= 32 + 4
|
||||
Case Buttons.LeftShoulder, Buttons.RightShoulder
|
||||
x -= 64 + 4
|
||||
|
@ -373,6 +373,8 @@ Public MustInherit Class Screen
|
|||
t &= "RightTrigger"
|
||||
Case Buttons.Start
|
||||
t &= "Start"
|
||||
Case Buttons.Back
|
||||
t &= "Back"
|
||||
End Select
|
||||
|
||||
'Draw the buttons (first, the "shadow" with a black color, then the real button).
|
||||
|
|
Loading…
Reference in New Issue