I am trying to alter the value of a specific slider when a directional button is pressed. For example, if the down arrow is pressed, the slider value will decrease by a value of 100. However, the timer is throwing an error: “Timer has no member named AsyncKeyDown”
I’m probably misreading / misunderstanding the example code from the documentation. Could someone provide some insight?
@Emile Schwarz & @Kem Tekinay Thank you both! I’ve added Keyboard.AsyncKeyDown as an event handler, and it works. However, now I need to find a way to disable any other sliders from being affected by the use of arrow keys.
You don’t need to (nor should you) use the Async variant in a KeyDown event. You are passed the Key that was pressed as an argument. Use that. For reference
if Key = chr(28) then
// Left Arrow
ElseIf Key = chr(29) then
// Right Arrow
Elseif Key = chr(30) then
// Up Arrow
ElseIf Key = chr(31) then
// Down Arrow
End