Fix being unable to mine when game wasn't focused.