Improved detection of ranked mode

Fixed the logic on checking for ranked mode so that it is correctly detected when playing a ranked game immediately after another ranked game, which previously could cause the mode to be [undetected]