Adapt rank counting to new XBoard standard