public float abSearch(ABNode node, int depth, float a, float b, Boolean maximizingPlayer) {
		if(depth == 0 || node.isTerminal()) {
			return node.getHVal();
		}
		
		if (maximizingPlayer) {
			for(ABNode child : node.getChildNodes(1)) { //Each child node
				a = Math.max(a, abSearch(child, depth -1, a, b, false));
				if(b <= a) {
					break; //B cut-off
				}
				return a;
			}
		} else {
			for(ABNode child : node.getChildNodes(0))	{ //Each child node
				b = Math.min(b, abSearch(child, depth - 1, a, b, true));
				if (b <= a) {
					break; //a cut-off
				}
				return b;
			}
		}
		return -1;
	}