Fixed a case where the AI would attempt to switch when in reality switching was impossible.