Fixed minimax with depth

But its somewhat untested due to slowness.