Created
August 21, 2013 08:18
-
-
Save chribben/6291696 to your computer and use it in GitHub Desktop.
SignalForPressingRightOrLeftArrow
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Keyboard | |
keyToBool x = if x == 0 then False else True | |
sfx p = lift (\p -> p.x) p | |
signalX = sfx Keyboard.arrows | |
xArrowPulse = fpsWhen 10 (keyToBool <~ signalX) | |
main = lift asText xArrowPulse |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment