Fixed issues with GameFinished and implemented basic minimax.