Now detects AI win

added lines 92 and 93