When developing games, it's very common to test whether a key is down in a loop rather than relying on key events. This commit adds two methods that let you check to see if a key is down, isKeyPressed() and getPressedKeyCodes().
Added functions for recording whether a key is down
+1 this is super handy.
This is great and I'd love to add it, but it lacks unit tests (see keymaster.html in the test folder!).
Added unit test
Added unit tests. See if that works for you.
Note: I did NOT minify the code.