Reference for get_trigger
Get a discrete input for a joystick-like device. This is part of the reference section.
Arc
Buffer
Data
Dialog
Ellipse
Geo Utils
Image
Joystick (future)
get_trigger
Keyboard
Line
Mouse / Touchscreen
Pixel
Rectangle
Renderers
Shape
Sound (future)
Style
System
Text
Transform
Purpose
Get a "discrete input" for a joystick-like device which includes push buttons and hats. Sketchingpy refers to these as "triggers" on the device. For example, "push0" refers to the first push button on the device.
Snippet
Get the state of a push button.
joysticks = sketch.get_joysticks()() first_joystick = joysticks[0] push_button = first_joystick.get_trigger('push0')
Parameters
- name: The name of the input like "push0" for first push button.
Availability
Not yet available. Planned for future release.