Skip to content

Commit 468bd17

Browse files
authored
fix: update input manager example to use ControllerSticks instead of ControllerAxes (#2873)
1 parent fa042e6 commit 468bd17

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

arcade/experimental/input_manager_example.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
Example for handling input using the Arcade InputManager
44
55
If Python and Arcade are installed, this example can be run from the command line with:
6-
python -m arcade.examples.input_manager
6+
python -m arcade.experimental.input_manager_example
77
"""
88

99
import random
@@ -13,7 +13,7 @@
1313
from pyglet.input import Controller
1414

1515
import arcade
16-
from arcade.input import ActionState, ControllerAxes, ControllerButtons, InputManager, Keys
16+
from arcade.input import ActionState, ControllerSticks, ControllerButtons, InputManager, Keys
1717

1818
WINDOW_WIDTH = 1280
1919
WINDOW_HEIGHT = 720
@@ -112,7 +112,7 @@ def __init__(
112112
self.INPUT_TEMPLATE.new_axis("Move")
113113
self.INPUT_TEMPLATE.add_axis_input("Move", Keys.A, -1.0)
114114
self.INPUT_TEMPLATE.add_axis_input("Move", Keys.D, 1.0)
115-
self.INPUT_TEMPLATE.add_axis_input("Move", ControllerAxes.LEFT_STICK_X)
115+
self.INPUT_TEMPLATE.add_axis_input("Move", ControllerSticks.LEFT_STICK_X)
116116

117117
# This is an example of how to dump an InputManager to a file. The serialize function
118118
# returns a dictionary, so anything such as toml, yaml, or json could be used to save

0 commit comments

Comments
 (0)