Fixed computation of selectOffsetBot variable