Made race ending work with the new system