add isKeyDown and hasKeyBeenUp functions to input.ts