public void selectAction() {
        List<TreeNode> visited = new LinkedList<TreeNode>();
        TreeNode cur = this;
        visited.add(this);
        int depth = 0;
        while (cur.children!=null) {
            cur = cur.select();
            visited.add(cur);
            depth+=1;
            if(cur==null) return;
        }
        if(depth<maxDepth && cur.nVisits>expandThd){
        	
	        if(!cur.expand()){
	        	if(cur.state.whoseTurn().equals(me)){
	        		cur.totValue = -100;
	        	}
	        	else{
	        		cur.totValue = 100;
	        	}
	        	return;
	        }
	        depth+=1;
        	print = false;
	        cur = cur.select();
	        visited.add(cur);
	        if(cur==null){
	        	System.out.println("null new node");
	        }
	        print = false;
        }

        double value = randomSimulate(cur.state);
        //System.out.println("depth "+depth);
        for (TreeNode node : visited) {
            // would need extra logic for n-player game
            node.updateStats(value);
        }
    }