Total refactoring of Minimax. Heuristic is done.