fixes board win detection
first pass at basic minimax algorithm