minimax framework is working, need to integrate with heuristic function