In Haxe, how do I check for a key that's been pressed twice?

Viewed 80

I've searched on Google for an answer, but I couldn't find anything that helped me. Basically, I want a function that activates when you press the R button twice.

1 Answers

You could store pressed key and time, on next press check if it same and not long time pass activate, otherwise update last pressed key and time

Related