Fixed exception when switching players