mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-12-26 11:48:55 +01:00
internal/gamepad: bug fix: Y axis values are opposite on Xbox
Updates #2084
This commit is contained in:
parent
b31ce0a568
commit
c14403f195
@ -162,11 +162,11 @@ func (n *nativeGamepadXbox) axisValue(axis int) float64 {
|
|||||||
case gamepaddb.StandardAxisLeftStickHorizontal:
|
case gamepaddb.StandardAxisLeftStickHorizontal:
|
||||||
return float64(n.state.leftThumbstickX)
|
return float64(n.state.leftThumbstickX)
|
||||||
case gamepaddb.StandardAxisLeftStickVertical:
|
case gamepaddb.StandardAxisLeftStickVertical:
|
||||||
return float64(n.state.leftThumbstickY)
|
return -float64(n.state.leftThumbstickY)
|
||||||
case gamepaddb.StandardAxisRightStickHorizontal:
|
case gamepaddb.StandardAxisRightStickHorizontal:
|
||||||
return float64(n.state.rightThumbstickX)
|
return float64(n.state.rightThumbstickX)
|
||||||
case gamepaddb.StandardAxisRightStickVertical:
|
case gamepaddb.StandardAxisRightStickVertical:
|
||||||
return float64(n.state.rightThumbstickY)
|
return -float64(n.state.rightThumbstickY)
|
||||||
}
|
}
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user