mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2025-01-12 20:18:59 +01:00
examples/gamepad: Always show signs for axis values
This commit is contained in:
parent
700052519c
commit
6b949cede8
@ -65,7 +65,7 @@ func (g *Game) Update() error {
|
||||
maxAxis := ebiten.GamepadAxisNum(id)
|
||||
for a := 0; a < maxAxis; a++ {
|
||||
v := ebiten.GamepadAxisValue(id, a)
|
||||
g.axes[id] = append(g.axes[id], fmt.Sprintf("%d:%0.2f", a, v))
|
||||
g.axes[id] = append(g.axes[id], fmt.Sprintf("%d:%+0.2f", a, v))
|
||||
}
|
||||
maxButton := ebiten.GamepadButton(ebiten.GamepadButtonNum(id))
|
||||
for b := ebiten.GamepadButton(id); b < maxButton; b++ {
|
||||
|
Loading…
Reference in New Issue
Block a user