Waits for input to become available.
true if input is available, false otherwise.
Maximum time to wait in milliseconds.