fix difficulty calc