integrating Fred's value function into the valuePolicy policy of mcts.py