Fix calculation of initial mouse position, mouse position gets reset when pointer lock is lost